Re: [PATCH RFC 3/3] net: vertexcom: Add MSE102x SPI support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Sep 16, 2021 at 11:26:18AM +0000, Michael Heimpold wrote:
> Hi Andrew,
> 
> Zitat von Andrew Lunn <andrew@xxxxxxx>:
> 
> > > +static int mse102x_probe_spi(struct spi_device *spi)
> > > +{
> > 
> > ...
> > 
> > > +	netif_carrier_off(mse->ndev);
> > > +	ndev->if_port = IF_PORT_10BASET;
> > 
> > That is not correct. Maybe you should add a IF_PORT_HOMEPLUG ?
> 
> Would a simple IF_PORT_HOMEPLUG be sufficient, or should it be
> more precise as for Ethernet (10BASET, 100BASET...), e.g.
> IF_PORT_HOMEPLUG_10
> IF_PORT_HOMEPLUG_AV
> IF_PORT_HOMEPLUG_AV2
> IF_PORT_HOMEPLUG_GREENPHY

It is an interesting question. I think the first thing to find out is,
what in userspace actually uses this. If it is a deprecated tool, i
would not spend the energy.

Probably a better interface is ethtool get_link_ksettings, and
set_link_ksettings.

$ /sbin/ethtool enp3s0
Settings for enp3s0:
	Supported ports: [ TP	 MII ]
	Supported link modes:   10baseT/Half 10baseT/Full
	                        100baseT/Half 100baseT/Full
	                        1000baseT/Full

You can set supported ports to HomePlug, and supported link modes to
10, AV, AV2, GREENPHY etc.

Is there a negotiation mechanism where different homeplug devices can
find out what they have in common and select a mode? That would be
very similar to Ethernet autoneg, so you can make use of the other
fields ethtool provides to show this information, etc.

       Andrew





[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux