[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Xen-devel] [PATCH V4 2/9] blk-zoned: update blkdev_nr_zones() with helper
- To: linux-block@xxxxxxxxxxxxxxx
- From: Chaitanya Kulkarni <chaitanya.kulkarni@xxxxxxx>
- Date: Mon, 8 Jul 2019 11:47:04 -0700
- Cc: damien.lemoal@xxxxxxx, linux-btrace@xxxxxxxxxxxxxxx, bvanassche@xxxxxxx, linux-scsi@xxxxxxxxxxxxxxx, konrad.wilk@xxxxxxxxxx, Chaitanya Kulkarni <chaitanya.kulkarni@xxxxxxx>, yuchao0@xxxxxxxxxx, colyli@xxxxxxx, linux-bcache@xxxxxxxxxxxxxxx, jaegeuk@xxxxxxxxxx, xen-devel@xxxxxxxxxxxxxxxxxxxx, kent.overstreet@xxxxxxxxx, roger.pau@xxxxxxxxxx
- Delivery-date: Mon, 08 Jul 2019 18:47:39 +0000
- Ironport-sdr: Ddfa461mcMslhxLUCvjkQtkjRFgubLF0XEXTILOhlUlZxjmwDi+XVyfQk2kqLPva4Z+bbCfjDj cEZTr/HZHuI4MvNm6yES37FeYxFev2wBeFO+FnQLUEaQhaOkCHHMq+trJyZ9OWf3di1pTzNsG5 bg51cS0c+k2tQvR1Xk81iUGQLtSINKpeho/EhiszzdKRJrL0cQK6EzmOQPYgLRXEVVkO6m1emm 1bYODjGHVI+gNj4jvVmcdUm4Z2hf6AIKx1zesenyeq/y728mjczG3QnY8EJQnvMWy99oFNILfe 5yo=
- Ironport-sdr: SkSYt/4HUgsPXVgZN4jf7guI3pPDn1HAiNIJYXEJ/xttXqc4t547Iwzjgjh93F8ihyXKVxXw63 BlRM4aojYbUc84xlfcH69BVW/RC2zsS23y6GlyZy+VWCuPw+GSltbBEpOt3XwZv4k6EEyQ6mLd OAtvN7aLTMnjI99pBsvO3MIMZDDvugRFQkdKjhnhohByZn1ZOMyZeXnOx7GdUTcUkJFIV9UdSN a0SMFg41skrl++X654jcltHz88rq0OW+kVbiKFmVM4JjDZ/MQmgaPIi8BO8h2ll6tUaP2U8nSJ J6oAKGqlkosaeYtkyVWT6DiZ
- Ironport-sdr: YRRx/EURyyId2rAn63ItMGwUJucXOYj/rfVXRkkyVSj/PtgC9c92Thdp63KOL6fYEaXTRbz/kU 1mfBfPgUOnEpRMI0FiaKN+4XSPY3ldYWJMZobspJSp2ODImnKlumR4tmOV5PAQQ9SRk3E9POWF VPn16WelTwmPiXdpUSqS8jeH0LDODQfnndrN7Ms33RFBa41zXzdS74G4tpcHX6MAZ8OgbHv1yL vhfCazKm6xZfVAQUDl0uXtbCaC0Nxr3Nufc6fjTg69fyi/C5Z3rd6iqUXjZe0g0eJdugYt0WSc KC0=
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
This patch updates the blkdev_nr_zones() with newly introduced helper
function to read the nr_sects from block device's hd_parts with the
help if part_nr_sects_read().
Signed-off-by: Chaitanya Kulkarni <chaitanya.kulkarni@xxxxxxx>
---
block/blk-zoned.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/block/blk-zoned.c b/block/blk-zoned.c
index ae7e91bd0618..5051db35c3fd 100644
--- a/block/blk-zoned.c
+++ b/block/blk-zoned.c
@@ -90,7 +90,7 @@ unsigned int blkdev_nr_zones(struct block_device *bdev)
if (!blk_queue_is_zoned(q))
return 0;
- return __blkdev_nr_zones(q, bdev->bd_part->nr_sects);
+ return __blkdev_nr_zones(q, bdev_nr_sects(bdev));
}
EXPORT_SYMBOL_GPL(blkdev_nr_zones);
--
2.17.0
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel
|