mbox series

[iproute2-next,0/4] devlink: Support get,set mac address of a port function

Message ID 20200623104425.2324-1-parav@mellanox.com
Headers show
Series devlink: Support get,set mac address of a port function | expand

Message

Parav Pandit June 23, 2020, 10:44 a.m. UTC
Currently ip link set dev <pfndev> vf <vf_num> <param> <value> has
few below limitations.

1. Command is limited to set VF parameters only.
It cannot set the default MAC address for the PCI PF.

2. It can be set only on system where PCI SR-IOV is supported.
In smartnic based system, eswitch of a NIC resides on a different
embedded cpu which has the VF and PF representors for the SR-IOV
support on a host system in which this smartnic is plugged-in.

3. It cannot setup the function attributes of sub-function described
in detail in comprehensive RFC [1] and [2].

This series covers the first small part to let user query and set MAC
address (hardware address) of a PCI PF/VF which is represented by
devlink port.

Patch summary:
Patch-1 Sync kernel header
Patch-2 Move devlink port code at start to reuse
Patch-3 Extends port dump command to query additional port function
attribute(s)
Patch-4 Enables user to set port function hardware address

[1] https://lore.kernel.org/netdev/20200519092258.GF4655@nanopsycho/
[2] https://marc.info/?l=linux-netdev&m=158555928517777&w=2

Parav Pandit (4):
  Update kernel headers
  devlink: Move devlink port code at start to reuse
  devlink: Support querying hardware address of port function
  devlink: Support setting port function hardware address

 devlink/devlink.c            | 378 ++++++++++++++++++++++++-----------
 include/uapi/linux/devlink.h |  12 ++
 2 files changed, 269 insertions(+), 121 deletions(-)

Comments

David Ahern July 5, 2020, 2:56 p.m. UTC | #1
On 6/23/20 4:44 AM, Parav Pandit wrote:
> Currently ip link set dev <pfndev> vf <vf_num> <param> <value> has

> few below limitations.

> 

> 1. Command is limited to set VF parameters only.

> It cannot set the default MAC address for the PCI PF.

> 

> 2. It can be set only on system where PCI SR-IOV is supported.

> In smartnic based system, eswitch of a NIC resides on a different

> embedded cpu which has the VF and PF representors for the SR-IOV

> support on a host system in which this smartnic is plugged-in.

> 

> 3. It cannot setup the function attributes of sub-function described

> in detail in comprehensive RFC [1] and [2].

> 

> This series covers the first small part to let user query and set MAC

> address (hardware address) of a PCI PF/VF which is represented by

> devlink port.

> 

> Patch summary:

> Patch-1 Sync kernel header

> Patch-2 Move devlink port code at start to reuse

> Patch-3 Extends port dump command to query additional port function

> attribute(s)

> Patch-4 Enables user to set port function hardware address

> 

> [1] https://lore.kernel.org/netdev/20200519092258.GF4655@nanopsycho/

> [2] https://marc.info/?l=linux-netdev&m=158555928517777&w=2

> 

> Parav Pandit (4):

>   Update kernel headers

>   devlink: Move devlink port code at start to reuse

>   devlink: Support querying hardware address of port function

>   devlink: Support setting port function hardware address

> 

>  devlink/devlink.c            | 378 ++++++++++++++++++++++++-----------

>  include/uapi/linux/devlink.h |  12 ++

>  2 files changed, 269 insertions(+), 121 deletions(-)

> 


applied to iproute2-next. Thanks