1. 31 7月, 2007 1 次提交
  2. 15 7月, 2007 2 次提交
    • P
      [NET_SCHED]: act_api: qdisc internal reclassify support · 73ca4918
      Patrick McHardy 提交于
      The behaviour of NET_CLS_POLICE for TC_POLICE_RECLASSIFY was to return
      it to the qdisc, which could handle it internally or ignore it. With
      NET_CLS_ACT however, tc_classify starts over at the first classifier
      and never returns it to the qdisc. This makes it impossible to support
      qdisc-internal reclassification, which in turn makes it impossible to
      remove the old NET_CLS_POLICE code without breaking compatibility since
      we have two qdiscs (CBQ and ATM) that support this.
      
      This patch adds a tc_classify_compat function that handles
      reclassification the old way and changes CBQ and ATM to use it.
      
      This again is of course not fully backwards compatible with the previous
      NET_CLS_ACT behaviour. Unfortunately there is no way to fully maintain
      compatibility *and* support qdisc internal reclassification with
      NET_CLS_ACT, but this seems like the better choice over keeping the two
      incompatible options around forever.
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      73ca4918
    • P
      [NET_SCHED]: Revert "avoid transmit softirq on watchdog wakeup" optimization · 0621ed2e
      Patrick McHardy 提交于
      As noticed by Ranko Zivojnovic <ranko@spidernet.net>, calling qdisc_run
      from the timer handler can result in deadlock:
      
      > CPU#0
      >
      > qdisc_watchdog() fires and gets dev->queue_lock
      > qdisc_run()...qdisc_restart()...
      > -> releases dev->queue_lock and enters dev_hard_start_xmit()
      >
      > CPU#1
      >
      > tc del qdisc dev ...
      > qdisc_graft()...dev_graft_qdisc()...dev_deactivate()...
      > -> grabs dev->queue_lock ...
      >
      > qdisc_reset()...{cbq,hfsc,htb,netem,tbf}_reset()...qdisc_watchdog_cancel()...
      > -> hrtimer_cancel() - waiting for the qdisc_watchdog() to exit, while still
      >		        holding dev->queue_lock
      >
      > CPU#0
      >
      > dev_hard_start_xmit() returns ...
      > -> wants to get dev->queue_lock(!)
      >
      > DEADLOCK!
      
      The entire optimization is a bit questionable IMO, it moves potentially
      large parts of NET_TX_SOFTIRQ work to TIMER_SOFTIRQ/HRTIMER_SOFTIRQ,
      which kind of defeats the separation of them.
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      Acked-by: NRanko Zivojnovic <ranko@spidernet.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      0621ed2e
  3. 11 7月, 2007 2 次提交
  4. 04 5月, 2007 1 次提交
  5. 26 4月, 2007 14 次提交
  6. 15 2月, 2007 1 次提交
    • T
      [PATCH] remove many unneeded #includes of sched.h · cd354f1a
      Tim Schmielau 提交于
      After Al Viro (finally) succeeded in removing the sched.h #include in module.h
      recently, it makes sense again to remove other superfluous sched.h includes.
      There are quite a lot of files which include it but don't actually need
      anything defined in there.  Presumably these includes were once needed for
      macros that used to live in sched.h, but moved to other header files in the
      course of cleaning it up.
      
      To ease the pain, this time I did not fiddle with any header files and only
      removed #includes from .c-files, which tend to cause less trouble.
      
      Compile tested against 2.6.20-rc2 and 2.6.20-rc2-mm2 (with offsets) on alpha,
      arm, i386, ia64, mips, powerpc, and x86_64 with allnoconfig, defconfig,
      allmodconfig, and allyesconfig as well as a few randconfigs on x86_64 and all
      configs in arch/arm/configs on arm.  I also checked that no new warnings were
      introduced by the patch (actually, some warnings are removed that were emitted
      by unnecessarily included header files).
      Signed-off-by: NTim Schmielau <tim@physik3.uni-rostock.de>
      Acked-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      cd354f1a
  7. 13 2月, 2007 1 次提交
  8. 11 2月, 2007 1 次提交
  9. 03 12月, 2006 3 次提交
  10. 29 9月, 2006 1 次提交
    • P
      [NET_SCHED]: Fix fallout from dev->qdisc RCU change · 85670cc1
      Patrick McHardy 提交于
      The move of qdisc destruction to a rcu callback broke locking in the
      entire qdisc layer by invalidating previously valid assumptions about
      the context in which changes to the qdisc tree occur.
      
      The two assumptions were:
      
      - since changes only happen in process context, read_lock doesn't need
        bottem half protection. Now invalid since destruction of inner qdiscs,
        classifiers, actions and estimators happens in the RCU callback unless
        they're manually deleted, resulting in dead-locks when read_lock in
        process context is interrupted by write_lock_bh in bottem half context.
      
      - since changes only happen under the RTNL, no additional locking is
        necessary for data not used during packet processing (f.e. u32_list).
        Again, since destruction now happens in the RCU callback, this assumption
        is not valid anymore, causing races while using this data, which can
        result in corruption or use-after-free.
      
      Instead of "fixing" this by disabling bottem halfs everywhere and adding
      new locks/refcounting, this patch makes these assumptions valid again by
      moving destruction back to process context. Since only the dev->qdisc
      pointer is protected by RCU, but ->enqueue and the qdisc tree are still
      protected by dev->qdisc_lock, destruction of the tree can be performed
      immediately and only the final free needs to happen in the rcu callback
      to make sure dev_queue_xmit doesn't access already freed memory.
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      85670cc1
  11. 05 8月, 2006 1 次提交
  12. 01 7月, 2006 1 次提交
  13. 10 9月, 2005 1 次提交
  14. 30 8月, 2005 1 次提交
  15. 06 7月, 2005 2 次提交
  16. 29 6月, 2005 1 次提交
  17. 19 6月, 2005 1 次提交
  18. 04 5月, 2005 1 次提交
  19. 17 4月, 2005 1 次提交
    • L
      Linux-2.6.12-rc2 · 1da177e4
      Linus Torvalds 提交于
      Initial git repository build. I'm not bothering with the full history,
      even though we have it. We can create a separate "historical" git
      archive of that later if we want to, and in the meantime it's about
      3.2GB when imported into git - space that would just make the early
      git days unnecessarily complicated, when we don't have a lot of good
      infrastructure for it.
      
      Let it rip!
      1da177e4