diff options
| author | Christoph Hellwig <[email protected]> | 2020-11-10 06:48:53 +0100 |
|---|---|---|
| committer | Jens Axboe <[email protected]> | 2020-12-01 14:53:39 -0700 |
| commit | e79319af6d8cfd7311fef1bfbb1c59c94e6e10a9 (patch) | |
| tree | 4ff488ec301873703f1a92c3c6dfe6416a8435e2 | |
| parent | 8d65269fe8065fee889bca5b204d711b0695a8f6 (diff) | |
block: use disk_part_iter_exit in disk_part_iter_next
Call disk_part_iter_exit in disk_part_iter_next instead of duplicating
the functionality.
Signed-off-by: Christoph Hellwig <[email protected]>
Reviewed-by: Greg Kroah-Hartman <[email protected]>
Reviewed-by: Jan Kara <[email protected]>
Reviewed-by: Hannes Reinecke <[email protected]>
Reviewed-by: Johannes Thumshirn <[email protected]>
Acked-by: Tejun Heo <[email protected]>
Signed-off-by: Jens Axboe <[email protected]>
| -rw-r--r-- | block/genhd.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/block/genhd.c b/block/genhd.c index 4e039524f92b..0bd9c41dd4cb 100644 --- a/block/genhd.c +++ b/block/genhd.c @@ -227,8 +227,7 @@ struct hd_struct *disk_part_iter_next(struct disk_part_iter *piter) int inc, end; /* put the last partition */ - disk_put_part(piter->part); - piter->part = NULL; + disk_part_iter_exit(piter); /* get part_tbl */ rcu_read_lock(); |