diff options
author | Ilya Dryomov <idryomov@gmail.com> | 2020-02-12 14:34:03 +0100 |
---|---|---|
committer | Ilya Dryomov <idryomov@gmail.com> | 2020-03-30 12:42:40 +0200 |
commit | 78b42a871a654face984c844b43c777d66adb1fe (patch) | |
tree | 24349023f427746e6d9131b3d05b9fb0ad58f71e /drivers/block/rbd.c | |
parent | 679a97d28627647e5a68dd684537e499cd741e2a (diff) |
rbd: get rid of img_request_layered_clear()
No need to clear IMG_REQ_LAYERED before destroying the request.
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'drivers/block/rbd.c')
-rw-r--r-- | drivers/block/rbd.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/block/rbd.c b/drivers/block/rbd.c index b077c0fb9f70..c61c5dd424fa 100644 --- a/drivers/block/rbd.c +++ b/drivers/block/rbd.c @@ -1358,11 +1358,6 @@ static void img_request_layered_set(struct rbd_img_request *img_request) set_bit(IMG_REQ_LAYERED, &img_request->flags); } -static void img_request_layered_clear(struct rbd_img_request *img_request) -{ - clear_bit(IMG_REQ_LAYERED, &img_request->flags); -} - static bool img_request_layered_test(struct rbd_img_request *img_request) { return test_bit(IMG_REQ_LAYERED, &img_request->flags) != 0; @@ -1661,10 +1656,8 @@ static void rbd_img_request_destroy(struct rbd_img_request *img_request) for_each_obj_request_safe(img_request, obj_request, next_obj_request) rbd_img_obj_request_del(img_request, obj_request); - if (img_request_layered_test(img_request)) { - img_request_layered_clear(img_request); + if (img_request_layered_test(img_request)) rbd_dev_parent_put(img_request->rbd_dev); - } if (rbd_img_is_write(img_request)) ceph_put_snap_context(img_request->snapc); |