From patchwork Fri May 20 23:33:07 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Antonio Quartulli X-Patchwork-Id: 1091 Return-Path: Received: from contumacia.investici.org (contumacia.investici.org [178.255.144.35]) by open-mesh.org (Postfix) with ESMTPS id 1F9D81540E1 for ; Sat, 21 May 2011 01:33:05 +0200 (CEST) Authentication-Results: open-mesh.org; dkim=pass (1024-bit key) header.i=@autistici.org; dkim-adsp=pass Received: from [178.255.144.35] (contumacia [178.255.144.35]) (Authenticated sender: ordex@autistici.org) by localhost (Postfix) with ESMTPSA id 0389FE8288; Fri, 20 May 2011 23:33:02 +0000 (UTC) X-DKIM: Sendmail DKIM Filter v2.8.2 contumacia.investici.org 0389FE8288 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=autistici.org; s=stigmate; t=1305934383; bh=lk3RGq7RdS/Tq40gvgnWhhoER9d27r09VDloAG8/t7s=; h=From:To:Cc:Subject:Date:Message-Id; b=Cb5DjyXeJ6gx3K+aWfGuN3WACnQjHrDx+b7XAFa6SA4jl2MLzF4z40l+w1FMwjWXH 7PbA+Mv1DdHQXh+lBvxVyPwNOYTxuY5n+8g8RAfs3Lw3tdFpJwFLtjTA8VV8Zu3WNL DNorqlqD8gfkhUQzKXoPZmBOliNHQ79cLyeXcGlg= From: Antonio Quartulli To: "B.A.T.M.A.N" Date: Sat, 21 May 2011 01:33:07 +0200 Message-Id: <1305934387-25000-1-git-send-email-ordex@autistici.org> X-Mailer: git-send-email 1.7.3.4 Subject: [B.A.T.M.A.N.] [PATCH] batman-adv: use is_broadcast_ether_addr() instead of compare_eth(.., brd_addr) X-BeenThere: b.a.t.m.a.n@lists.open-mesh.org X-Mailman-Version: 2.1.13 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: Fri, 20 May 2011 23:33:05 -0000 Instead of comparing mac addresses with the broadcast address by means of compare_eth(), the is_broadcast_ether_addr() kernel function has to be used. Signed-off-by: Antonio Quartulli Acked-by: Sven Eckelmann --- routing.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/routing.c b/routing.c index 07f23ba..90ae6f0 100644 --- a/routing.c +++ b/routing.c @@ -661,7 +661,7 @@ void receive_bat_packet(const struct ethhdr *ethhdr, hard_iface->net_dev->dev_addr)) is_my_oldorig = 1; - if (compare_eth(ethhdr->h_source, broadcast_addr)) + if (is_broadcast_ether_addr(ethhdr->h_source)) is_broadcast = 1; } rcu_read_unlock();