Date: Mon, 21 Jan 2002 18:39:47 +0200 From: Ruslan Ermilov <ru@FreeBSD.org> To: "M. Warner Losh" <imp@village.org> Cc: rwatson@FreeBSD.org, cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/net if.c if.h route.h rtsock.c src/share/man/man4 route.4 src/sbin/route route.c Message-ID: <20020121183947.A83821@sunbay.com> In-Reply-To: <20020121.085527.98102760.imp@village.org> References: <20020121103822.A16527@sunbay.com> <Pine.NEB.3.96L.1020121101217.69509A-100000@fledge.watson.org> <20020121173406.A77567@sunbay.com> <20020121.085527.98102760.imp@village.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Jan 21, 2002 at 08:55:27AM -0700, M. Warner Losh wrote: > In message: <20020121173406.A77567@sunbay.com> > Ruslan Ermilov <ru@FreeBSD.org> writes: > : I'm talking about IFF_UP thing here, not sure what do you mean. > > Robert is talking about connecting and disconnecting the cable. This > changes the "link status": > > fxp0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500 > inet 0.0.0.0 netmask 0xff000000 broadcast 255.255.255.255 > ether 00:20:e0:68:17:ae > media: Ethernet autoselect (none) > status: no carrier > > to > > fxp0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500 > inet 0.0.0.0 netmask 0xff000000 broadcast 255.255.255.255 > ether 00:20:e0:68:17:ae > media: Ethernet autoselect (none) > status: active > Nope, this actually changes the "media status", that is where my confusion comes from. I've looked at several device drivers, and some get asynchronous notifications about media status changes (like ti(4)), and some don't (like dc(4) using dcphy_status() through mii_pollstat()). This means that the only reliable way is to periodically query the driver about media status changes through the SIOCGIFMEDIA ioctl. Cheers, -- Ruslan Ermilov Oracle Developer/DBA, ru@sunbay.com Sunbay Software AG, ru@FreeBSD.org FreeBSD committer, +380.652.512.251 Simferopol, Ukraine http://www.FreeBSD.org The Power To Serve http://www.oracle.com Enabling The Information Age To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020121183947.A83821>