Skip to content

blktrace: startup / shutdown race fixes

Andy Isaacson lkml 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2blktrace: use cmpxchgkernel/trace/blktrace.c+5 -90 replies
2/2blktrace: unlink blk directory on final trace closekernel/trace/blktrace.c+4 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/2] blktrace: startup / shutdown race fixes

I ran into the stale-block-directory problem while using blktrace, and while chasing it noticed the open-coded cmpxchg.

The unlink-on-final-close is a longstanding bug that's triggerable by the standard blktrace(1) utility (it races child threads against the parent), and should go to -stable. The cmpxchg is a startup race that may be easy to maliciously trigger from userspace, but is unlikely to be triggered accidentally. (Famous last words...)

Andy Isaacson (2):
blktrace: use cmpxchg
blktrace: unlink blk directory on final trace close

 kernel/trace/blktrace.c |   18 +++++++++---------
 1 files changed, 9 insertions(+), 9 deletions(-)