aboutsummaryrefslogtreecommitdiff
path: root/scripts/gdb/linux/genpd.py
diff options
context:
space:
mode:
authorChristoph Hellwig <[email protected]>2020-01-26 14:05:43 +0100
committerJens Axboe <[email protected]>2020-01-26 09:59:08 -0700
commitb72053072c0bbe9f1cdfe2ffa3c201c185da2201 (patch)
treeee33c0d04b60c7e8bfb88bfafd486c72e4d51a3a /scripts/gdb/linux/genpd.py
parentad6bf88a6c19a39fb3b0045d78ea880325dfcf15 (diff)
block: allow partitions on host aware zone devices
Host-aware SMR drives can be used with the commands to explicitly manage zone state, but they can also be used as normal disks. In the former case it makes perfect sense to allow partitions on them, in the latter it does not, just like for host managed devices. Add a check to add_partition to allow partitions on host aware devices, but give up any zone management capabilities in that case, which also catches the previously missed case of adding a partition vs just scanning it. Because sd can rescan the attribute at runtime it needs to check if a disk has partitions, for which a new helper is added to genhd.h. Fixes: 5eac3eb30c9a ("block: Remove partition support for zoned block devices") Reported-by: Borislav Petkov <[email protected]> Signed-off-by: Christoph Hellwig <[email protected]> Tested-by: Damien Le Moal <[email protected]> Reviewed-by: Damien Le Moal <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
Diffstat (limited to 'scripts/gdb/linux/genpd.py')
0 files changed, 0 insertions, 0 deletions