netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Antonio Quartulli <antonio-x4xJYDvStAgysxA8WJXlww@public.gmane.org>
To: davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org
Cc: netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	b.a.t.m.a.n-ZwoEplunGu2X36UT3dwllkB+6BGkLq7r@public.gmane.org,
	Marek Lindner
	<mareklindner-rVWd3aGhH2z5bpWLKbzFeg@public.gmane.org>,
	Antonio Quartulli
	<antonio-x4xJYDvStAgysxA8WJXlww@public.gmane.org>
Subject: [PATCH 7/7] batman-adv: fix vlan header access
Date: Sat, 28 Dec 2013 17:06:00 +0100	[thread overview]
Message-ID: <1388246760-3335-8-git-send-email-antonio@meshcoding.com> (raw)
In-Reply-To: <1388246760-3335-1-git-send-email-antonio-x4xJYDvStAgysxA8WJXlww@public.gmane.org>

When batadv_get_vid() is invoked in interface_rx() the
batman-adv header has already been removed, therefore
the header_len argument has to be 0.

Introduced by c018ad3de61a1dc4194879a53e5559e094aa7b1a
("batman-adv: add the VLAN ID attribute to the TT entry")

Signed-off-by: Antonio Quartulli <antonio-x4xJYDvStAgysxA8WJXlww@public.gmane.org>
Signed-off-by: Marek Lindner <mareklindner-rVWd3aGhH2z5bpWLKbzFeg@public.gmane.org>
---
 net/batman-adv/soft-interface.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/batman-adv/soft-interface.c b/net/batman-adv/soft-interface.c
index 875a702..a8f99d1 100644
--- a/net/batman-adv/soft-interface.c
+++ b/net/batman-adv/soft-interface.c
@@ -351,7 +351,7 @@ void batadv_interface_rx(struct net_device *soft_iface,
 	 */
 	nf_reset(skb);
 
-	vid = batadv_get_vid(skb, hdr_size);
+	vid = batadv_get_vid(skb, 0);
 	ethhdr = eth_hdr(skb);
 
 	switch (ntohs(ethhdr->h_proto)) {
-- 
1.8.5.2

  parent reply	other threads:[~2013-12-28 16:06 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-28 16:05 pull request [net]: batman-adv 2013-12-28 Antonio Quartulli
2013-12-28 16:05 ` [PATCH 2/7] batman-adv: fix header alignment by unrolling batadv_header Antonio Quartulli
2013-12-28 16:05 ` [PATCH 4/7] batman-adv: fix size of batadv_bla_claim_dst Antonio Quartulli
     [not found] ` <1388246760-3335-1-git-send-email-antonio-x4xJYDvStAgysxA8WJXlww@public.gmane.org>
2013-12-28 16:05   ` [PATCH 1/7] batman-adv: fix alignment for batadv_coded_packet Antonio Quartulli
2013-12-28 16:05   ` [PATCH 3/7] batman-adv: fix size of batadv_icmp_header Antonio Quartulli
2013-12-28 16:05   ` [PATCH 5/7] batman-adv: fix alignment for batadv_tvlv_tt_change Antonio Quartulli
2013-12-28 16:05   ` [PATCH 6/7] batman-adv: clean nf state when removing protocol header Antonio Quartulli
2013-12-28 16:06   ` Antonio Quartulli [this message]
2013-12-29  5:37 ` pull request [net]: batman-adv 2013-12-28 David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1388246760-3335-8-git-send-email-antonio@meshcoding.com \
    --to=antonio-x4xjydvstagysxa8wjxlww@public.gmane.org \
    --cc=b.a.t.m.a.n-ZwoEplunGu2X36UT3dwllkB+6BGkLq7r@public.gmane.org \
    --cc=davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org \
    --cc=mareklindner-rVWd3aGhH2z5bpWLKbzFeg@public.gmane.org \
    --cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).