Subject: Re: how to view interface's media options?
To: <>
From: David Laight <david@l8s.co.uk>
List: netbsd-help
Date: 03/07/2002 10:29:10
On Thu, Mar 07, 2002 at 12:42:27AM -0500, Brian A. Seklecki wrote:
> > > (Also, it seems like "netstat -i" always shows zero collisions but my
> > > other systems show collisions on same network.)
> >
> > So it's probably full duplex then.
> >

Or that driver doesn't (maybe can't) count them :-)
> 
> All my CCNA/CCDA reference material insists that 10/full can only exist on
> a cross/over or to a switch (where there is only a 2 point collision
> domain), although I can get my sun hardware [ hme(7D) ] to talk to my $15
> dumb hubs at 10/full, but it exhibits, as J.C.R. indicated, an extreme
> performance decrease.
> 
> General rule of thumb: Always best to force media and mediaopt on both
> sides.

Erm - have to disagree!

Full duplex MUST be agreed by the transceivers at both ends of the link,
and the ethernet MAC engine must also know.

Since (almost) all the transceivers that support FDX support
autonegotiation, you are better off only using FDX if the
transceivers agree to it.

However the MAC engine isn't told whether the transceiver is
running FDX or not - indeed it could renegotiate to HDX (or v.v.)
at any time without the MAC being informed.

The only way to find out the transceiver speed is to poll one
of the transceiver dependant registers (8-15) over the MII.
(registers 0-7 do not contain the current mode!)  Some
MAC engines (eg suns FEPS) will poll one of the transceiver's
registers and interrupt the driver if it changes, however
most do not - so the MAC has to poll in sw.  This is a cpu
intensive function (a 32 bit datastream has to be clocked
out in software....), but could be done at 1 bit per clock
tick to save locking out interrupts...

It is actually safest - especially with an unknown tranceiver
to explicitly disable FDX.  Then nothing can go wrong.

	David



	David

-- 
David Laight: david@l8s.co.uk