1. 04 11月, 2012 9 次提交
    • S
      smsc75xx: add wol support for more frame types · 899a391b
      Steve Glendinning 提交于
      This patch adds support for wol wakeup on unicast, broadcast,
      multicast and arp frames.
      Signed-off-by: NSteve Glendinning <steve.glendinning@shawell.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      899a391b
    • A
      if_ether.h: add B.A.T.M.A.N.-Advanced Ethertype · 4f99ad51
      Antonio Quartulli 提交于
      Add Ethertype 0x4305 (not an officially registered id).
      This Ethertype is used by every frame generated by B.A.T.M.A.N.-Advanced. Its
      definition is currently batman-adv local only and since it is not officially
      registered it is better to make its definition kernel-wide so that we avoid
      collisions given by future unofficial uses of the same Ethertype.
      Signed-off-by: NAntonio Quartulli <ordex@autistici.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      4f99ad51
    • K
      r8169: Kill SafeMtu macro · 4d44a9ab
      Kirill Smelkov 提交于
      After d58d46b5 (r8169: jumbo fixes.) max frame len is stored in
      rtl_chip_infos[].jumbo_max for each chip and SafeMtu should be gone.
      Signed-off-by: NKirill Smelkov <kirr@mns.spb.ru>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      4d44a9ab
    • A
      ipv6: introduce ip6_rt_put() · 94e187c0
      Amerigo Wang 提交于
      As suggested by Eric, we could introduce a helper function
      for ipv6 too, to avoid checking if rt is NULL before
      dst_release().
      
      Cc: Eric Dumazet <eric.dumazet@gmail.com>
      Cc: David S. Miller <davem@davemloft.net>
      Signed-off-by: NCong Wang <amwang@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      94e187c0
    • E
      ipv4: avoid a test in ip_rt_put() · 6da025fa
      Eric Dumazet 提交于
      We can save a test in ip_rt_put(), considering dst_release() accepts
      a NULL parameter, and dst is first element in rtable.
      
      Add a BUILD_BUG_ON() to catch any change that could break this
      assertion.
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Cc: Cong Wang <amwang@redhat.com>
      Acked-by: NCong Wang <amwang@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      6da025fa
    • N
      sctp: Clean up type-punning in sctp_cmd_t union · b26ddd81
      Neil Horman 提交于
      Lots of points in the sctp_cmd_interpreter function treat the sctp_cmd_t arg as
      a void pointer, even though they are written as various other types.  Theres no
      need for this as doing so just leads to possible type-punning issues that could
      cause crashes, and if we remain type-consistent we can actually just remove the
      void * member of the union entirely.
      
      Change Notes:
      
      v2)
      	* Dropped chunk that modified SCTP_NULL to create a marker pattern
      	 should anyone try to use a SCTP_NULL() assigned sctp_arg_t, Assigning
      	 to .zero provides the same effect and should be faster, per Vlad Y.
      
      v3)
      	* Reverted part of V2, opting to use memset instead of .zero, so that
      	 the entire union is initalized thus avoiding the i164 speculative load
      	 problems previously encountered, per Dave M..  Also rewrote
      	 SCTP_[NO]FORCE so as to use common infrastructure a little more
      
      Signed-off-by: Neil Horman <nhorman@tuxdriver.com
      CC: Vlad Yasevich <vyasevich@gmail.com>
      CC: "David S. Miller" <davem@davemloft.net>
      CC: linux-sctp@vger.kernel.org
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      b26ddd81
    • A
      ipv6: remove a useless NULL check · 1a940835
      Amerigo Wang 提交于
      In dev_forward_change(), it is useless to check if idev->dev
      is NULL, it is always non-NULL here.
      Reported-by: NFengguang Wu <fengguang.wu@intel.com>
      Cc: David S. Miller <davem@davemloft.net>
      Signed-off-by: NCong Wang <amwang@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      1a940835
    • D
      pktgen: clean up ktime_t helpers · 398f382c
      Daniel Borkmann 提交于
      Some years ago, the ktime_t helper functions ktime_now() and ktime_lt()
      have been introduced. Instead of defining them inside pktgen.c, they
      should either use ktime_t library functions or, if not available, they
      should be defined in ktime.h, so that also others can benefit from them.
      ktime_compare() is introduced with a similar notion as in timespec_compare().
      Signed-off-by: NDaniel Borkmann <daniel.borkmann@tik.ee.ethz.ch>
      Cc: Cong Wang <xiyou.wangcong@gmail.com>
      Cc: Stephen Hemminger <shemminger@vyatta.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Acked-by: NThomas Gleixner <tglx@linutronix.de>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      398f382c
    • E
      tcp: better retrans tracking for defer-accept · e6c022a4
      Eric Dumazet 提交于
      For passive TCP connections using TCP_DEFER_ACCEPT facility,
      we incorrectly increment req->retrans each time timeout triggers
      while no SYNACK is sent.
      
      SYNACK are not sent for TCP_DEFER_ACCEPT that were established (for
      which we received the ACK from client). Only the last SYNACK is sent
      so that we can receive again an ACK from client, to move the req into
      accept queue. We plan to change this later to avoid the useless
      retransmit (and potential problem as this SYNACK could be lost)
      
      TCP_INFO later gives wrong information to user, claiming imaginary
      retransmits.
      
      Decouple req->retrans field into two independent fields :
      
      num_retrans : number of retransmit
      num_timeout : number of timeouts
      
      num_timeout is the counter that is incremented at each timeout,
      regardless of actual SYNACK being sent or not, and used to
      compute the exponential timeout.
      
      Introduce inet_rtx_syn_ack() helper to increment num_retrans
      only if ->rtx_syn_ack() succeeded.
      
      Use inet_rtx_syn_ack() from tcp_check_req() to increment num_retrans
      when we re-send a SYNACK in answer to a (retransmitted) SYN.
      Prior to this patch, we were not counting these retransmits.
      
      Change tcp_v[46]_rtx_synack() to increment TCP_MIB_RETRANSSEGS
      only if a synack packet was successfully queued.
      Reported-by: NYuchung Cheng <ycheng@google.com>
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Cc: Julian Anastasov <ja@ssi.bg>
      Cc: Vijay Subramanian <subramanian.vijay@gmail.com>
      Cc: Elliott Hughes <enh@google.com>
      Cc: Neal Cardwell <ncardwell@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      e6c022a4
  2. 03 11月, 2012 15 次提交
  3. 02 11月, 2012 16 次提交