1. 02 12月, 2013 1 次提交
    • F
      {pktgen, xfrm} Update IPv4 header total len and checksum after tranformation · 3868204d
      fan.du 提交于
      commit a553e4a6 ("[PKTGEN]: IPSEC support")
      tried to support IPsec ESP transport transformation for pktgen, but acctually
      this doesn't work at all for two reasons(The orignal transformed packet has
      bad IPv4 checksum value, as well as wrong auth value, reported by wireshark)
      
      - After transpormation, IPv4 header total length needs update,
        because encrypted payload's length is NOT same as that of plain text.
      
      - After transformation, IPv4 checksum needs re-caculate because of payload
        has been changed.
      
      With this patch, armmed pktgen with below cofiguration, Wireshark is able to
      decrypted ESP packet generated by pktgen without any IPv4 checksum error or
      auth value error.
      
      pgset "flag IPSEC"
      pgset "flows 1"
      Signed-off-by: NFan Du <fan.du@windriver.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      3868204d
  2. 29 7月, 2013 1 次提交
  3. 28 7月, 2013 2 次提交
  4. 12 6月, 2013 1 次提交
  5. 05 6月, 2013 1 次提交
  6. 29 5月, 2013 2 次提交
  7. 02 5月, 2013 1 次提交
  8. 30 4月, 2013 2 次提交
  9. 10 4月, 2013 1 次提交
    • A
      procfs: new helper - PDE_DATA(inode) · d9dda78b
      Al Viro 提交于
      The only part of proc_dir_entry the code outside of fs/proc
      really cares about is PDE(inode)->data.  Provide a helper
      for that; static inline for now, eventually will be moved
      to fs/proc, along with the knowledge of struct proc_dir_entry
      layout.
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      d9dda78b
  10. 19 2月, 2013 1 次提交
  11. 30 1月, 2013 2 次提交
  12. 04 11月, 2012 1 次提交
  13. 22 10月, 2012 1 次提交
  14. 11 10月, 2012 5 次提交
  15. 14 9月, 2012 1 次提交
    • N
      pktgen: fix crash with vlan and packet size less than 46 · 6af773e7
      Nishank Trivedi 提交于
      If vlan option is being specified in the pktgen and packet size
      being requested is less than 46 bytes, despite being illogical
      request, pktgen should not crash the kernel.
      
      BUG: unable to handle kernel paging request at ffff88021fb82000
      Process kpktgend_0 (pid: 1184, threadinfo ffff880215f1a000, task ffff880218544530)
      Call Trace:
      [<ffffffffa0637cd2>] ? pktgen_finalize_skb+0x222/0x300 [pktgen]
      [<ffffffff814f0084>] ? build_skb+0x34/0x1c0
      [<ffffffffa0639b11>] pktgen_thread_worker+0x5d1/0x1790 [pktgen]
      [<ffffffffa03ffb10>] ? igb_xmit_frame_ring+0xa30/0xa30 [igb]
      [<ffffffff8107ba20>] ? wake_up_bit+0x40/0x40
      [<ffffffff8107ba20>] ? wake_up_bit+0x40/0x40
      [<ffffffffa0639540>] ? spin+0x240/0x240 [pktgen]
      [<ffffffff8107b4e3>] kthread+0x93/0xa0
      [<ffffffff81615de4>] kernel_thread_helper+0x4/0x10
      [<ffffffff8107b450>] ? flush_kthread_worker+0x80/0x80
      [<ffffffff81615de0>] ? gs_change+0x13/0x13
      
      The root cause of why pktgen is not able to handle this case is due
      to comparison of signed (datalen) and unsigned data (sizeof), which
      eventually passes a huge number to skb_put().
      Signed-off-by: NNishank Trivedi <nistrive@cisco.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      6af773e7
  16. 19 5月, 2012 1 次提交
  17. 17 5月, 2012 1 次提交
  18. 16 5月, 2012 1 次提交
  19. 11 5月, 2012 1 次提交
    • E
      pktgen: fix crash at module unload · c57b5468
      Eric Dumazet 提交于
      commit 7d3d43da (net: In unregister_netdevice_notifier unregister
      the netdevices.) makes pktgen crashing at module unload.
      
      [  296.820578] BUG: spinlock bad magic on CPU#6, rmmod/3267
      [  296.820719]  lock: ffff880310c38000, .magic: ffff8803, .owner: <none>/-1, .owner_cpu: -1
      [  296.820943] Pid: 3267, comm: rmmod Not tainted 3.4.0-rc5+ #254
      [  296.821079] Call Trace:
      [  296.821211]  [<ffffffff8168a715>] spin_dump+0x8a/0x8f
      [  296.821345]  [<ffffffff8168a73b>] spin_bug+0x21/0x26
      [  296.821507]  [<ffffffff812b4741>] do_raw_spin_lock+0x131/0x140
      [  296.821648]  [<ffffffff8169188e>] _raw_spin_lock+0x1e/0x20
      [  296.821786]  [<ffffffffa00cc0fd>] __pktgen_NN_threads+0x4d/0x140 [pktgen]
      [  296.821928]  [<ffffffffa00ccf8d>] pktgen_device_event+0x10d/0x1e0 [pktgen]
      [  296.822073]  [<ffffffff8154ed4f>] unregister_netdevice_notifier+0x7f/0x100
      [  296.822216]  [<ffffffffa00d2a0b>] pg_cleanup+0x48/0x73 [pktgen]
      [  296.822357]  [<ffffffff8109528e>] sys_delete_module+0x17e/0x2a0
      [  296.822502]  [<ffffffff81699652>] system_call_fastpath+0x16/0x1b
      
      Hold the pktgen_thread_lock while splicing pktgen_threads, and test
      pktgen_exiting in pktgen_device_event() to make unload faster.
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Cc: Eric W. Biederman <ebiederm@xmission.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c57b5468
  20. 16 4月, 2012 1 次提交
  21. 23 1月, 2012 1 次提交
  22. 08 1月, 2012 1 次提交
  23. 30 11月, 2011 1 次提交
  24. 23 11月, 2011 1 次提交
  25. 21 10月, 2011 1 次提交
  26. 20 10月, 2011 1 次提交
  27. 19 10月, 2011 1 次提交
  28. 25 8月, 2011 1 次提交
  29. 28 7月, 2011 1 次提交
    • N
      net: add IFF_SKB_TX_SHARED flag to priv_flags · d8873315
      Neil Horman 提交于
      Pktgen attempts to transmit shared skbs to net devices, which can't be used by
      some drivers as they keep state information in skbs.  This patch adds a flag
      marking drivers as being able to handle shared skbs in their tx path.  Drivers
      are defaulted to being unable to do so, but calling ether_setup enables this
      flag, as 90% of the drivers calling ether_setup touch real hardware and can
      handle shared skbs.  A subsequent patch will audit drivers to ensure that the
      flag is set properly
      Signed-off-by: NNeil Horman <nhorman@tuxdriver.com>
      Reported-by: NJiri Pirko <jpirko@redhat.com>
      CC: Robert Olsson <robert.olsson@its.uu.se>
      CC: Eric Dumazet <eric.dumazet@gmail.com>
      CC: Alexey Dobriyan <adobriyan@gmail.com>
      CC: David S. Miller <davem@davemloft.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d8873315
  30. 23 5月, 2011 2 次提交
  31. 21 5月, 2011 1 次提交
    • L
      sanitize <linux/prefetch.h> usage · 268bb0ce
      Linus Torvalds 提交于
      Commit e66eed65 ("list: remove prefetching from regular list
      iterators") removed the include of prefetch.h from list.h, which
      uncovered several cases that had apparently relied on that rather
      obscure header file dependency.
      
      So this fixes things up a bit, using
      
         grep -L linux/prefetch.h $(git grep -l '[^a-z_]prefetchw*(' -- '*.[ch]')
         grep -L 'prefetchw*(' $(git grep -l 'linux/prefetch.h' -- '*.[ch]')
      
      to guide us in finding files that either need <linux/prefetch.h>
      inclusion, or have it despite not needing it.
      
      There are more of them around (mostly network drivers), but this gets
      many core ones.
      Reported-by: NStephen Rothwell <sfr@canb.auug.org.au>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      268bb0ce