[ltp] WG511 PCMCIA with 2 Mac addresses (Mandriva)
Mauro Maroni
linux-thinkpad@linux-thinkpad.org
Thu, 22 Apr 2010 18:36:44 -0300
Richard:
Here is what I found:
gentoo mauro # /etc/init.d/net.eth0 stop
* Unmounting network filesystems ...
[ ok ]
* Stopping eth0
* Bringing down eth0
* Shutting down eth0 ...
[ ok ]
After this, it is still showing the real MAC:
gentoo mauro # cat /sys/class/net/eth0/address
00:09:5b:e6:c5:aa
gentoo mauro # rmmod prism54
At this point, the card no longer exists in /sys/class/net.
And ifconfig only shows the loopback interface
gentoo mauro # cardctl eject
If I reinsert the card at this point, it is detected, prism54 module is loaded
and then eth0 comes up with the real MAC.
So I did it all again but moving isl3890 firmware to another place.
Reinserted the card, it is detected and prism54 loaded.
eth0 does not come up (no firmware).And now yes, I get the bogus MAC:
gentoo mauro # cat /sys/class/net/eth0/address
00:30:b4:00:00:00
Then I put isl3890 back in place and tried to bring the card up.
It comes up without issues:
gentoo mauro # /etc/init.d/net.eth0 start
* Starting eth0
* Configuring wireless network for eth0
* eth0 connected to "NETGEAR" at 00:09:5B:DD:FA:6E
* Bringing up eth0
* 10.0.0.100
[ ok ]
* Adding routes
* default gw 10.0.0.2 ...
[ ok ]
gentoo mauro # cat /sys/class/net/eth0/address
00:09:5b:e6:c5:aa
Hope this helps
Mauro
On Saturday 01 April 2006 20:46, Richard Neill wrote:
> Mauro Maroni wrote:
> > I have a Netgear WG511 but never saw that behaviour...The only issue I
> > have is that sometimes the card disconnects from the access point, but I
> > only have to run '/etc/init.d/net.eth0 restart' (I am using Gentoo) in
> > order to reconnect it. I will try to see if that issue is also related to
> > a changing MAC address.
>
> Dear Mauro,
>
> Thanks very much for your help. That's interesting that it doesn't
> happen on Gentoo. The question is, why?
> a) Gentoo's ifup/ifcfg script is smarter than Mandriva's.
> b) Your version of the prism driver always reports the true mac, even
> without the firmware being uploaded.
> c) We have different revisions of the hardware.
>
> Could you check for me what happens if you do the following:
> [I'm assuming your interface is called eth0, although it could be eth1
> or wlan]
>
> 0)Stop ifplugd if you have it running.
>
> 1)rmmod prism54; cardctl eject; physically eject the card.
>
> 2)reinsert the card.
>
> [At this point, the eth0 interface will not be up]
>
> 3)Check which MAC address you have with:
> cat sys/class/net/wlan/address
> and
> ifconfig -a
>
> 4)ifup wlan
>
> 5)Repeat (3).
>
> 6)Ifdown eth0;
>
> 7)ifup eth0
>
> 8)Repeat (3).
>
>
> I would expect that the results are these:
>
> [3] 00:30:b4:00:00:00 #the "default" bogus mac.
>
> [5] your_real_mac_address
>
> [8] I don't know, because step 7) fails for me.
>
>
> You might also try repeating steps 1-4 after temporarily moving
> /usr/lib/hotplug/firmware/isl3890 somewhere where it cannot be found.
>
> Lastly, is the MAC you have in ifcfg-eth0 your real one, or the bogus
> one?
>
>
> Thanks very much,
>
> Richard
>
> > Regards,
> > Mauro
> >
> > On Friday 31 March 2006 21:28, Richard Neill wrote:
> >>Dear All,
> >>
> >>I wonder whether I could consult the collective wisdom about this. My
> >>Netgear WG511 card works perfectly with the prism54 driver, once the
> >>binary firmware has been loaded.
> >>
> >>However, the MAC address (as reported by ifconfig, or udevinfo) changes
> >>between 2 different values depending on status:
> >>
> >>1)Without the firmware installed, or before the network interface has
> >>been brought up (for the first time since boot or plugging in the card):
> >> 00:30:b4:00:00:00
> >>
> >>2)Once the firmware has been loaded, and the interface has been brought
> >>up at least once:
> >> 00:09:5b:c1:3a:b1
> >>
> >>The problem is that restarting the network no longer recognises the
> >>card, since the MAC address has now changed:
> >> "interface 'wlan' not foundDevice wlan has different MAC address
> >> than expected, ignoring."
> >>
> >>
> >>
> >>All the config tools (iftab, ifcfg-wlan) need to refer to the first
> >>(un-initialised) MAC. But once initialised, they don't recognise the
> >>card anymore.
> >>
> >>The simple solution is to cardctl eject, and physically unplug/replug
> >>the card each time I restart the network. But that's ugly! I think I
> >>need to bind one interface name to 2 different MAC addresses.
> >>
> >>Does anyone know the correct solution, or can point me to an appropriate
> >>resource?
> >>
> >>Thanks very much,
> >>
> >>Richard
> >>
> >>
> >>
> >>
> >>
> >>--
> >>rn214@hermes.cam.ac.uk ** http://www.richardneill.org
> >>Richard Neill, Trinity College, Cambridge, CB21TQ, U.K.