Messages in this thread | | | Date | Wed, 15 Apr 2020 15:45:11 +0200 | From | Andrew Lunn <> | Subject | Re: [PATCH v1] ethtool: provide UAPI for PHY master/slave configuration. |
| |
> In the IEEE 802.3 it is described as: > --------------------------------------------------------------------------- > Port type: Bit 9.10 is to be used to indicate the preference to operate > as MASTER (multiport device) or as SLAVE (single-port device) if the > MASTER-SLAVE Manual Configuration Enable bit, 9.12, is not set. Usage > of this bit is described in 40.5.2. > 1 = Multiport device > 0 = single-port device
I really should go read the standard, but...
> --------------------------------------------------------------------------- > > Setting PORT_MODE_MASTER/PORT_MODE_SLAVE will increase the chance to get > MASTER or SLAVE mode, but not force it. > > If we will follow strictly to the IEEE 802.3 spec, it should be named: > > #define PORT_MODE_UNKNOWN 0x00 > /* this two options will not force some specific mode, only influence > * the chance to get it */ > #define PORT_TYPE_MULTI_PORT 0x01 > #define PORT_TYPE_SINGLE_PORT 0x02 > /* this two options will force master or slave mode */ > #define PORT_MODE_MASTER 0x03 > #define PORT_MODE_SLAVE 0x04
I prefer having FORCE in the name.
But let me read the standard and get up to speed.
Andrew
| |