From patchwork Sat Jan 29 21:47:38 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sven Eckelmann X-Patchwork-Id: 791 Return-Path: Received: from v3-1039.vlinux.de (narfation.org [79.140.41.39]) by open-mesh.org (Postfix) with ESMTPS id 6501A154688 for ; Sat, 29 Jan 2011 22:48:31 +0100 (CET) Received: from sven-desktop.home.narfation.org (unknown [88.130.181.181]) by v3-1039.vlinux.de (Postfix) with ESMTPSA id 0EF8F94057; Sat, 29 Jan 2011 22:49:04 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=narfation.org; s=mail; t=1296337744; bh=1HtDa/DbnyiiHk/Gl5/X1APG+kJFOV16/ZpPzhRIRYA=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References; b=nluxUSL91oazqZxWuFPrtzhYf5EVgjWLmLxjst2nOXQJ3E7Trwq99OiQBFRar+lRV NbBqhfph/gFdbRi4QHHOF+foiUNoHl5V4xBTw9w5r/tk1qTwfDsZd+2LBX1UoKXJnT Z5gEr2kDhwyqt6TFuB6yTEaaELZ7qRWAY1taV2c0= From: Sven Eckelmann To: davem@davemloft.net Date: Sat, 29 Jan 2011 22:47:38 +0100 Message-Id: <1296337660-12376-12-git-send-email-sven@narfation.org> X-Mailer: git-send-email 1.7.2.3 In-Reply-To: <1296337660-12376-1-git-send-email-sven@narfation.org> References: <1296337660-12376-1-git-send-email-sven@narfation.org> Cc: netdev@vger.kernel.org, b.a.t.m.a.n@lists.open-mesh.org Subject: [B.A.T.M.A.N.] [PATCH 11/13] batman-adv: Remove unused variables X-BeenThere: b.a.t.m.a.n@lists.open-mesh.org X-Mailman-Version: 2.1.11 Precedence: list Reply-To: The list for a Better Approach To Mobile Ad-hoc Networking List-Id: The list for a Better Approach To Mobile Ad-hoc Networking List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Jan 2011 21:48:31 -0000 Signed-off-by: Sven Eckelmann --- net/batman-adv/bat_debugfs.c | 4 +--- net/batman-adv/routing.c | 7 ------- 2 files changed, 1 insertions(+), 10 deletions(-) diff --git a/net/batman-adv/bat_debugfs.c b/net/batman-adv/bat_debugfs.c index 0ae81d0..d36d305 100644 --- a/net/batman-adv/bat_debugfs.c +++ b/net/batman-adv/bat_debugfs.c @@ -52,7 +52,6 @@ static void emit_log_char(struct debug_log *debug_log, char c) static int fdebug_log(struct debug_log *debug_log, char *fmt, ...) { - int printed_len; va_list args; static char debug_log_buf[256]; char *p; @@ -62,8 +61,7 @@ static int fdebug_log(struct debug_log *debug_log, char *fmt, ...) spin_lock_bh(&debug_log->lock); va_start(args, fmt); - printed_len = vscnprintf(debug_log_buf, sizeof(debug_log_buf), - fmt, args); + vscnprintf(debug_log_buf, sizeof(debug_log_buf), fmt, args); va_end(args); for (p = debug_log_buf; *p != 0; p++) diff --git a/net/batman-adv/routing.c b/net/batman-adv/routing.c index e946dc9..3b7e2f7 100644 --- a/net/batman-adv/routing.c +++ b/net/batman-adv/routing.c @@ -807,13 +807,11 @@ static int recv_my_icmp_packet(struct bat_priv *bat_priv, { struct orig_node *orig_node; struct icmp_packet_rr *icmp_packet; - struct ethhdr *ethhdr; struct batman_if *batman_if; int ret; uint8_t dstaddr[ETH_ALEN]; icmp_packet = (struct icmp_packet_rr *)skb->data; - ethhdr = (struct ethhdr *)skb_mac_header(skb); /* add data to device queue */ if (icmp_packet->msg_type != ECHO_REQUEST) { @@ -845,7 +843,6 @@ static int recv_my_icmp_packet(struct bat_priv *bat_priv, return NET_RX_DROP; icmp_packet = (struct icmp_packet_rr *)skb->data; - ethhdr = (struct ethhdr *)skb_mac_header(skb); memcpy(icmp_packet->dst, icmp_packet->orig, ETH_ALEN); memcpy(icmp_packet->orig, @@ -867,13 +864,11 @@ static int recv_icmp_ttl_exceeded(struct bat_priv *bat_priv, { struct orig_node *orig_node; struct icmp_packet *icmp_packet; - struct ethhdr *ethhdr; struct batman_if *batman_if; int ret; uint8_t dstaddr[ETH_ALEN]; icmp_packet = (struct icmp_packet *)skb->data; - ethhdr = (struct ethhdr *)skb_mac_header(skb); /* send TTL exceeded if packet is an echo request (traceroute) */ if (icmp_packet->msg_type != ECHO_REQUEST) { @@ -906,7 +901,6 @@ static int recv_icmp_ttl_exceeded(struct bat_priv *bat_priv, return NET_RX_DROP; icmp_packet = (struct icmp_packet *) skb->data; - ethhdr = (struct ethhdr *)skb_mac_header(skb); memcpy(icmp_packet->dst, icmp_packet->orig, ETH_ALEN); memcpy(icmp_packet->orig, @@ -998,7 +992,6 @@ int recv_icmp_packet(struct sk_buff *skb, struct batman_if *recv_if) return NET_RX_DROP; icmp_packet = (struct icmp_packet_rr *)skb->data; - ethhdr = (struct ethhdr *)skb_mac_header(skb); /* decrement ttl */ icmp_packet->ttl--;