Re: [PATCH 6/7] netdev: octeon-ethernet: Add Cavium Octeon III support.

2017-11-03 Thread Andrew Lunn
> >>+static char *mix_port; > >>+module_param(mix_port, charp, 0444); > >>+MODULE_PARM_DESC(mix_port, "Specifies which ports connect to MIX > >>interfaces."); > > > >Can you derive this from Device Tree /platform data configuration? > > > >>+ > >>+static char *pki_port; >

Re: [PATCH 6/7] netdev: octeon-ethernet: Add Cavium Octeon III support.

2017-11-02 Thread David Daney
On 11/02/2017 12:13 PM, Florian Fainelli wrote: On 11/01/2017 05:36 PM, David Daney wrote: From: Carlos Munoz The Cavium OCTEON cn78xx and cn73xx SoCs have network packet I/O hardware that is significantly different from previous generations of the family. Add a new driver

Re: [PATCH 6/7] netdev: octeon-ethernet: Add Cavium Octeon III support.

2017-11-02 Thread Florian Fainelli
On 11/01/2017 05:36 PM, David Daney wrote: > From: Carlos Munoz > > The Cavium OCTEON cn78xx and cn73xx SoCs have network packet I/O > hardware that is significantly different from previous generations of > the family. > > Add a new driver for this hardware. The Ethernet MAC

Re: [PATCH 6/7] netdev: octeon-ethernet: Add Cavium Octeon III support.

2017-11-02 Thread Florian Fainelli
On 11/02/2017 11:31 AM, David Daney wrote: > On 11/02/2017 09:56 AM, Andrew Lunn wrote: >>> OK, now I think I understand. Yes, the MAC can be hardwired to a >>> switch. >>> In fact, there are system designs that do exactly that. >>> >>> We try to handle this case by not having a "phy-handle"

Re: [PATCH 6/7] netdev: octeon-ethernet: Add Cavium Octeon III support.

2017-11-02 Thread David Daney
On 11/02/2017 09:56 AM, Andrew Lunn wrote: OK, now I think I understand. Yes, the MAC can be hardwired to a switch. In fact, there are system designs that do exactly that. We try to handle this case by not having a "phy-handle" property in the device tree. The link to the remote device

Re: [PATCH 6/7] netdev: octeon-ethernet: Add Cavium Octeon III support.

2017-11-02 Thread Andrew Lunn
> OK, now I think I understand. Yes, the MAC can be hardwired to a switch. > In fact, there are system designs that do exactly that. > > We try to handle this case by not having a "phy-handle" property in the > device tree. The link to the remote device (switch IC in this case) is > brought up

Re: [PATCH 6/7] netdev: octeon-ethernet: Add Cavium Octeon III support.

2017-11-02 Thread David Daney
On 11/02/2017 09:10 AM, Andrew Lunn wrote: On Thu, Nov 02, 2017 at 08:55:33AM -0700, David Daney wrote: On 11/02/2017 05:43 AM, Andrew Lunn wrote: [...] + + i = atomic_inc_return(_id); + pki_dev = platform_device_register_data(_dev->dev, +

Re: [PATCH 6/7] netdev: octeon-ethernet: Add Cavium Octeon III support.

2017-11-02 Thread Andrew Lunn
On Thu, Nov 02, 2017 at 08:55:33AM -0700, David Daney wrote: > On 11/02/2017 05:43 AM, Andrew Lunn wrote: > [...] > >>+ > >>+ i = atomic_inc_return(_id); > >>+ pki_dev = platform_device_register_data(_dev->dev, > >>+ is_mix ?

Re: [PATCH 6/7] netdev: octeon-ethernet: Add Cavium Octeon III support.

2017-11-02 Thread David Daney
On 11/02/2017 05:43 AM, Andrew Lunn wrote: [...] + + i = atomic_inc_return(_id); + pki_dev = platform_device_register_data(_dev->dev, + is_mix ? "octeon_mgmt" : "ethernet-mac-pki", +

Re: [PATCH 6/7] netdev: octeon-ethernet: Add Cavium Octeon III support.

2017-11-02 Thread Andrew Lunn
> +static int bgx_probe(struct platform_device *pdev) > +{ > + struct mac_platform_data platform_data; > + const __be32 *reg; > + u32 port; > + u64 addr; > + struct device_node *child; > + struct platform_device *new_dev; > + struct platform_device *pki_dev; > + int