1. 10 7月, 2020 3 次提交
  2. 09 7月, 2020 1 次提交
    • L
      net: dsa: tag_rtl4_a: Implement Realtek 4 byte A tag · efd7fe68
      Linus Walleij 提交于
      This implements the known parts of the Realtek 4 byte
      tag protocol version 0xA, as found in the RTL8366RB
      DSA switch.
      
      It is designated as protocol version 0xA as a
      different Realtek 4 byte tag format with protocol
      version 0x9 is known to exist in the Realtek RTL8306
      chips.
      
      The tag and switch chip lacks public documentation, so
      the tag format has been reverse-engineered from
      packet dumps. As only ingress traffic has been available
      for analysis an egress tag has not been possible to
      develop (even using educated guesses about bit fields)
      so this is as far as it gets. It is not known if the
      switch even supports egress tagging.
      
      Excessive attempts to figure out the egress tag format
      was made. When nothing else worked, I just tried all bit
      combinations with 0xannp where a is protocol and p is
      port. I looped through all values several times trying
      to get a response from ping, without any positive
      result.
      
      Using just these ingress tags however, the switch
      functionality is vastly improved and the packets find
      their way into the destination port without any
      tricky VLAN configuration. On the D-Link DIR-685 the
      LAN ports now come up and respond to ping without
      any command line configuration so this is a real
      improvement for users.
      
      Egress packets need to be restricted to the proper
      target ports using VLAN, which the RTL8366RB DSA
      switch driver already sets up.
      
      Cc: DENG Qingfang <dqfext@gmail.com>
      Cc: Mauri Sandberg <sandberg@mailfence.com>
      Reviewed-by: NAndrew Lunn <andrew@lunn.ch>
      Reviewed-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      efd7fe68
  3. 04 7月, 2020 4 次提交
  4. 02 7月, 2020 1 次提交
    • J
      bonding: allow xfrm offload setup post-module-load · a3b658cf
      Jarod Wilson 提交于
      At the moment, bonding xfrm crypto offload can only be set up if the bonding
      module is loaded with active-backup mode already set. We need to be able to
      make this work with bonds set to AB after the bonding driver has already
      been loaded.
      
      So what's done here is:
      
      1) move #define BOND_XFRM_FEATURES to net/bonding.h so it can be used
      by both bond_main.c and bond_options.c
      2) set BOND_XFRM_FEATURES in bond_dev->hw_features universally, rather than
      only when loading in AB mode
      3) wire up xfrmdev_ops universally too
      4) disable BOND_XFRM_FEATURES in bond_dev->features if not AB
      5) exit early (non-AB case) from bond_ipsec_offload_ok, to prevent a
      performance hit from traversing into the underlying drivers
      5) toggle BOND_XFRM_FEATURES in bond_dev->wanted_features and call
      netdev_change_features() from bond_option_mode_set()
      
      In my local testing, I can change bonding modes back and forth on the fly,
      have hardware offload work when I'm in AB, and see no performance penalty
      to non-AB software encryption, despite having xfrm bits all wired up for
      all modes now.
      
      Fixes: 18cb261a ("bonding: support hardware encryption offload to slaves")
      Reported-by: NHuy Nguyen <huyn@mellanox.com>
      CC: Saeed Mahameed <saeedm@mellanox.com>
      CC: Jay Vosburgh <j.vosburgh@gmail.com>
      CC: Veaceslav Falico <vfalico@gmail.com>
      CC: Andy Gospodarek <andy@greyhouse.net>
      CC: "David S. Miller" <davem@davemloft.net>
      CC: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
      CC: Jakub Kicinski <kuba@kernel.org>
      CC: Steffen Klassert <steffen.klassert@secunet.com>
      CC: Herbert Xu <herbert@gondor.apana.org.au>
      CC: netdev@vger.kernel.org
      CC: intel-wired-lan@lists.osuosl.org
      Signed-off-by: NJarod Wilson <jarod@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a3b658cf
  5. 01 7月, 2020 2 次提交
  6. 30 6月, 2020 4 次提交
    • P
      net:qos: police action offloading parameter 'burst' change to the original value · 5f035af7
      Po Liu 提交于
      Since 'tcfp_burst' with TICK factor, driver side always need to recover
      it to the original value, this patch moves the generic calculation and
      recover to the 'burst' original value before offloading to device driver.
      Signed-off-by: NPo Liu <po.liu@nxp.com>
      Acked-by: NVladimir Oltean <vladimir.oltean@nxp.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      5f035af7
    • P
      net: sched: sch_red: Add qevents "early_drop" and "mark" · aee9caa0
      Petr Machata 提交于
      In order to allow acting on dropped and/or ECN-marked packets, add two new
      qevents to the RED qdisc: "early_drop" and "mark". Filters attached at
      "early_drop" block are executed as packets are early-dropped, those
      attached at the "mark" block are executed as packets are ECN-marked.
      
      Two new attributes are introduced: TCA_RED_EARLY_DROP_BLOCK with the block
      index for the "early_drop" qevent, and TCA_RED_MARK_BLOCK for the "mark"
      qevent. Absence of these attributes signifies "don't care": no block is
      allocated in that case, or the existing blocks are left intact in case of
      the change callback.
      
      For purposes of offloading, blocks attached to these qevents appear with
      newly-introduced binder types, FLOW_BLOCK_BINDER_TYPE_RED_EARLY_DROP and
      FLOW_BLOCK_BINDER_TYPE_RED_MARK.
      Signed-off-by: NPetr Machata <petrm@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      aee9caa0
    • P
      net: sched: Introduce helpers for qevent blocks · 3625750f
      Petr Machata 提交于
      Qevents are attach points for TC blocks, where filters can be put that are
      executed when "interesting events" take place in a qdisc. The data to keep
      and the functions to invoke to maintain a qevent will be largely the same
      between qevents. Therefore introduce sched-wide helpers for qevent
      management.
      
      Currently, similarly to ingress and egress blocks of clsact pseudo-qdisc,
      blocks attachment cannot be changed after the qdisc is created. To that
      end, add a helper tcf_qevent_validate_change(), which verifies whether
      block index attribute is not attached, or if it is, whether its value
      matches the current one (i.e. there is no material change).
      
      The function tcf_qevent_handle() should be invoked when qdisc hits the
      "interesting event" corresponding to a block. This function releases root
      lock for the duration of executing the attached filters, to allow packets
      generated through user actions (notably mirred) to be reinserted to the
      same qdisc tree.
      Signed-off-by: NPetr Machata <petrm@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      3625750f
    • P
      net: sched: Pass root lock to Qdisc_ops.enqueue · aebe4426
      Petr Machata 提交于
      A following patch introduces qevents, points in qdisc algorithm where
      packet can be processed by user-defined filters. Should this processing
      lead to a situation where a new packet is to be enqueued on the same port,
      holding the root lock would lead to deadlocks. To solve the issue, qevent
      handler needs to unlock and relock the root lock when necessary.
      
      To that end, add the root lock argument to the qdisc op enqueue, and
      propagate throughout.
      Signed-off-by: NPetr Machata <petrm@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      aebe4426
  7. 29 6月, 2020 2 次提交
  8. 28 6月, 2020 2 次提交
  9. 26 6月, 2020 1 次提交
  10. 25 6月, 2020 5 次提交
  11. 24 6月, 2020 9 次提交
    • T
      net: Do not clear the sock TX queue in sk_set_socket() · 41b14fb8
      Tariq Toukan 提交于
      Clearing the sock TX queue in sk_set_socket() might cause unexpected
      out-of-order transmit when called from sock_orphan(), as outstanding
      packets can pick a different TX queue and bypass the ones already queued.
      
      This is undesired in general. More specifically, it breaks the in-order
      scheduling property guarantee for device-offloaded TLS sockets.
      
      Remove the call to sk_tx_queue_clear() in sk_set_socket(), and add it
      explicitly only where needed.
      
      Fixes: e022f0b4 ("net: Introduce sk_tx_queue_mapping")
      Signed-off-by: NTariq Toukan <tariqt@mellanox.com>
      Reviewed-by: NBoris Pismenny <borisp@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      41b14fb8
    • G
      net: ipv6: Use struct_size() helper and kcalloc() · 6f393457
      Gustavo A. R. Silva 提交于
      Make use of the struct_size() helper instead of an open-coded version
      in order to avoid any potential type mistakes. Also, remove unnecessary
      function ipv6_rpl_srh_alloc_size() and replace kzalloc() with kcalloc(),
      which has a 2-factor argument form for multiplication.
      
      This code was detected with the help of Coccinelle and, audited and
      fixed manually.
      Signed-off-by: NGustavo A. R. Silva <gustavoars@kernel.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      6f393457
    • E
      udp: move gro declarations to net/udp.h · 6db69328
      Eric Dumazet 提交于
      This removes following warnings :
        CC      net/ipv4/udp_offload.o
      net/ipv4/udp_offload.c:504:17: warning: no previous prototype for 'udp4_gro_receive' [-Wmissing-prototypes]
        504 | struct sk_buff *udp4_gro_receive(struct list_head *head, struct sk_buff *skb)
            |                 ^~~~~~~~~~~~~~~~
      net/ipv4/udp_offload.c:584:29: warning: no previous prototype for 'udp4_gro_complete' [-Wmissing-prototypes]
        584 | INDIRECT_CALLABLE_SCOPE int udp4_gro_complete(struct sk_buff *skb, int nhoff)
            |                             ^~~~~~~~~~~~~~~~~
      
        CHECK   net/ipv6/udp_offload.c
      net/ipv6/udp_offload.c:115:16: warning: symbol 'udp6_gro_receive' was not declared. Should it be static?
      net/ipv6/udp_offload.c:148:29: warning: symbol 'udp6_gro_complete' was not declared. Should it be static?
        CC      net/ipv6/udp_offload.o
      net/ipv6/udp_offload.c:115:17: warning: no previous prototype for 'udp6_gro_receive' [-Wmissing-prototypes]
        115 | struct sk_buff *udp6_gro_receive(struct list_head *head, struct sk_buff *skb)
            |                 ^~~~~~~~~~~~~~~~
      net/ipv6/udp_offload.c:148:29: warning: no previous prototype for 'udp6_gro_complete' [-Wmissing-prototypes]
        148 | INDIRECT_CALLABLE_SCOPE int udp6_gro_complete(struct sk_buff *skb, int nhoff)
            |                             ^~~~~~~~~~~~~~~~~
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      6db69328
    • E
      net: move tcp gro declarations to net/tcp.h · 5521d95e
      Eric Dumazet 提交于
      This patch removes following (C=1 W=1) warnings for CONFIG_RETPOLINE=y :
      
      net/ipv4/tcp_offload.c:306:16: warning: symbol 'tcp4_gro_receive' was not declared. Should it be static?
      net/ipv4/tcp_offload.c:306:17: warning: no previous prototype for 'tcp4_gro_receive' [-Wmissing-prototypes]
      net/ipv4/tcp_offload.c:319:29: warning: symbol 'tcp4_gro_complete' was not declared. Should it be static?
      net/ipv4/tcp_offload.c:319:29: warning: no previous prototype for 'tcp4_gro_complete' [-Wmissing-prototypes]
        CHECK   net/ipv6/tcpv6_offload.c
      net/ipv6/tcpv6_offload.c:16:16: warning: symbol 'tcp6_gro_receive' was not declared. Should it be static?
      net/ipv6/tcpv6_offload.c:29:29: warning: symbol 'tcp6_gro_complete' was not declared. Should it be static?
        CC      net/ipv6/tcpv6_offload.o
      net/ipv6/tcpv6_offload.c:16:17: warning: no previous prototype for 'tcp6_gro_receive' [-Wmissing-prototypes]
         16 | struct sk_buff *tcp6_gro_receive(struct list_head *head, struct sk_buff *skb)
            |                 ^~~~~~~~~~~~~~~~
      net/ipv6/tcpv6_offload.c:29:29: warning: no previous prototype for 'tcp6_gro_complete' [-Wmissing-prototypes]
         29 | INDIRECT_CALLABLE_SCOPE int tcp6_gro_complete(struct sk_buff *skb, int thoff)
            |                             ^~~~~~~~~~~~~~~~~
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      5521d95e
    • E
      tcp: move ipv4_specific to tcp include file · 9b9e2f25
      Eric Dumazet 提交于
      Declare ipv4_specific once, in tcp.h were it belongs.
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      9b9e2f25
    • E
      tcp: move ipv6_specific declaration to remove a warning · b03d2142
      Eric Dumazet 提交于
      ipv6_specific should be declared in tcp include files,
      not mptcp.
      
      This removes the following warning :
        CHECK   net/ipv6/tcp_ipv6.c
      net/ipv6/tcp_ipv6.c:78:42: warning: symbol 'ipv6_specific' was not declared. Should it be static?
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      b03d2142
    • E
      tcp: add declarations to avoid warnings · 243600ee
      Eric Dumazet 提交于
      Remove these errors:
      
      net/ipv6/tcp_ipv6.c:1550:29: warning: symbol 'tcp_v6_rcv' was not declared. Should it be static?
      net/ipv6/tcp_ipv6.c:1770:30: warning: symbol 'tcp_v6_early_demux' was not declared. Should it be static?
      
      net/ipv6/tcp_ipv6.c:1550:29: warning: no previous prototype for 'tcp_v6_rcv' [-Wmissing-prototypes]
       1550 | INDIRECT_CALLABLE_SCOPE int tcp_v6_rcv(struct sk_buff *skb)
            |                             ^~~~~~~~~~
      net/ipv6/tcp_ipv6.c:1770:30: warning: no previous prototype for 'tcp_v6_early_demux' [-Wmissing-prototypes]
       1770 | INDIRECT_CALLABLE_SCOPE void tcp_v6_early_demux(struct sk_buff *skb)
            |                              ^~~~~~~~~~~~~~~~~~
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      243600ee
    • J
      bonding/xfrm: use real_dev instead of slave_dev · bdfd2d1f
      Jarod Wilson 提交于
      Rather than requiring every hw crypto capable NIC driver to do a check for
      slave_dev being set, set real_dev in the xfrm layer and xso init time, and
      then override it in the bonding driver as needed. Then NIC drivers can
      always use real_dev, and at the same time, we eliminate the use of a
      variable name that probably shouldn't have been used in the first place,
      particularly given recent current events.
      
      CC: Boris Pismenny <borisp@mellanox.com>
      CC: Saeed Mahameed <saeedm@mellanox.com>
      CC: Leon Romanovsky <leon@kernel.org>
      CC: Jay Vosburgh <j.vosburgh@gmail.com>
      CC: Veaceslav Falico <vfalico@gmail.com>
      CC: Andy Gospodarek <andy@greyhouse.net>
      CC: "David S. Miller" <davem@davemloft.net>
      CC: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
      CC: Jakub Kicinski <kuba@kernel.org>
      CC: Steffen Klassert <steffen.klassert@secunet.com>
      CC: Herbert Xu <herbert@gondor.apana.org.au>
      CC: netdev@vger.kernel.org
      Suggested-by: NSaeed Mahameed <saeedm@mellanox.com>
      Signed-off-by: NJarod Wilson <jarod@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      bdfd2d1f
    • B
      ipv6: fib6: avoid indirect calls from fib6_rule_lookup · 55cced4f
      Brian Vazquez 提交于
      It was reported that a considerable amount of cycles were spent on the
      expensive indirect calls on fib6_rule_lookup. This patch introduces an
      inline helper called pol_route_func that uses the indirect_call_wrappers
      to avoid the indirect calls.
      
      This patch saves around 50ns per call.
      
      Performance was measured on the receiver by checking the amount of
      syncookies that server was able to generate under a synflood load.
      
      Traffic was generated using trafgen[1] which was pushing around 1Mpps on
      a single queue. Receiver was using only one rx queue which help to
      create a bottle neck and make the experiment rx-bounded.
      
      These are the syncookies generated over 10s from the different runs:
      
      Whithout the patch:
      TcpExtSyncookiesSent            3553749            0.0
      TcpExtSyncookiesSent            3550895            0.0
      TcpExtSyncookiesSent            3553845            0.0
      TcpExtSyncookiesSent            3541050            0.0
      TcpExtSyncookiesSent            3539921            0.0
      TcpExtSyncookiesSent            3557659            0.0
      TcpExtSyncookiesSent            3526812            0.0
      TcpExtSyncookiesSent            3536121            0.0
      TcpExtSyncookiesSent            3529963            0.0
      TcpExtSyncookiesSent            3536319            0.0
      
      With the patch:
      TcpExtSyncookiesSent            3611786            0.0
      TcpExtSyncookiesSent            3596682            0.0
      TcpExtSyncookiesSent            3606878            0.0
      TcpExtSyncookiesSent            3599564            0.0
      TcpExtSyncookiesSent            3601304            0.0
      TcpExtSyncookiesSent            3609249            0.0
      TcpExtSyncookiesSent            3617437            0.0
      TcpExtSyncookiesSent            3608765            0.0
      TcpExtSyncookiesSent            3620205            0.0
      TcpExtSyncookiesSent            3601895            0.0
      
      Without the patch the average is 354263 pkt/s or 2822 ns/pkt and with
      the patch the average is 360738 pkt/s or 2772 ns/pkt which gives an
      estimate of 50 ns per packet.
      
      [1] http://netsniff-ng.org/
      
      Changelog since v1:
       - Change ordering in the ICW (Paolo Abeni)
      
      Cc: Luigi Rizzo <lrizzo@google.com>
      Cc: Paolo Abeni <pabeni@redhat.com>
      Reported-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NBrian Vazquez <brianvv@google.com>
      Acked-by: NPaolo Abeni <pabeni@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      55cced4f
  12. 23 6月, 2020 6 次提交
    • A
      GUE: Fix a typo · 26ac10be
      Aiden Leong 提交于
      Fix a typo in gue.h
      Signed-off-by: NAiden Leong <aiden.leong@aibsd.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      26ac10be
    • V
      devlink: Add support for board.serial_number to info_get cb. · b5872cd0
      Vasundhara Volam 提交于
      Board serial number is a serial number, often available in PCI
      *Vital Product Data*.
      
      Also, update devlink-info.rst documentation file.
      
      Cc: Jiri Pirko <jiri@mellanox.com>
      Cc: Jakub Kicinski <kuba@kernel.org>
      Signed-off-by: NVasundhara Volam <vasundhara-v.volam@broadcom.com>
      Reviewed-by: NMichael Chan <michael.chan@broadcom.com>
      Reviewed-by: NJiri Pirko <jiri@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      b5872cd0
    • J
      bonding: support hardware encryption offload to slaves · 18cb261a
      Jarod Wilson 提交于
      Currently, this support is limited to active-backup mode, as I'm not sure
      about the feasilibity of mapping an xfrm_state's offload handle to
      multiple hardware devices simultaneously, and we rely on being able to
      pass some hints to both the xfrm and NIC driver about whether or not
      they're operating on a slave device.
      
      I've tested this atop an Intel x520 device (ixgbe) using libreswan in
      transport mode, succesfully achieving ~4.3Gbps throughput with netperf
      (more or less identical to throughput on a bare NIC in this system),
      as well as successful failover and recovery mid-netperf.
      
      v2: just use CONFIG_XFRM_OFFLOAD for wrapping, isolate more code with it
      
      CC: Jay Vosburgh <j.vosburgh@gmail.com>
      CC: Veaceslav Falico <vfalico@gmail.com>
      CC: Andy Gospodarek <andy@greyhouse.net>
      CC: "David S. Miller" <davem@davemloft.net>
      CC: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
      CC: Jakub Kicinski <kuba@kernel.org>
      CC: Steffen Klassert <steffen.klassert@secunet.com>
      CC: Herbert Xu <herbert@gondor.apana.org.au>
      CC: netdev@vger.kernel.org
      CC: intel-wired-lan@lists.osuosl.org
      Signed-off-by: NJarod Wilson <jarod@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      18cb261a
    • J
      xfrm: bail early on slave pass over skb · 272c2330
      Jarod Wilson 提交于
      This is prep work for initial support of bonding hardware encryption
      pass-through support. The bonding driver will fill in the slave_dev
      pointer, and we use that to know not to skb_push() again on a given
      skb that was already processed on the bond device.
      
      CC: Jay Vosburgh <j.vosburgh@gmail.com>
      CC: Veaceslav Falico <vfalico@gmail.com>
      CC: Andy Gospodarek <andy@greyhouse.net>
      CC: "David S. Miller" <davem@davemloft.net>
      CC: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
      CC: Jakub Kicinski <kuba@kernel.org>
      CC: Steffen Klassert <steffen.klassert@secunet.com>
      CC: Herbert Xu <herbert@gondor.apana.org.au>
      CC: netdev@vger.kernel.org
      CC: intel-wired-lan@lists.osuosl.org
      Signed-off-by: NJarod Wilson <jarod@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      272c2330
    • P
      net/devlink: Support setting hardware address of port function · a1e8ae90
      Parav Pandit 提交于
      PCI PF and VF devlink port can manage the function represented by a
      devlink port.
      
      Allow users to set port function's hardware address.
      
      Example of a PCI VF port which supports a port function:
      $ devlink port show pci/0000:06:00.0/2
      pci/0000:06:00.0/2: type eth netdev enp6s0pf0vf1 flavour pcivf pfnum 0 vfnum 1
        function:
          hw_addr 00:00:00:00:00:00
      
      $ devlink port function set pci/0000:06:00.0/2 hw_addr 00:11:22:33:44:55
      
      $ devlink port show pci/0000:06:00.0/2
      pci/0000:06:00.0/2: type eth netdev enp6s0pf0vf1 flavour pcivf pfnum 0 vfnum 1
        function:
          hw_addr 00:11:22:33:44:55
      Signed-off-by: NParav Pandit <parav@mellanox.com>
      Reviewed-by: NJiri Pirko <jiri@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a1e8ae90
    • P
      net/devlink: Support querying hardware address of port function · 2a916ecc
      Parav Pandit 提交于
      PCI PF and VF devlink port can manage the function represented by
      a devlink port.
      
      Enable users to query port function's hardware address.
      
      Example of a PCI VF port which supports a port function:
      $ devlink port show pci/0000:06:00.0/2
      pci/0000:06:00.0/2: type eth netdev enp6s0pf0vf1 flavour pcivf pfnum 0 vfnum 1
        function:
          hw_addr 00:11:22:33:44:66
      
      $ devlink port show pci/0000:06:00.0/2 -jp
      {
          "port": {
              "pci/0000:06:00.0/2": {
                  "type": "eth",
                  "netdev": "enp6s0pf0vf1",
                  "flavour": "pcivf",
                  "pfnum": 0,
                  "vfnum": 1,
                  "function": {
                      "hw_addr": "00:11:22:33:44:66"
                  }
              }
          }
      }
      Signed-off-by: NParav Pandit <parav@mellanox.com>
      Reviewed-by: NJiri Pirko <jiri@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      2a916ecc