1. 25 9月, 2016 12 次提交
  2. 24 9月, 2016 17 次提交
    • S
      hv_netvsc: fix comments · c6a77ff8
      Stephen Hemminger 提交于
      Typo's and spelling errors. Also remove old comment from staging era.
      Signed-off-by: NStephen Hemminger <sthemmin@microsoft.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c6a77ff8
    • D
      Merge branch 'thunderx-bql' · 15a09901
      David S. Miller 提交于
      Sunil Goutham says:
      
      ====================
      BQL support and fix for a regression issue
      
      These patches add byte queue limit support and also fixes a regression
      issue introduced by commit
      'net: thunderx: Use netdev's name for naming VF's interrupts'
      
      Changes from v1:
      - As suggested added 'Fixes' tag with commit id of previous commit
        which cuased issue.
      - Also fixed the missing netdev_tx_reset_queue() function call in
        byte queue limits support patch.
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      15a09901
    • S
      net: thunderx: Support for byte queue limits · 2c204c2b
      Sunil Goutham 提交于
      This patch adds support for byte queue limits
      Signed-off-by: NSunil Goutham <sgoutham@cavium.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      2c204c2b
    • S
      net: thunderx: Fix issue with IRQ namimg · b4e28c1f
      Sunil Goutham 提交于
      This patch fixes a regression caused by previous commit
      when irq name exceeds 20 byte array if interface's name
      size is large.
      
      Fixes: e4126213 ("net: thunderx: Use netdev's name for naming VF's interrupts")
      Signed-off-by: NSunil Goutham <sgoutham@cavium.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      b4e28c1f
    • C
      mlxsw: spectrum: remove redundant check if err is zero · faac0ff0
      Colin Ian King 提交于
      There is an earlier check and return if err is non-zero, so
      the check to see if it is zero is redundant in every iteration
      of the loop and hence the check can be removed.
      Signed-off-by: NColin Ian King <colin.king@canonical.com>
      Acked-by: NJiri Pirko <jiri@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      faac0ff0
    • S
      Documentation: devicetree: fix typo in MediaTek ethernet device-tree binding · 7f8c2865
      Sean Wang 提交于
      fix typo in
      Documentation/devicetree/bindings/net/mediatek-net.txt
      
      Cc: devicetree@vger.kernel.org
      Reported-by: NSergei Shtylyov <sergei.shtylyov@cogentembedded.com>
      Signed-off-by: NSean Wang <sean.wang@mediatek.com>
      Acked-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      7f8c2865
    • S
      Documentation: devicetree: revise ethernet device-tree binding about TRGMII · 4ce4862a
      Sean Wang 提交于
      add phy-mode "trgmii" to
      Documentation/devicetree/bindings/net/ethernet.txt
      
      Cc: devicetree@vger.kernel.org
      Reported-by: NSergei Shtylyov <sergei.shtylyov@cogentembedded.com>
      Signed-off-by: NSean Wang <sean.wang@mediatek.com>
      Acked-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      4ce4862a
    • D
      Merge tag 'rxrpc-rewrite-20160923' of... · 2a9aa41f
      David S. Miller 提交于
      Merge tag 'rxrpc-rewrite-20160923' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs
      
      David Howells says:
      
      ====================
      rxrpc: Bug fixes and tracepoints
      
      Here are a bunch of bug fixes:
      
       (1) Need to set the timestamp on a Tx packet before queueing it to avoid
           trouble with the retransmission function.
      
       (2) Don't send an ACK at the end of the service reply transmission; it's
           the responsibility of the client to send an ACK to close the call.
           The service can resend the last DATA packet or send a PING ACK.
      
       (3) Wake sendmsg() on abnormal call termination.
      
       (4) Use ktime_add_ms() not ktime_add_ns() to add millisecond offsets.
      
       (5) Use before_eq() & co. to compare serial numbers (which may wrap).
      
       (6) Start the resend timer on DATA packet transmission.
      
       (7) Don't accidentally cancel a retransmission upon receiving a NACK.
      
       (8) Fix the call timer setting function to deal with timeouts that are now
           or past.
      
       (9) Don't use a flag to communicate the presence of the last packet in the
           Tx buffer from sendmsg to the input routines where ACK and DATA
           reception is handled.  The problem is that there's a window between
           queueing the last packet for transmission and setting the flag in
           which ACKs or reply DATA packets can arrive, causing apparent state
           machine violation issues.
      
           Instead use the annotation buffer to mark the last packet and pick up
           and set the flag in the input routines.
      
      (10) Don't call the tx_ack tracepoint and don't allocate a serial number if
           someone else nicked the ACK we were about to transmit.
      
      There are also new tracepoints and one altered tracepoint used to track
      down the above bugs:
      
      (11) Call timer tracepoint.
      
      (12) Data Tx tracepoint (and adjustments to ACK tracepoint).
      
      (13) Injected Rx packet loss tracepoint.
      
      (14) Ack proposal tracepoint.
      
      (15) Retransmission selection tracepoint.
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      2a9aa41f
    • D
      Merge branch '10GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue · 3eb193e0
      David S. Miller 提交于
      Jeff Kirsher says:
      
      ====================
      10GbE Intel Wired LAN Driver Updates 2016-09-23
      
      This series contains updates to ixgbe and ixgbevf.
      
      Emil provides several changes, first simplifies the logic for setting VLAN
      filtering by checking the VMDQ flag and the old 82598 MAC, instead of
      having to maintain a list of MAC types.  Then made two functions static
      that are used only within the file, a by-product is sparse is now happy.
      Added spinlocks to make sure that the MTU configuration is handled
      properly.  Fixed an issue where when SR-IOV is enabled while the
      ixgbevf driver is loaded would result in all mailbox requests being
      rejected by ixgbe, so call ixgbe_sriov_reinit() before pci_enable_sriov()
      to ensure mailbox requests are properly handled.
      
      Mark resolves a NULL pointer issue by simply setting the read and write
      *_ref_mdi pointers for x550em_a devices.  Then clearly indicates within
      ethtool that all MACs support pause frames and made sure that the
      advertising is set to the requested mode.  Fixed an issue where
      MDIO_PRTAD_NONE was not being used consistently to indicate no PHY
      address.
      
      Alex fixes an issue, where the support for multiple queues when SR-IOV
      is enabled was added but the support was not reported.  With that, fix
      an issue where the hardware redirection table could support more queues
      then the PF currently has when SR-IOV is enabled, so use the RSS mask to
      trim off the bits that are not used.  Lastly, instead of limiting the
      VFs if we do not use 4 queues for RSS in the PF, we can instead just limit
      the RSS queues used to a power of 2.  We can now support use cases where
      VFs are using more queues than the PF is currently using and can support
      RSS if so desired.
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      3eb193e0
    • D
      Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/klassert/ipsec-next · 1678c113
      David S. Miller 提交于
      Steffen Klassert says:
      
      ====================
      pull request (net-next): ipsec-next 2016-09-23
      
      Only two patches this time:
      
      1) Fix a comment reference to struct xfrm_replay_state_esn.
         From Richard Guy Briggs.
      
      2) Convert xfrm_state_lookup to rcu, we don't need the
         xfrm_state_lock anymore in the input path.
         From Florian Westphal.
      
      Please pull or let me know if there are problems.
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      1678c113
    • D
      Merge branch '40GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue · 834d9649
      David S. Miller 提交于
      Jeff Kirsher says:
      
      ====================
      40GbE Intel Wired LAN Driver Updates 2016-09-22
      
      This series contains updates to i40e and i40evf only.
      
      Sridhar fixes link state event handling by updating the carrier and
      starts/stops the Tx queues based on the link state notification from PF.
      
      Brady fixes an issue where a user defined RSS hash key was not being
      set because a user defined indirection table is not supplied when changing
      the hash key, so if an indirection table is not supplied now, then a
      default one is created and the hash key is correctly set.  Also fixed
      an issue where when NPAR was enabled, we were still using pf->mac_seid
      to perform the dump port query. Instead, go through the VSI to determine
      the correct ID to use in either case.
      
      Mitch provides one fix where a conditional return code was reversed, so
      he does a "switheroo" to fix the issue.
      
      Carolyn has two fixes, first fixes an issue in the virt channel code,
      where a return code was not checked for NULL when applicable.  Second,
      fixes an issue where we were byte swapping the port parameter, then
      byte swapping it again in function execution.
      
      Colin Ian King fixes a potential NULL pointer dereference.
      
      Bimmy changes up i40evf_up_complete() to be void since it always returns
      success anyways, which allows cleaning up of code which checked the
      return code from this function.
      
      Alex fixed an issue where the driver was incorrectly assuming that we
      would always be pulling no more than 1 descriptor from each fragment.
      So to correct this, we just need to make certain to test all the way to
      the end of the fragments as it is possible for us to span 2 descriptors
      in the block before us so we need to guarantee that even the last 6
      descriptors have enough data to fill a full frame.
      
      v2: dropped patches 1-3, 10 and 12 from the original series since Or
          Gerlitz pointed out several areas of improvement in the implementation
          of the VF Port representor netdev.  Sridhar is re-working the series
          for later submission.
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      834d9649
    • D
      Merge branch 'mlx4-vf-vlan-802.1ad' · 1ad0751d
      David S. Miller 提交于
      Tariq Toukan says:
      
      ====================
      mlx4 VF vlan protocol 802.1ad support
      
      This patchset adds VF VLAN protocol 802.1ad support to the
      mlx4 driver.
      We extended the VF VLAN API with an additional parameter
      for VLAN protocol, and kept 802.1Q as drivers' default.
      
      We prepared a userspace support (ip link tool).
      The patch will be submitted to the iproute2 mailing list.
      
      The ip link tool VF VLAN protocol parameter is optional (default: 802.1Q).
      A configuration command of VF VLAN that is used prior to this patchset
      will result in same functionality as today's (VST with VLAN protocol 802.1Q).
      
      The series generated against net-next commit:
      688dc536 "Merge branch 'mlx4-next'"
      
      All maintainers of the modified modules are in cc.
      
      v3:
        Expand the UAPI to a nested list to support future use-cases.
        Use a more formal feature name.
      
      v2:
        Drop patch 4 ("net/mlx4_core: Add an option to configure SVLAN TPID").
        Patch 1/5: Update commit log.
        2-3/5: Split patch 2 into two patches, to separate between changes
               done in mlx4_core and the ones done in mlx4_en.
        4-5/5: Split patch 3 into two patches, to separate between the
               addition of a protocol parameter and the actual implementation
      	 in mlx4_en.
      	 In addition, we implement a handshake mechanism so PF and VF
      	 exchange their VST QinQ support capability.
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      1ad0751d
    • M
      net/mlx4: Add VF vlan protocol 802.1ad support · b42959dc
      Moshe Shemesh 提交于
      Move the vf to VST 802.1ad mode (mlx4 VST QinQ mode) by setting vf vlan
      protocol to 802.1ad.
      VST 802.1ad mode in mlx4, is used for STAG strip/insertion by PF, while
      the CTAG is set by the VF.
      Read current vlan protocol as part of the vf configuration state.
      
      Upon setting vf vlan protocol to 802.1ad, we use a mechanism of handshake
      to verify that both the vf and the pf driver version support it.
      The handshake uses the command QUERY_FUNC_CAP:
      - The vf sets a pre-defined support bit in input modifier.
      - A pf that supports the feature sends the request to the vf through a
        pre-defined field in the output mailbox.
      - In case vf does not support the feature, the pf will fail the control
        command (in this case, IP link tool command to set the vf vlan
        protocol to 802.1ad).
      
      No change in VST 802.1Q mode.
      Signed-off-by: NMoshe Shemesh <moshe@mellanox.com>
      Signed-off-by: NTariq Toukan <tariqt@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      b42959dc
    • M
      net: Update API for VF vlan protocol 802.1ad support · 79aab093
      Moshe Shemesh 提交于
      Introduce new rtnl UAPI that exposes a list of vlans per VF, giving
      the ability for user-space application to specify it for the VF, as an
      option to support 802.1ad.
      We adjusted IP Link tool to support this option.
      
      For future use cases, the new UAPI supports multiple vlans. For now we
      limit the list size to a single vlan in kernel.
      Add IFLA_VF_VLAN_LIST in addition to IFLA_VF_VLAN to keep backward
      compatibility with older versions of IP Link tool.
      
      Add a vlan protocol parameter to the ndo_set_vf_vlan callback.
      We kept 802.1Q as the drivers' default vlan protocol.
      Suitable ip link tool command examples:
        Set vf vlan protocol 802.1ad:
          ip link set eth0 vf 1 vlan 100 proto 802.1ad
        Set vf to VST (802.1Q) mode:
          ip link set eth0 vf 1 vlan 100 proto 802.1Q
        Or by omitting the new parameter
          ip link set eth0 vf 1 vlan 100
      Signed-off-by: NMoshe Shemesh <moshe@mellanox.com>
      Signed-off-by: NTariq Toukan <tariqt@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      79aab093
    • M
      net/mlx4_en: Disable vlan HW acceleration when in VF vlan protocol 802.1ad mode · 0815fe3a
      Moshe Shemesh 提交于
      In Ethernet VF, disable vlan HW acceleration on VF
      while it is set to VF vlan protocol 802.1ad mode.
      Signed-off-by: NMoshe Shemesh <moshe@mellanox.com>
      Signed-off-by: NTariq Toukan <tariqt@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      0815fe3a
    • M
      net/mlx4_core: Preparation for VF vlan protocol 802.1ad · 7c3d21c8
      Moshe Shemesh 提交于
      Check device capability to support VF vlan protocol 802.1ad mode.
      Add vport attribute vlan protocol.
      Init vport vlan protocol by default to 802.1Q.
      Add update QP support for VF vlan protocol 802.1ad.
      Add func capability vlan_offload_disable to disable all
      vlan HW acceleration on VF while the VF is set to VF vlan protocol
      802.1ad mode.
      No change in VF vlan protocol 802.1Q (VST) mode.
      Signed-off-by: NMoshe Shemesh <moshe@mellanox.com>
      Signed-off-by: NTariq Toukan <tariqt@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      7c3d21c8
    • M
      net/mlx4_core: Fix QUERY FUNC CAP flags · c9cc599a
      Moshe Shemesh 提交于
      Separate QUERY_FUNC_CAP flags0 from QUERY_FUNC_CAP flags, as 'flags' is
      already used for another set of flags in FUNC CAP, while phv bit should be
      part of a different set of flags.
      Remove QUERY_FUNC_CAP port_flags field, as it is not in use.
      
      Fixes: 77fc29c4 ('net/mlx4_core: Preparations for 802.1ad VLAN support')
      Fixes: 5cc914f1 ('mlx4_core: Added FW commands and their wrappers for supporting SRIOV')
      Signed-off-by: NMoshe Shemesh <moshe@mellanox.com>
      Signed-off-by: NTariq Toukan <tariqt@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c9cc599a
  3. 23 9月, 2016 11 次提交
    • D
      rxrpc: Add a tracepoint to log which packets will be retransmitted · c6672e3f
      David Howells 提交于
      Add a tracepoint to log in rxrpc_resend() which packets will be
      retransmitted.  Note that if a positive ACK comes in whilst we have dropped
      the lock to retransmit another packet, the actual retransmission may not
      happen, though some of the effects will (such as altering the congestion
      management).
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      c6672e3f
    • D
      rxrpc: Add tracepoint for ACK proposal · 9c7ad434
      David Howells 提交于
      Add a tracepoint to log proposed ACKs, including whether the proposal is
      used to update a pending ACK or is discarded in favour of an easlier,
      higher priority ACK.
      
      Whilst we're at it, get rid of the rxrpc_acks() function and access the
      name array directly.  We do, however, need to validate the ACK reason
      number given to trace_rxrpc_rx_ack() to make sure we don't overrun the
      array.
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      9c7ad434
    • D
      rxrpc: Add a tracepoint to log injected Rx packet loss · 89b475ab
      David Howells 提交于
      Add a tracepoint to log received packets that get discarded due to Rx
      packet loss.
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      89b475ab
    • D
      rxrpc: Add data Tx tracepoint and adjust Tx ACK tracepoint · be832aec
      David Howells 提交于
      Add a tracepoint to log transmission of DATA packets (including loss
      injection).
      
      Adjust the ACK transmission tracepoint to include the packet serial number
      and to line this up with the DATA transmission display.
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      be832aec
    • D
      rxrpc: Add a tracepoint for the call timer · fc7ab6d2
      David Howells 提交于
      Add a tracepoint to log call timer initiation, setting and expiry.
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      fc7ab6d2
    • D
      rxrpc: Don't call the tx_ack tracepoint if don't generate an ACK · b86e218e
      David Howells 提交于
      rxrpc_send_call_packet() is invoking the tx_ack tracepoint before it checks
      whether there's an ACK to transmit (another thread may jump in and transmit
      it).
      
      Fix this by only invoking the tracepoint if we get a valid ACK to transmit.
      
      Further, only allocate a serial number if we're going to actually transmit
      something.
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      b86e218e
    • D
      rxrpc: Pass the last Tx packet marker in the annotation buffer · 70790dbe
      David Howells 提交于
      When the last packet of data to be transmitted on a call is queued, tx_top
      is set and then the RXRPC_CALL_TX_LAST flag is set.  Unfortunately, this
      leaves a race in the ACK processing side of things because the flag affects
      the interpretation of tx_top and also allows us to start receiving reply
      data before we've finished transmitting.
      
      To fix this, make the following changes:
      
       (1) rxrpc_queue_packet() now sets a marker in the annotation buffer
           instead of setting the RXRPC_CALL_TX_LAST flag.
      
       (2) rxrpc_rotate_tx_window() detects the marker and sets the flag in the
           same context as the routines that use it.
      
       (3) rxrpc_end_tx_phase() is simplified to just shift the call state.
           The Tx window must have been rotated before calling to discard the
           last packet.
      
       (4) rxrpc_receiving_reply() is added to handle the arrival of the first
           DATA packet of a reply to a client call (which is an implicit ACK of
           the Tx phase).
      
       (5) The last part of rxrpc_input_ack() is reordered to perform Tx
           rotation, then soft-ACK application and then to end the phase if we've
           rotated the last packet.  In the event of a terminal ACK, the soft-ACK
           application will be skipped as nAcks should be 0.
      
       (6) rxrpc_input_ackall() now has to rotate as well as ending the phase.
      
      In addition:
      
       (7) Alter the transmit tracepoint to log the rotation of the last packet.
      
       (8) Remove the no-longer relevant queue_reqack tracepoint note.  The
           ACK-REQUESTED packet header flag is now set as needed when we actually
           transmit the packet and may vary by retransmission.
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      70790dbe
    • D
      rxrpc: Fix call timer · 01a88f7f
      David Howells 提交于
      Fix the call timer in the following ways:
      
       (1) If call->resend_at or call->ack_at are before or equal to the current
           time, then ignore that timeout.
      
       (2) If call->expire_at is before or equal to the current time, then don't
           set the timer at all (possibly we should queue the call).
      
       (3) Don't skip modifying the timer if timer_pending() is true.  This
           indicates that the timer is working, not that it has expired and is
           running/waiting to run its expiry handler.
      
      Also call rxrpc_set_timer() to start the call timer going rather than
      calling add_timer().
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      01a88f7f
    • D
      rxrpc: Fix accidental cancellation of scheduled resend by ACK parser · be8aa338
      David Howells 提交于
      When rxrpc_input_soft_acks() is parsing the soft-ACKs from an ACK packet,
      it updates the Tx packet annotations in the annotation buffer.  If a
      soft-ACK is an ACK, then we overwrite unack'd, nak'd or to-be-retransmitted
      states and that is fine; but if the soft-ACK is an NACK, we overwrite the
      to-be-retransmitted with a nak - which isn't.
      
      Instead, we need to let any scheduled retransmission stand if the packet
      was NAK'd.
      
      Note that we don't reissue a resend if the annotation is in the
      to-be-retransmitted state because someone else must've scheduled the
      resend already.
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      be8aa338
    • D
      Revert "xen-netback: create a debugfs node for hash information" · fb2a3d5c
      David S. Miller 提交于
      This reverts commit c0c64c15.
      
      There is no vif->ctrl_task member, so this change broke
      the build.
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      fb2a3d5c
    • D
      rxrpc: Need to start the resend timer on initial transmission · dfc3da44
      David Howells 提交于
      When a DATA packet has its initial transmission, we may need to start or
      adjust the resend timer.  Without this we end up relying on being sent a
      NACK to initiate the resend.
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      dfc3da44