diff options
| author | Eric Dumazet <[email protected]> | 2011-03-24 07:13:14 +0000 |
|---|---|---|
| committer | David S. Miller <[email protected]> | 2011-03-24 07:13:14 +0000 |
| commit | ef352e7cdf714596f51ad18809404edeaa50e8fd (patch) | |
| tree | 6323cffca24cba664cd57a7245eb78647c48b914 /fs/ubifs/commit.c | |
| parent | Merge branch 'sfc-2.6.39' of git://git.kernel.org/pub/scm/linux/kernel/git/bw... (diff) | |
| download | kernel-ef352e7cdf714596f51ad18809404edeaa50e8fd.tar.gz kernel-ef352e7cdf714596f51ad18809404edeaa50e8fd.zip | |
net_sched: fix THROTTLED/RUNNING race
commit fd245a4adb52 (net_sched: move TCQ_F_THROTTLED flag)
added a race.
qdisc_watchdog() is run from softirq, so special care should be taken or
we can lose one state transition (THROTTLED/RUNNING)
Prior to fd245a4adb52, we were manipulating q->flags (qdisc->flags &=
~TCQ_F_THROTTLED;) and this manipulation could only race with
qdisc_warn_nonwc().
Since we want to avoid atomic ops in qdisc fast path - it was the
meaning of commit 371121057607e (QDISC_STATE_RUNNING dont need atomic
bit ops) - fix is to move THROTTLE bit into 'state' field, this one
being manipulated with SMP and IRQ safe operations.
Signed-off-by: Eric Dumazet <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'fs/ubifs/commit.c')
0 files changed, 0 insertions, 0 deletions
