Date: Mon, 19 Jul 2004 23:12:54 +0200 From: Marius Strobl <marius@alchemy.franken.de> To: Frank Nobis <fn@radio-do.de> Cc: freebsd-sparc64@freebsd.org Subject: Re: Quad ethernet card on AXi starts with identical MAC addresses on 5.2.1R Message-ID: <20040719231254.A37923@newtrinity.zeist.de> In-Reply-To: <10DE5AAC-D9AF-11D8-A4E6-000A95BA60A4@radio-do.de>; from fn@radio-do.de on Mon, Jul 19, 2004 at 08:11:33PM %2B0200 References: <CD6F5740-D9A3-11D8-A4E6-000A95BA60A4@radio-do.de> <20040719170238.GA3121@sunhsc.germany.sun.com> <20040719172658.GC10699@electra.cse.Buffalo.EDU> <10DE5AAC-D9AF-11D8-A4E6-000A95BA60A4@radio-do.de>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Jul 19, 2004 at 08:11:33PM +0200, Frank Nobis wrote: > > Am 19.07.2004 um 19:26 schrieb Ken Smith: > > > On Mon, Jul 19, 2004 at 07:02:38PM +0200, Ronald Kuehn wrote: > >> > >> Yes, unless you set local-mac-address? to true in OBP. > >> > > > > I would be interested in knowing if this works. I know it works on > > SUN's running Solaris when it is possible but I just checked the > > FreeBSD code and unless I made a wrong turn somewhere (which is > > possible... :-) it won't matter if this is set or not. The pathway > > I followed seemed to dig the MAC address out of the ID-PROM no matter > > what. In particular hme_pci_attach() seems to call OF_getetheraddr() > > which in turn seems to blindly dig the MAC address out of the idprom. > > > A friend told me Solaris would just add up some numbers to make > different MAC addresses. > All hme(4) add-in cards except the single port SBus ones contain a MAC address for each interface in their FCode. The same seems to be true for Sun mainboards having more than one onboard network interface. I don't know for sure about Solaris but I'd expect it to just use these addresses and not make up its own. > I just tested with local-mac-address set to true. > > Some as before. Seems the the attach code of the hme driver reads only > the MAC from the builtin ethernet and set this to all instances of the > hme interfaces. The question is, how difficult it is to simulate the > Solaris behavior. It's not hard to read these addresses via Open Firmware and use them instead the hostid but it's not so easy to do it in a sane way. The first way I thought of turned out to result in plain ugly code (despite working :). I have two other ways in mind but haven't had time to try them, yet.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040719231254.A37923>