Skip to content

block: fix partition use-after-free and optimization

Ming Lei linux-block 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 3 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4block: fix use-after-free on cached last_lookup partitionblock/blk-core.c block/genhd.c block/partition-generic.c +1 more+15 -143 replies
2/4block: only define 'nr_sects_seq' in hd_part for 32bit SMPblock/genhd.c block/partition-generic.c include/linux/genhd.h+11 -20 replies
3/4block: re-organize fields of 'struct hd_part'include/linux/genhd.h+8 -70 replies
4/4block: don't hold part0's refcount in IO pathblock/blk-core.c block/genhd.c+2 -20 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/4] block: fix partition use-after-free and optimization

Hi,

The 1st patch fixes one use-after-free on cached last_lookup partition.

The other 3 patches optimizes partition uses in IO path.

Ming Lei (4):
block: fix use-after-free on cached last_lookup partition
block: only define 'nr_sects_seq' in hd_part for 32bit SMP
block: re-organize fields of 'struct hd_part'
block: don't hold part0's refcount in IO path

 block/blk-core.c          | 15 ++-------------
 block/genhd.c             |  7 +++++--
 block/partition-generic.c | 12 ++++++++++--
 include/linux/genhd.h     | 25 ++++++++++++++++++-------
 4 files changed, 35 insertions(+), 24 deletions(-)
Cc Yufen Yu <[email protected]>
Cc Christoph Hellwig <[email protected]>
Cc Hou Tao <[email protected]>
Signature · 1 line
2.20.1