1. 26 6月, 2013 36 次提交
  2. 25 6月, 2013 4 次提交
    • Y
      bnx2x: Remove sparse and coccinelle warnings · c957d09f
      Yuval Mintz 提交于
      This patch solves several sparse issues as well as an unneeded semicolon
      found via coccinelle.
      Signed-off-by: NYuval Mintz <yuvalmin@broadcom.com>
      Signed-off-by: NDmitry Kravkov <dmitry@broadcom.com>
      Signed-off-by: NAriel Elior <ariele@broadcom.com>
      Signed-off-by: NEilon Greenstein <eilong@broadcom.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c957d09f
    • E
      ipv6: add include file to suppress sparse warnings · 6da334ee
      Eric Dumazet 提交于
      commit f88c91dd ("ipv6: statically link
      register_inet6addr_notifier()" added following sparse warnings :
      
      net/ipv6/addrconf_core.c:83:5: warning: symbol
      'register_inet6addr_notifier' was not declared. Should it be static?
      net/ipv6/addrconf_core.c:89:5: warning: symbol
      'unregister_inet6addr_notifier' was not declared. Should it be static?
      net/ipv6/addrconf_core.c:95:5: warning: symbol
      'inet6addr_notifier_call_chain' was not declared. Should it be static?
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Cc: Cong Wang <amwang@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      6da334ee
    • E
      tcp: remove invalid __rcu annotation · 7ae8639c
      Eric Dumazet 提交于
      struct tcp_fastopen_context has a field named tfm, which is a pointer
      to a crypto_cipher structure.
      
      It currently has a __rcu annotation, which is not needed at all.
      
      tcp_fastopen_ctx is the pointer fetched by rcu_dereference(), but once
      we have a pointer to current tcp_fastopen_context, we do not use/need
      rcu_dereference() to access tfm.
      
      This fixes a lot of sparse errors like the following :
      
      net/ipv4/tcp_fastopen.c:21:31: warning: incorrect type in argument 1 (different address spaces)
      net/ipv4/tcp_fastopen.c:21:31:    expected struct crypto_cipher *tfm
      net/ipv4/tcp_fastopen.c:21:31:    got struct crypto_cipher [noderef] <asn:4>*tfm
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Cc: Jerry Chu <hkchu@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      7ae8639c
    • D
      packet: nlmon: virtual netlink monitoring device for packet sockets · e4fc408e
      Daniel Borkmann 提交于
      Currently, there is no good possibility to debug netlink traffic that
      is being exchanged between kernel and user space. Therefore, this patch
      implements a netlink virtual device, so that netlink messages will be
      made visible to PF_PACKET sockets. Once there was an approach with a
      similar idea [1], but it got forgotten somehow.
      
      I think it makes most sense to accept the "overhead" of an extra netlink
      net device over implementing the same functionality from PF_PACKET
      sockets once again into netlink sockets. We have BPF filters that can
      already be easily applied which even have netlink extensions, we have
      RX_RING zero-copy between kernel- and user space that can be reused,
      and much more features. So instead of re-implementing all of this, we
      simply pass the skb to a given PF_PACKET socket for further analysis.
      
      Another nice benefit that comes from that is that no code needs to be
      changed in user space packet analyzers (maybe adding a dissector, but
      not more), thus out of the box, we can already capture pcap files of
      netlink traffic to debug/troubleshoot netlink problems.
      
      Also thanks goes to Thomas Graf, Flavio Leitner, Jesper Dangaard Brouer.
      
       [1] http://marc.info/?l=linux-netdev&m=113813401516110Signed-off-by: NDaniel Borkmann <dborkman@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      e4fc408e