Skip to content
  1. Nov 01, 2016
    • David S. Miller's avatar
      Merge branch 'qed-next' · f3a6f592
      David S. Miller authored
      
      
      Yuval Mintz says:
      
      ====================
      qed*: Patch series
      
      This series does several things. The bigger changes:
      
       - Add new notification APIs [& Defaults] for various fields.
      The series then utilizes some of those qed <-> qede APIs to bass WoL
      support upon.
      
       - Change the resource allocation scheme to receive the values from
      management firmware, instead of equally sharing resources between
      functions [that might not need those]. That would, e.g., allow us to
      configure additional filters to network interfaces in presence of
      storage [PCI] functions from same adapter.
      ====================
      
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f3a6f592
    • Tomer Tayar's avatar
      qed: Learn resources from management firmware · 2edbff8d
      Tomer Tayar authored
      
      
      Currently, each interfaces assumes it receives an equal portion
      of HW/FW resources, but this is wasteful - different partitions
      [and specifically, parititions exposing different protocol support]
      might require different resources.
      
      Implement a new resource learning scheme where the information is
      received directly from the management firmware [which has knowledge
      of all of the functions and can serve as arbiter].
      
      Signed-off-by: default avatarTomer Tayar <Tomer.Tayar@cavium.com>
      Signed-off-by: default avatarYuval Mintz <Yuval.Mintz@cavium.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      2edbff8d
    • Mintz, Yuval's avatar
      qed: Use VF-queue feature · 5a1f965a
      Mintz, Yuval authored
      
      
      Driver sets several restrictions about the number of supported VFs
      according to available HW/FW resources.
      This creates a problem as there are constellations which can't be
      supported [as limitation don't accurately describe the resources],
      as well as holes where enabling IOV would fail due to supposed
      lack of resources.
      
      This introduces a new interal feature - vf-queues, which would
      be used to lift some of the restriction and accurately enumerate
      the queues that can be used by a given PF's VFs.
      
      Signed-off-by: default avatarYuval Mintz <Yuval.Mintz@cavium.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      5a1f965a
    • Mintz, Yuval's avatar
      qed: Learn of RDMA capabilities per-device · 6927e826
      Mintz, Yuval authored
      
      
      Today, RDMA capabilities are learned from management firmware
      which provides a per-device indication for all interfaces.
      Newer management firmware is capable of providing a per-device
      indication [would later be extended to either RoCE/iWARP].
      
      Try using this newer learning mechanism, but fallback in case
      management firmware is too old to retain current functionality.
      
      Signed-off-by: default avatarYuval Mintz <Yuval.Mintz@cavium.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6927e826
    • Mintz, Yuval's avatar
      qede: Decouple ethtool caps from qed · d7455f6e
      Mintz, Yuval authored
      
      
      While the qed_lm_maps is closely tied with the QED_LM_* defines,
      when iterating over the array use actual size instead of the qed
      define to prevent future possible issues.
      
      Signed-off-by: default avatarYuval Mintz <Yuval.Mintz@cavium.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      d7455f6e
    • Mintz, Yuval's avatar
      qed*: Add support for WoL · 14d39648
      Mintz, Yuval authored
      
      
      Signed-off-by: default avatarYuval Mintz <Yuval.Mintz@cavium.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      14d39648
    • Mintz, Yuval's avatar
      qed: Add nvram selftest · 7a4b21b7
      Mintz, Yuval authored
      
      
      Signed-off-by: default avatarYuval Mintz <Yuval.Mintz@cavium.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      7a4b21b7
    • Sudarsana Kalluru's avatar
      qed*: Management firmware - notifications and defaults · 0fefbfba
      Sudarsana Kalluru authored
      
      
      Management firmware is interested in various tidbits about
      the driver - including the driver state & several configuration
      related fields [MTU, primtary MAC, etc.].
      This adds the necessray logic to update MFW with such configurations,
      some of which are passed directly via qed while for others APIs
      are provide so that qede would be able to later configure if needed.
      
      This also introduces a new default configuration for MTU which would
      replace the default inherited by being an ethernet device.
      
      Signed-off-by: default avatarSudarsana Kalluru <Sudarsana.Kalluru@cavium.com>
      Signed-off-by: default avatarYuval Mintz <Yuval.Mintz@cavium.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      0fefbfba
    • Julia Lawall's avatar
      solos-pci: use permission-specific DEVICE_ATTR variants · 89d9123e
      Julia Lawall authored
      
      
      Use DEVICE_ATTR_RW for read-write attributes.  This simplifies the
      source code, improves readbility, and reduces the chance of
      inconsistencies.
      
      The semantic patch that makes this change is as follows:
      (http://coccinelle.lip6.fr/)
      
      // <smpl>
      @rw@
      declarer name DEVICE_ATTR;
      identifier x,x_show,x_store;
      @@
      
      DEVICE_ATTR(x, \(0644\|S_IRUGO|S_IWUSR\), x_show, x_store);
      
      @script:ocaml@
      x << rw.x;
      x_show << rw.x_show;
      x_store << rw.x_store;
      @@
      
      if not (x^"_show" = x_show && x^"_store" = x_store)
      then Coccilib.include_match false
      
      @@
      declarer name DEVICE_ATTR_RW;
      identifier rw.x,rw.x_show,rw.x_store;
      @@
      
      - DEVICE_ATTR(x, \(0644\|S_IRUGO|S_IWUSR\), x_show, x_store);
      + DEVICE_ATTR_RW(x);
      // </smpl>
      
      Signed-off-by: default avatarJulia Lawall <Julia.Lawall@lip6.fr>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      89d9123e
    • Julia Lawall's avatar
      ptp: use permission-specific DEVICE_ATTR variants · 63215705
      Julia Lawall authored
      
      
      Use DEVICE_ATTR_RO for read only attributes.  This simplifies the
      source code, improves readbility, and reduces the chance of
      inconsistencies.
      
      The semantic patch that makes this change is as follows:
      (http://coccinelle.lip6.fr/)
      
      // <smpl>
      @ro@
      declarer name DEVICE_ATTR;
      identifier x,x_show;
      @@
      
      DEVICE_ATTR(x, \(0444\|S_IRUGO\), x_show, NULL);
      
      @script:ocaml@
      x << ro.x;
      x_show << ro.x_show;
      @@
      
      if not (x^"_show" = x_show) then Coccilib.include_match false
      
      @@
      declarer name DEVICE_ATTR_RO;
      identifier ro.x,ro.x_show;
      @@
      
      - DEVICE_ATTR(x, \(0444\|S_IRUGO\), x_show, NULL);
      + DEVICE_ATTR_RO(x);
      // </smpl>
      
      Signed-off-by: default avatarJulia Lawall <Julia.Lawall@lip6.fr>
      Acked-by: default avatarRichard Cochran <richardcochran@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      63215705
    • Daniel Borkmann's avatar
      bpf, inode: add support for symlinks and fix mtime/ctime · 0f98621b
      Daniel Borkmann authored
      While commit bb35a6ef ("bpf, inode: allow for rename and link ops")
      added support for hard links that can be used for prog and map nodes,
      this work adds simple symlink support, which can be used f.e. for
      directories also when unpriviledged and works with cmdline tooling that
      understands S_IFLNK anyway. Since the switch in e27f4a94
      
       ("bpf: Use
      mount_nodev not mount_ns to mount the bpf filesystem"), there can be
      various mount instances with mount_nodev() and thus hierarchy can be
      flattened to facilitate object sharing. Thus, we can keep bpf tooling
      also working by repointing paths.
      
      Most of the functionality can be used from vfs library operations. The
      symlink is stored in the inode itself, that is in i_link, which is
      sufficient in our case as opposed to storing it in the page cache.
      While at it, I noticed that bpf_mkdir() and bpf_mkobj() don't update
      the directories mtime and ctime, so add a common helper for it called
      bpf_dentry_finalize() that takes care of it for all cases now.
      
      Signed-off-by: default avatarDaniel Borkmann <daniel@iogearbox.net>
      Acked-by: default avatarAlexei Starovoitov <ast@kernel.org>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      0f98621b
    • Aaron Young's avatar
      ldmvsw: tx queue stuck in stopped state after LDC reset · 8778b276
      Aaron Young authored
      
      
      The following patch fixes an issue with the ldmvsw driver where
      the network connection of a guest domain becomes non-functional after
      the guest domain has panic'd and rebooted.
      
      The root cause was determined to be from the following series of
      events:
      
      1. Guest domain panics - resulting in the guest no longer processing
         network packets (from ldmvsw driver)
      2. The ldmvsw driver (in the control domain) eventually exerts flow
         control due to no more available tx drings and stops the tx queue
         for the guest domain
      3. The LDC of the network connection for the guest is reset when
         the guest domain reboots after the panic.
      4. The LDC reset event is received by the ldmvsw driver and the ldmvsw
         responds by clearing the tx queue for the guest.
      5. ldmvsw waits indefinitely for a DATA ACK from the guest - which is
         the normal method to re-enable the tx queue. But the ACK never comes
         because the tx queue was cleared due to the LDC reset.
      
      To fix this issue, in addition to clearing the tx queue, re-enable the
      tx queue on a LDC reset. This prevents the ldmvsw from getting caught in
      this deadlocked state of waiting for a DATA ACK which will never come.
      
      Signed-off-by: default avatarAaron Young <Aaron.Young@oracle.com>
      Acked-by: default avatarSowmini Varadhan <sowmini.varadhan@oracle.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      8778b276
    • David S. Miller's avatar
      Merge branch 'xps-DCB' · 04f762e8
      David S. Miller authored
      
      
      Alexander Duyck says:
      
      ====================
      Add support for XPS when using DCB
      
      This patch series enables proper isolation between traffic classes when
      using XPS while DCB is enabled.  Previously enabling XPS would cause the
      traffic to be potentially pulled from one traffic class into another on
      egress.  This change essentially multiplies the XPS map by the number of
      traffic classes and allows us to do a lookup per traffic class for a given
      CPU.
      
      To guarantee the isolation I invalidate the XPS map for any queues that are
      moved from one traffic class to another, or if we change the number of
      traffic classes.
      
      v2: Added sysfs to display traffic class
          Replaced do/while with for loop
          Cleaned up several other for for loops throughout the patch
      ====================
      
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      04f762e8
    • Alexander Duyck's avatar
      net: Add support for XPS with QoS via traffic classes · 184c449f
      Alexander Duyck authored
      
      
      This patch adds support for setting and using XPS when QoS via traffic
      classes is enabled.  With this change we will factor in the priority and
      traffic class mapping of the packet and use that information to correctly
      select the queue.
      
      This allows us to define a set of queues for a given traffic class via
      mqprio and then configure the XPS mapping for those queues so that the
      traffic flows can avoid head-of-line blocking between the individual CPUs
      if so desired.
      
      Signed-off-by: default avatarAlexander Duyck <alexander.h.duyck@intel.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      184c449f
    • Alexander Duyck's avatar
      net: Refactor removal of queues from XPS map and apply on num_tc changes · 6234f874
      Alexander Duyck authored
      
      
      This patch updates the code for removing queues from the XPS map and makes
      it so that we can apply the code any time we change either the number of
      traffic classes or the mapping of a given block of queues.  This way we
      avoid having queues pulling traffic from a foreign traffic class.
      
      Signed-off-by: default avatarAlexander Duyck <alexander.h.duyck@intel.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6234f874
    • Alexander Duyck's avatar
      net: Add sysfs value to determine queue traffic class · 8d059b0f
      Alexander Duyck authored
      
      
      Add a sysfs attribute for a Tx queue that allows us to determine the
      traffic class for a given queue.  This will allow us to more easily
      determine this in the future.  It is needed as XPS will take the traffic
      class for a group of queues into account in order to avoid pulling traffic
      from one traffic class into another.
      
      Signed-off-by: default avatarAlexander Duyck <alexander.h.duyck@intel.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      8d059b0f
    • Alexander Duyck's avatar
      net: Move functions for configuring traffic classes out of inline headers · 9cf1f6a8
      Alexander Duyck authored
      
      
      The functions for configuring the traffic class to queue mappings have
      other effects that need to be addressed.  Instead of trying to export a
      bunch of new functions just relocate the functions so that we can
      instrument them directly with the functionality they will need.
      
      Signed-off-by: default avatarAlexander Duyck <alexander.h.duyck@intel.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      9cf1f6a8
  2. Oct 31, 2016