Date: Thu, 20 Feb 1997 12:40:02 -0500 From: Garrett Wollman <wollman@lcs.mit.edu> To: elh@astroarch.com Cc: freebsd-bugs@freebsd.org, elh@secretariat.astroarch.com Subject: SIOCGIFPHYS Message-ID: <9702201740.AA09784@halloran-eldar.lcs.mit.edu> In-Reply-To: <199702200236.UAA09387@secretariat.astroarch.com> References: <199702200236.UAA09387@secretariat.astroarch.com>
next in thread | previous in thread | raw e-mail | index | archive | help
<<On Wed, 19 Feb 1997 20:36:28 -0600, elh@astroarch.com said: > I am in need of code that can query the physical hardware address of > an ethernet. I have written the following code but it is to no > avail. SIOCGIFPHYS does not get the hardware address. In fact, it does not do anything at all. It was intended to get the currently-selected medium, but this was never implemented by any of the driver writers. You should use SIOCGIFCONF and look for addresses in the AF_LINK family where the sdl_type member (of struct sockaddr_dl, defined in <net/if_dl.h>) is IFT_ETHER. -GAWollman -- Garrett A. Wollman | O Siem / We are all family / O Siem / We're all the same wollman@lcs.mit.edu | O Siem / The fires of freedom Opinions not those of| Dance in the burning flame MIT, LCS, ANA, or NSA| - Susan Aglukark and Chad Irschick
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?9702201740.AA09784>