> This makes ifconfig display baudrates defined in ifmedia.h tables. > > Before (prints media subtype): > > $ ifconfig iwn0 | grep media: > media: IEEE802.11 autoselect (OFDM6 mode 11a) > $ ifconfig em0 | grep media: > media: Ethernet autoselect (100baseTX full-duplex,rxpause,txpause) > > After (prints corresponding baudrate): > > $ ifconfig iwn0 | grep media: > media: IEEE802.11 autoselect (6Mbps mode 11a) > $ ifconfig em0 | grep media: > media: Ethernet autoselect (100Mbps full-duplex,rxpause,txpause) > > The output of 'ifconfig media' (which prints command syntax) is unchanged > and we fall back to printing the media subtype if no baudrate is found.
It makes no sense to change ethernet. The values it prints now is intended to match what you pass as parameters for the 'media' and 'mediaopt' subcommands. That's why the line is prefixed with the word "media", not "speed". There are legacy options at the 100mbit level: if_media.h: { IFM_ETHER|IFM_100_TX, "100baseTX" }, \ if_media.h: { IFM_ETHER|IFM_100_FX, "100baseFX" }, \ if_media.h: { IFM_ETHER|IFM_100_T4, "100baseT4" }, \ if_media.h: { IFM_ETHER|IFM_100_VG, "100baseVG" }, \ if_media.h: { IFM_ETHER|IFM_100_T2, "100baseT2" }, \ Now they all become the opaque "100Mbps"? Sure many of those don't exist at the moment, or are not used. But look at gig: if_media.h: { IFM_ETHER|IFM_1000_SX, "1000baseSX" }, \ if_media.h: { IFM_ETHER|IFM_1000_SX, "1000SX" }, \ if_media.h: { IFM_ETHER|IFM_1000_LX, "1000baseLX" }, \ if_media.h: { IFM_ETHER|IFM_1000_LX, "1000LX" }, \ if_media.h: { IFM_ETHER|IFM_1000_CX, "1000baseCX" }, \ if_media.h: { IFM_ETHER|IFM_1000_CX, "1000CX" }, \ if_media.h: { IFM_ETHER|IFM_1000_T, "1000baseT" }, \ if_media.h: { IFM_ETHER|IFM_1000_T, "1000T" }, \ if_media.h: { IFM_ETHER|IFM_1000_T, "1000baseTX" }, \ if_media.h: { IFM_ETHER|IFM_1000_T, "1000TX" }, \ this is on cvs: media: Ethernet autoselect (10GSFP+Cu full-duplex) That is information, you'd replace that with a speed? No thanks, it does not make sense.