All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Buesch <mb@bu3sch.de>
To: Johannes Berg <johannes@sipsolutions.net>
Cc: linux-wireless <linux-wireless@vger.kernel.org>,
	Daniel Drake <dsd@gentoo.org>,
	Michael Wu <flamingice@sourmilk.net>,
	James Ketrenos <jketreno@linux.intel.com>,
	Zhu Yi <yi.zhu@intel.com>
Subject: Re: driver bugs with changed mac address
Date: Wed, 20 Jun 2007 23:52:16 +0200	[thread overview]
Message-ID: <200706202352.16975.mb@bu3sch.de> (raw)
In-Reply-To: <1182333938.3714.53.camel@johannes.berg>

On Wednesday 20 June 2007 12:05:38 Johannes Berg wrote:
> Hi,
> 
> I was just looking through some bcm43xx code and noticed that when you
> set a different mac address for some interface, then it is stored to
> wl->mac_addr but this is only ever used in
> bcm43xx_write_mac_bssid_templates and not in bcm43xx_wireless_core_init.
> 
> iwlwifi on the other hand completely ignores the mac address after
> printing it out.
> 
> Also in bcm43xx, when the interface is removed again wl->mac_addr isn't
> set to NULL when the interface that the MAC belonged to is deleted, so
> that the mac address stays programmed on the card and we continue to ACK
> packets for that MAC address.
> 
> In zd1211, we start with hwaddr = dev->wiphy->perm_addr which isn't
> correct either, for a pure monitor mode we want to start with a zero mac
> addr to avoid acking packets. Also, zd1211rw will end up having a NULL
> hwaddr when a monitor interface is added, most likely segfaulting in
> zd_write_mac_addr then.
> 
> The NULL mac address will also happen to rtl818x and possibly p54 (at
> least when that gets monitor mode support)
> 
> Whew. So much for our little mac address audit.
> 
> johannes
> 

Nice catch, thanks!

This should fix it on bcm43xx:
http://bu3sch.de/gitweb?p=wireless-dev.git;a=commitdiff;h=dbf39fd9f4cc4edc35ed7ab349c55137ea35aea0

-- 
Greetings Michael.

  reply	other threads:[~2007-06-20 21:55 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-20 10:05 driver bugs with changed mac address Johannes Berg
2007-06-20 21:52 ` Michael Buesch [this message]
2007-07-26  2:21 ` Daniel Drake
2007-07-26 15:39   ` Johannes Berg

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=200706202352.16975.mb@bu3sch.de \
    --to=mb@bu3sch.de \
    --cc=dsd@gentoo.org \
    --cc=flamingice@sourmilk.net \
    --cc=jketreno@linux.intel.com \
    --cc=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=yi.zhu@intel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.