1. 04 6月, 2014 1 次提交
  2. 03 6月, 2014 9 次提交
    • B
      ethtool: Check that reserved fields of struct ethtool_rxfh are 0 · f062a384
      Ben Hutchings 提交于
      We should fail rather than silently ignoring use of these extensions.
      Signed-off-by: NBen Hutchings <ben@decadent.org.uk>
      f062a384
    • B
      ethtool: Replace ethtool_ops::{get,set}_rxfh_indir() with {get,set}_rxfh() · fe62d001
      Ben Hutchings 提交于
      ETHTOOL_{G,S}RXFHINDIR and ETHTOOL_{G,S}RSSH should work for drivers
      regardless of whether they expose the hash key, unless you try to
      set a hash key for a driver that doesn't expose it.
      Signed-off-by: NBen Hutchings <ben@decadent.org.uk>
      Acked-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      fe62d001
    • R
      bridge: Add bridge ifindex to bridge fdb notify msgs · 41c389d7
      Roopa Prabhu 提交于
      (This patch was previously posted as RFC at
      http://patchwork.ozlabs.org/patch/352677/)
      
      This patch adds NDA_MASTER attribute to neighbour attributes enum for
      bridge/master ifindex. And adds NDA_MASTER to bridge fdb notify msgs.
      
      Today bridge fdb notifications dont contain bridge information.
      Userspace can derive it from the port information in the fdb
      notification. However this is tricky in some scenarious.
      
      Example, bridge port delete notification comes before bridge fdb
      delete notifications. And we have seen problems in userspace
      when using libnl where, the bridge fdb delete notification handling code
      does not understand which bridge this fdb entry is part of because
      the bridge and port association has already been deleted.
      And these notifications (port membership and fdb) are generated on
      separate rtnl groups.
      
      Fixing the order of notifications could possibly solve the problem
      for some cases (I can submit a separate patch for that).
      
      This patch chooses to add NDA_MASTER to bridge fdb notify msgs
      because it not only solves the problem described above, but also helps
      userspace avoid another lookup into link msgs to derive the master index.
      Signed-off-by: NRoopa Prabhu <roopa@cumulusnetworks.com>
      Acked-by: NJamal Hadi Salim <jhs@mojatatu.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      41c389d7
    • D
      fib_trie: use seq_file_net rather than seq->private · 30f38d2f
      David Ahern 提交于
      Make fib_triestat_seq_show consistent with other /proc/net files and
      use seq_file_net.
      Signed-off-by: NDavid Ahern <dsahern@gmail.com>
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>
      Cc: James Morris <jmorris@namei.org>
      Cc: Hideaki YOSHIFUJI <yoshfuji@linux-ipv6.org>
      Cc: Patrick McHardy <kaber@trash.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      30f38d2f
    • E
      inetpeer: get rid of ip_id_count · 73f156a6
      Eric Dumazet 提交于
      Ideally, we would need to generate IP ID using a per destination IP
      generator.
      
      linux kernels used inet_peer cache for this purpose, but this had a huge
      cost on servers disabling MTU discovery.
      
      1) each inet_peer struct consumes 192 bytes
      
      2) inetpeer cache uses a binary tree of inet_peer structs,
         with a nominal size of ~66000 elements under load.
      
      3) lookups in this tree are hitting a lot of cache lines, as tree depth
         is about 20.
      
      4) If server deals with many tcp flows, we have a high probability of
         not finding the inet_peer, allocating a fresh one, inserting it in
         the tree with same initial ip_id_count, (cf secure_ip_id())
      
      5) We garbage collect inet_peer aggressively.
      
      IP ID generation do not have to be 'perfect'
      
      Goal is trying to avoid duplicates in a short period of time,
      so that reassembly units have a chance to complete reassembly of
      fragments belonging to one message before receiving other fragments
      with a recycled ID.
      
      We simply use an array of generators, and a Jenkin hash using the dst IP
      as a key.
      
      ipv6_select_ident() is put back into net/ipv6/ip6_output.c where it
      belongs (it is only used from this file)
      
      secure_ip_id() and secure_ipv6_id() no longer are needed.
      
      Rename ip_select_ident_more() to ip_select_ident_segs() to avoid
      unnecessary decrement/increment of the number of segments.
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      73f156a6
    • A
      net: Add support for device specific address syncing · 670e5b8e
      Alexander Duyck 提交于
      This change provides a function to be used in order to break the
      ndo_set_rx_mode call into a set of address add and remove calls.  The code
      is based on the implementation of dev_uc_sync/dev_mc_sync.  Since they
      essentially do the same thing but with only one dev I simply named my
      functions __dev_uc_sync/__dev_mc_sync.
      
      I also implemented an unsync version of the functions as well to allow for
      cleanup on close.
      Signed-off-by: NAlexander Duyck <alexander.h.duyck@intel.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      670e5b8e
    • A
      6lowpan_rtnl: fix off by one while fragmentation · eb06481d
      Alexander Aring 提交于
      This patch fix a off by one error while fragmentation. If the frag_cap
      value is equal to skb_unprocessed value we need to stop the
      fragmentation loop because the last fragment which has a size of
      skb_unprocessed fits into the frag capability size.
      
      This issue was introduced by commit d4b2816d
      ("6lowpan: fix fragmentation").
      Signed-off-by: NAlexander Aring <alex.aring@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      eb06481d
    • A
      6lowpan_rtnl: fix fragmentation with two fragments · 51263fff
      Alexander Aring 提交于
      This patch fix the 6LoWPAN fragmentation for the case if we have exactly
      two fragments. The problem is that the (skb_unprocessed >= frag_cap)
      condition is always false on the second fragment after sending the first
      fragment. A fragmentation with only one fragment doesn't make any sense.
      The solution is that we use a do while loop here, that ensures we sending
      always a minimum of two fragments if we need a fragmentation.
      
      This issue was introduced by commit d4b2816d
      ("6lowpan: fix fragmentation").
      Signed-off-by: NAlexander Aring <alex.aring@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      51263fff
    • D
      genetlink: remove superfluous assignment · 2f91abd4
      Denis ChengRq 提交于
      the local variable ops and n_ops were just read out from family,
      and not changed, hence no need to assign back.
      
      Validation functions should operate on const parameters and not
      change anything.
      Signed-off-by: NCheng Renquan <crquan@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      2f91abd4
  3. 02 6月, 2014 3 次提交
  4. 31 5月, 2014 8 次提交
  5. 28 5月, 2014 4 次提交
  6. 27 5月, 2014 2 次提交
  7. 26 5月, 2014 8 次提交
    • J
      cfg80211: send events when devices are added/removed · 3bb20556
      Johannes Berg 提交于
      We're currently sending NEW_WIPHY events for renames (which
      is a bit odd, but now can't be changed), but also send them
      for really new devices that register.
      
      Also send DEL_WIPHY events when a device is removed, the
      event ID for this was already reserved.
      Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
      3bb20556
    • E
      mac80211: fix virtual monitor interface addition · 34171dc0
      Emmanuel Grumbach 提交于
      Since the commit below, cfg80211_chandef_dfs_required()
      will warn if it gets a an NL80211_IFTYPE_UNSPECIFIED iftype
      as explicitely written in the commit log.
      When an virtual monitor interface is added, its type is set
      in ieee80211_sub_if_data.vif.type, but not in
      ieee80211_sub_if_data.wdev.iftype which is passed to
      cfg80211_chandef_dfs_required() hence resulting in the
      following warning:
      
      WARNING: CPU: 1 PID: 21265 at net/wireless/chan.c:376 cfg80211_chandef_dfs_required+0xbc/0x130 [cfg80211]()
      Modules linked in: [...]
      CPU: 1 PID: 21265 Comm: ifconfig Tainted: G        W  O 3.13.11+ #12
      Hardware name: Dell Inc. Latitude E6410/0667CC, BIOS A01 03/05/2010
       0000000000000009 ffff88008f5fdb08 ffffffff817d4219 ffff88008f5fdb50
       ffff88008f5fdb40 ffffffff8106f57d 0000000000000000 0000000000000000
       ffff880081062fb8 ffff8800810604e0 0000000000000001 ffff88008f5fdba0
      Call Trace:
       [<ffffffff817d4219>] dump_stack+0x4d/0x66
       [<ffffffff8106f57d>] warn_slowpath_common+0x7d/0xa0
       [<ffffffff8106f5ec>] warn_slowpath_fmt+0x4c/0x50
       [<ffffffffa04ea4ec>] cfg80211_chandef_dfs_required+0xbc/0x130 [cfg80211]
       [<ffffffffa06b1024>] ieee80211_vif_use_channel+0x94/0x500 [mac80211]
       [<ffffffffa0684e6b>] ieee80211_add_virtual_monitor+0x1ab/0x5c0 [mac80211]
       [<ffffffffa0686ae5>] ieee80211_do_open+0xe75/0x1580 [mac80211]
       [<ffffffffa0687259>] ieee80211_open+0x69/0x70 [mac80211]
      [snip]
      
      Fixes: 00ec75fc ("cfg80211: pass the actual iftype when calling cfg80211_chandef_dfs_required()")
      Signed-off-by: NEmmanuel Grumbach <emmanuel.grumbach@intel.com>
      Acked-by: NLuciano Coelho <luciano.coelho@intel.com>
      Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
      34171dc0
    • L
      mac80211: add a single-transaction driver op to switch contexts · 1a5f0c13
      Luciano Coelho 提交于
      In some cases, when the driver is already using all the channel
      contexts it can handle at once, we have to do an in-place switch
      (ie. we cannot afford using an extra context temporarily for the
      transaction).  But some drivers may not support switching the channel
      context assigned to a vif on the fly (ie. without unassigning and
      assigning it) while others may only work if the context is changed on
      the fly, without unassigning it first.
      
      To allow these different scenarios, add a new driver operation that
      let's the driver decide how to handle an in-place switch.
      Signed-off-by: NLuciano Coelho <luciano.coelho@intel.com>
      Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
      1a5f0c13
    • P
      netfilter: bridge: fix Kconfig unmet dependencies · 1708803e
      Pablo Neira 提交于
      Before f5efc696 ("netfilter: nf_tables: Add meta expression key for
      bridge interface name"), the entire net/bridge/netfilter/ directory
      depended on BRIDGE_NF_EBTABLES, ie. on ebtables. However, that
      directory already contained the nf_tables bridge extension that
      we should allow to compile separately. In f5efc696, we tried to
      generalize this by using CONFIG_BRIDGE_NETFILTER which was not a good
      idea since this option already existed and it is dedicated to enable
      the Netfilter bridge IP/ARP filtering.
      
      Let's try to fix this mess by:
      
      1) making net/bridge/netfilter/ dependent on the toplevel
         CONFIG_NETFILTER option, just like we do with the net/netfilter and
         net/ipv{4,6}/netfilter/ directories.
      
      2) Changing 'selects' to 'depends on' NETFILTER_XTABLES for
         BRIDGE_NF_EBTABLES. I believe this problem was already before
         f5efc696:
      
      warning: (BRIDGE_NF_EBTABLES) selects NETFILTER_XTABLES which has
      unmet direct dependencies (NET && INET && NETFILTER)
      
      3) Fix ebtables/nf_tables bridge dependencies by making NF_TABLES_BRIDGE
         and BRIDGE_NF_EBTABLES dependent on BRIDGE and NETFILTER:
      
      warning: (NF_TABLES_BRIDGE && BRIDGE_NF_EBTABLES) selects
      BRIDGE_NETFILTER which has unmet direct dependencies (NET && BRIDGE &&
      NETFILTER && INET && NETFILTER_ADVANCED)
      
      net/built-in.o: In function `br_parse_ip_options':
      br_netfilter.c:(.text+0x4a5ba): undefined reference to `ip_options_compile'
      br_netfilter.c:(.text+0x4a5ed): undefined reference to `ip_options_rcv_srr'
      net/built-in.o: In function `br_nf_pre_routing_finish':
      br_netfilter.c:(.text+0x4a8a4): undefined reference to `ip_route_input_noref'
      br_netfilter.c:(.text+0x4a987): undefined reference to `ip_route_output_flow'
      make: *** [vmlinux] Error 1
      Reported-by: NJim Davis <jim.epost@gmail.com>
      Signed-off-by: NPablo Neira Ayuso <pablo@netfilter.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      1708803e
    • F
      NFC: nfc_sock_link() can be static · db3287da
      Fengguang Wu 提交于
      CC: Hiren Tandel <hirent@marvell.com>
      CC: Samuel Ortiz <sameo@linux.intel.com>
      Signed-off-by: NFengguang Wu <fengguang.wu@intel.com>
      Signed-off-by: NSamuel Ortiz <sameo@linux.intel.com>
      db3287da
    • F
      NFC: digital: digital_in_send_attrib_req() can be static · cb30caf0
      Fengguang Wu 提交于
      CC: "Mark A. Greer" <mgreer@animalcreek.com>
      CC: Samuel Ortiz <sameo@linux.intel.com>
      Signed-off-by: NFengguang Wu <fengguang.wu@intel.com>
      Signed-off-by: NSamuel Ortiz <sameo@linux.intel.com>
      cb30caf0
    • T
      NFC: digital: Randomize poll cycles · 9dc33705
      Thierry Escande 提交于
      This change adds some entropy to polling cycles, choosing the next
      polling rf technology randomly. This reflects the change done in the
      pn533 driver, avoiding possible infinite loop for devices that export 2
      targets on 2 different modulations. If the first target is not
      readable, we will stay in an error loop for ever.
      Signed-off-by: NThierry Escande <thierry.escande@linux.intel.com>
      Signed-off-by: NSamuel Ortiz <sameo@linux.intel.com>
      9dc33705
    • T
      NFC: digital: Return proper error code when sending ATR_REQ · 00e625df
      Thierry Escande 提交于
      The error code returned by digital_in_send_cmd() was not returned by
      digital_in_send_atr_req().
      Signed-off-by: NThierry Escande <thierry.escande@linux.intel.com>
      Signed-off-by: NSamuel Ortiz <sameo@linux.intel.com>
      00e625df
  8. 25 5月, 2014 1 次提交
  9. 24 5月, 2014 4 次提交