summaryrefslogtreecommitdiffstats
path: root/drivers/block
diff options
context:
space:
mode:
authorIlya Dryomov <idryomov@gmail.com>2019-08-30 11:31:06 -0400
committerIlya Dryomov <idryomov@gmail.com>2019-09-16 06:06:25 -0400
commit21ed05a8bae76b5163996e0bbcaa35cd9eff41d7 (patch)
treebef3e56644513acff055d298f0a38db3d8b81a3a /drivers/block
parent71a228bc8d65900179e37ac309e678f8c523f133 (diff)
rbd: pull rbd_img_request_create() dout out into the callers
Make it more informative: log op_type, offset and length for block layer requests and initiating obj_req for child requests. Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'drivers/block')
-rw-r--r--drivers/block/rbd.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/block/rbd.c b/drivers/block/rbd.c
index 69db7385c8df..7c4350c0fb77 100644
--- a/drivers/block/rbd.c
+++ b/drivers/block/rbd.c
@@ -1754,8 +1754,6 @@ static struct rbd_img_request *rbd_img_request_create(
1754 mutex_init(&img_request->state_mutex); 1754 mutex_init(&img_request->state_mutex);
1755 kref_init(&img_request->kref); 1755 kref_init(&img_request->kref);
1756 1756
1757 dout("%s: rbd_dev %p %s -> img %p\n", __func__, rbd_dev,
1758 obj_op_name(op_type), img_request);
1759 return img_request; 1757 return img_request;
1760} 1758}
1761 1759
@@ -2944,6 +2942,9 @@ static int rbd_obj_read_from_parent(struct rbd_obj_request *obj_req)
2944 __set_bit(IMG_REQ_CHILD, &child_img_req->flags); 2942 __set_bit(IMG_REQ_CHILD, &child_img_req->flags);
2945 child_img_req->obj_request = obj_req; 2943 child_img_req->obj_request = obj_req;
2946 2944
2945 dout("%s child_img_req %p for obj_req %p\n", __func__, child_img_req,
2946 obj_req);
2947
2947 if (!rbd_img_is_write(img_req)) { 2948 if (!rbd_img_is_write(img_req)) {
2948 switch (img_req->data_type) { 2949 switch (img_req->data_type) {
2949 case OBJ_REQUEST_BIO: 2950 case OBJ_REQUEST_BIO:
@@ -4877,6 +4878,9 @@ static void rbd_queue_workfn(struct work_struct *work)
4877 img_request->rq = rq; 4878 img_request->rq = rq;
4878 snapc = NULL; /* img_request consumes a ref */ 4879 snapc = NULL; /* img_request consumes a ref */
4879 4880
4881 dout("%s rbd_dev %p img_req %p %s %llu~%llu\n", __func__, rbd_dev,
4882 img_request, obj_op_name(op_type), offset, length);
4883
4880 if (op_type == OBJ_OP_DISCARD || op_type == OBJ_OP_ZEROOUT) 4884 if (op_type == OBJ_OP_DISCARD || op_type == OBJ_OP_ZEROOUT)
4881 result = rbd_img_fill_nodata(img_request, offset, length); 4885 result = rbd_img_fill_nodata(img_request, offset, length);
4882 else 4886 else