1. 08 12月, 2018 13 次提交
  2. 07 12月, 2018 15 次提交
  3. 06 12月, 2018 12 次提交
    • D
      neighbor: Add extack messages for add and delete commands · 7a35a50d
      David Ahern 提交于
      Add extack messages for failures in neigh_add and neigh_delete.
      Signed-off-by: NDavid Ahern <dsahern@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      7a35a50d
    • H
      tipc: fix node keep alive interval calculation · f5d6c3e5
      Hoang Le 提交于
      When setting LINK tolerance, node timer interval will be calculated
      base on the LINK with lowest tolerance.
      
      But when calculated, the old node timer interval only updated if current
      setting value (tolerance/4) less than old ones regardless of number of
      links as well as links' lowest tolerance value.
      
      This caused to two cases missing if tolerance changed as following:
      Case 1:
      1.1/ There is one link (L1) available in the system
      1.2/ Set L1's tolerance from 1500ms => lower (i.e 500ms)
      1.3/ Then, fallback to default (1500ms) or higher (i.e 2000ms)
      
      Expected:
          node timer interval is 1500/4=375ms after 1.3
      
      Result:
      node timer interval will not being updated after changing tolerance at 1.3
      since its value 1500/4=375ms is not less than 500/4=125ms at 1.2.
      
      Case 2:
      2.1/ There are two links (L1, L2) available in the system
      2.2/ L1 and L2 tolerance value are 2000ms as initial
      2.3/ Set L2's tolerance from 2000ms => lower 1500ms
      2.4/ Disable link L2 (bring down its bearer)
      
      Expected:
          node timer interval is 2000ms/4=500ms after 2.4
      
      Result:
      node timer interval will not being updated after disabling L2 since
      its value 2000ms/4=500ms is still not less than 1500/4=375ms at 2.3
      although L2 is already not available in the system.
      
      To fix this, we start the node interval calculation by initializing it to
      a value larger than any conceivable calculated value. This way, the link
      with the lowest tolerance will always determine the calculated value.
      Acked-by: NJon Maloy <jon.maloy@ericsson.com>
      Signed-off-by: NHoang Le <hoang.h.le@dektech.com.au>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      f5d6c3e5
    • R
      net: Use of_node_name_eq for node name comparisons · bf5849f1
      Rob Herring 提交于
      Convert string compares of DT node names to use of_node_name_eq helper
      instead. This removes direct access to the node name pointer.
      
      For instances using of_node_cmp, this has the side effect of now using
      case sensitive comparisons. This should not matter for any FDT based
      system which all of these are.
      
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Claudiu Manoil <claudiu.manoil@nxp.com>
      Cc: Grygorii Strashko <grygorii.strashko@ti.com>
      Cc: Wingman Kwok <w-kwok2@ti.com>
      Cc: Murali Karicheri <m-karicheri2@ti.com>
      Cc: netdev@vger.kernel.org
      Cc: linux-omap@vger.kernel.org
      Signed-off-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      bf5849f1
    • P
      net: netem: use a list in addition to rbtree · d66280b1
      Peter Oskolkov 提交于
      When testing high-bandwidth TCP streams with large windows,
      high latency, and low jitter, netem consumes a lot of CPU cycles
      doing rbtree rebalancing.
      
      This patch uses a linear list/queue in addition to the rbtree:
      if an incoming packet is past the tail of the linear queue, it is
      added there, otherwise it is inserted into the rbtree.
      
      Without this patch, perf shows netem_enqueue, netem_dequeue,
      and rb_* functions among the top offenders. With this patch,
      only netem_enqueue is noticeable if jitter is low/absent.
      Suggested-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NPeter Oskolkov <posk@google.com>
      Reviewed-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d66280b1
    • D
      Merge branch 'net-bridge-convert-multicast-to-generic-rhashtable' · 932c4417
      David S. Miller 提交于
      Nikolay Aleksandrov says:
      
      ====================
      net: bridge: convert multicast to generic rhashtable
      
      The current bridge multicast code uses a custom rhashtable
      implementation which predates the generic rhashtable API. Patch 01
      converts it to use the generic kernel rhashtable which simplifies the
      code a lot and removes duplicated functionality. The convert also makes
      hash_elasticity obsolete as the generic rhashtable already has such
      checks and has a fixed elasticity of RHT_ELASTICITY (16 currently) so we
      emit a warning whenever elasticity is set and return RHT_ELASTICITY when
      read (patch 03). Patch 02 converts the multicast code to use non-bh RCU
      flavor as it was mixing bh and non-bh. Since now we have the generic
      rhashtable which autoshrinks we can be more liberal with the default
      hash maximum so patch 04 increases it to 4096 and moves it to a define in
      br_private.h.
      
      v3: add non-rcu br_mdb_get variant and use it where we have
          multicast_lock, drop special hash_max handling and just set it where
          needed and use non-bh RCU consistently (patch 02, new)
      v2: send the latest version of the set which handles when IGMP snooping
          is not defined, changes are in patch 01
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      932c4417
    • N
      net: bridge: increase multicast's default maximum number of entries · d08c6bc0
      Nikolay Aleksandrov 提交于
      bridge's default hash_max was 512 which is rather conservative, now that
      we're using the generic rhashtable API which autoshrinks let's increase
      it to 4096 and move it to a define in br_private.h.
      Signed-off-by: NNikolay Aleksandrov <nikolay@cumulusnetworks.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d08c6bc0
    • N
      net: bridge: mark hash_elasticity as obsolete · cf332bca
      Nikolay Aleksandrov 提交于
      Now that the bridge multicast uses the generic rhashtable interface we
      can drop the hash_elasticity option as that is already done for us and
      it's hardcoded to a maximum of RHT_ELASTICITY (16 currently). Add a
      warning about the obsolete option when the hash_elasticity is set.
      Signed-off-by: NNikolay Aleksandrov <nikolay@cumulusnetworks.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      cf332bca
    • N
      net: bridge: multicast: use non-bh rcu flavor · 4329596c
      Nikolay Aleksandrov 提交于
      The bridge multicast code has been using a mix of RCU and RCU-bh flavors
      sometimes in questionable way. Since we've moved to rhashtable just use
      non-bh RCU everywhere. In addition this simplifies freeing of objects
      and allows us to remove some unnecessary callback functions.
      
      v3: new patch
      Signed-off-by: NNikolay Aleksandrov <nikolay@cumulusnetworks.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      4329596c
    • N
      net: bridge: convert multicast to generic rhashtable · 19e3a9c9
      Nikolay Aleksandrov 提交于
      The bridge multicast code currently uses a custom resizable hashtable
      which predates the generic rhashtable interface. It has many
      shortcomings compared and duplicates functionality that is presently
      available via the generic rhashtable, so this patch removes the custom
      rhashtable implementation in favor of the kernel's generic rhashtable.
      The hash maximum is kept and the rhashtable's size is used to do a loose
      check if it's reached in which case we revert to the old behaviour and
      disable further bridge multicast processing. Also now we can support any
      hash maximum, doesn't need to be a power of 2.
      
      v3: add non-rcu br_mdb_get variant and use it where multicast_lock is
          held to avoid RCU splat, drop hash_max function and just set it
          directly
      
      v2: handle when IGMP snooping is undefined, add br_mdb_init/uninit
          placeholders
      Signed-off-by: NNikolay Aleksandrov <nikolay@cumulusnetworks.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      19e3a9c9
    • D
      Merge tag 'mlx5e-updates-2018-12-04' of git://git.kernel.org/pub/scm/linux/kernel/git/saeed/linux · ba5dfaff
      David S. Miller 提交于
      Saeed Mahameed says:
      
      ====================
      mlx5e-updates-2018-12-04
      
      This series includes updates to mlx5e netdevice driver
      
      From Saeed, Remove trailing space of tx_pause ethtool stat
      From Gal, Cleanup unused defines
      From Aya, ethtool Support for configuring of RX hash fields
      From Tariq, Improve ethtool private-flags code structure
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      ba5dfaff
    • D
      Merge branch 'u32-to-linkmode-fixes' · 7127f2fe
      David S. Miller 提交于
      Andrew Lunn says:
      
      ====================
      u32 to linkmode fixes
      
      This patchset fixes issues found in the last patchset which converted
      the phydev advertise etc, from a u32 to a linux bitmap. Most of the
      issues are the result of clearing bits which should not of been
      cleared. To make the API clearer, the idea from Heiner Kallweit was
      used, with _mod_ to indicate the function modifies just the bits it
      needs to, or _to_ to clear all bits and just set bit that need to be
      set.
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      7127f2fe
    • A
      net: phy: Fix ioctl handler when modifing MII_ADVERTISE · 9db299c7
      Andrew Lunn 提交于
      When the MII_ADVERTISE register is modified by the IOCTL handler,
      phydev->advertising needs recalculating. Use the _mod_ variant of
      mii_adv_to_linkmode_adv_t so that bits outside of the advertise
      registers are not cleared.
      
      Fixes: c0ec3c27 ("net: phy: Convert u32 phydev->lp_advertising to linkmode")
      Reported-by: NHeiner Kallweit <hkallweit1@gmail.com>
      Signed-off-by: NAndrew Lunn <andrew@lunn.ch>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      9db299c7