Linux wireless drivers development
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Thomas Pedersen <thomas@cozybit.com>
Cc: linux-wireless@vger.kernel.org, linville@tuxdriver.com
Subject: Re: [PATCH 2/3] mac80211: find correct IE offset in mesh beacons
Date: Thu, 20 Oct 2011 19:51:15 +0200	[thread overview]
Message-ID: <1319133075.17101.4.camel@jlt3.sipsolutions.net> (raw)
In-Reply-To: <CAG6hwVOVHSN_-vfvVNQsGrZZtipArNs9UoPQb-gy1ZhC0owC=w@mail.gmail.com> (sfid-20111020_194901_127802_6503536C)

On Thu, 2011-10-20 at 10:48 -0700, Thomas Pedersen wrote:
> On Thu, Oct 20, 2011 at 4:13 AM, Johannes Berg
> <johannes@sipsolutions.net> wrote:
> >
> >> -     baselen = (u8 *) mgmt->u.probe_resp.variable - (u8 *) mgmt;
> >> +     switch (stype) {
> >> +     case IEEE80211_STYPE_PROBE_RESP:
> >> +             ies = (u8 *) mgmt->u.probe_resp.variable;
> >> +             break;
> >> +     case IEEE80211_STYPE_BEACON:
> >> +             ies = (u8 *) mgmt->u.beacon.variable;
> >> +             break;
> >> +     default:
> >> +             return;
> >> +     }
> >> +
> >
> > Does that really make sense? the offset is the same anyway and we don't
> > get here with other frames.
> 
> I don't think so:
> 
>                 struct {
>                         __le64 timestamp;
>                         __le16 beacon_int;
>                         __le16 capab_info;
>                         /* followed by some of SSID, Supported rates,
>                          * FH Params, DS Params, CF Params, IBSS Params, TIM */
>                         u8 variable[0];
>                 } __attribute__ ((packed)) beacon;
>                 struct {
>                         /* only variable items: SSID, Supported rates */
>                         u8 variable[0];
>                 } __attribute__ ((packed)) probe_req;

Err, probe_req != probe_resp.

johannes


  reply	other threads:[~2011-10-20 17:51 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-20  0:23 [PATCH 1/3] mac80211: comment allocation of mesh frames Thomas Pedersen
2011-10-20  0:23 ` [PATCH 2/3] mac80211: find correct IE offset in mesh beacons Thomas Pedersen
2011-10-20 11:13   ` Johannes Berg
2011-10-20 17:48     ` Thomas Pedersen
2011-10-20 17:51       ` Johannes Berg [this message]
2011-10-20 17:53         ` Thomas Pedersen
2011-10-20  0:23 ` [PATCH 3/3] mac80211: select queue for fwded mesh frames Thomas Pedersen
2011-10-20  7:26 ` [PATCH v2 " Thomas Pedersen

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=1319133075.17101.4.camel@jlt3.sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=thomas@cozybit.com \
    /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