All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alex Elder <elder@inktank.com>
To: ceph-devel@vger.kernel.org
Subject: [PATCH 7/7] rbd: drop "object_name" from rbd_req_sync_unwatch()
Date: Thu, 26 Jul 2012 13:57:55 -0500	[thread overview]
Message-ID: <50119333.50908@inktank.com> (raw)
In-Reply-To: <50119076.1030307@inktank.com>

rbd_req_sync_unwatch() only ever uses rbd_dev->header_name as the
value of its "object_name" parameter, and that value is available
within the function already.  So get rid of the parameter.

Signed-off-by: Alex Elder <elder@inktank.com>
---
 drivers/block/rbd.c |    9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/drivers/block/rbd.c b/drivers/block/rbd.c
index 48a7927..fd5f3038 100644
--- a/drivers/block/rbd.c
+++ b/drivers/block/rbd.c
@@ -1279,8 +1279,7 @@ fail:
 /*
  * Request sync osd unwatch
  */
-static int rbd_req_sync_unwatch(struct rbd_device *rbd_dev,
-				const char *object_name)
+static int rbd_req_sync_unwatch(struct rbd_device *rbd_dev)
 {
 	struct ceph_osd_req_op *ops;

@@ -1297,7 +1296,9 @@ static int rbd_req_sync_unwatch(struct rbd_device
*rbd_dev,
 			      0,
 			      CEPH_OSD_FLAG_WRITE | CEPH_OSD_FLAG_ONDISK,
 			      ops,
-			      object_name, 0, 0, NULL, NULL, NULL);
+			      rbd_dev->header_name,
+			      0, 0, NULL, NULL, NULL);
+

 	rbd_destroy_ops(ops);
 	ceph_osdc_cancel_event(rbd_dev->watch_event);
@@ -2563,7 +2564,7 @@ static void rbd_dev_release(struct device *dev)
 						    rbd_dev->watch_request);
 	}
 	if (rbd_dev->watch_event)
-		rbd_req_sync_unwatch(rbd_dev, rbd_dev->header_name);
+		rbd_req_sync_unwatch(rbd_dev);

 	rbd_put_client(rbd_dev);

-- 
1.7.9.5


  parent reply	other threads:[~2012-07-26 18:57 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-26 18:46 [PATCH 0/7] rbd: drop unused parameters from functions Alex Elder
2012-07-26 18:57 ` [PATCH 1/7] rbd: snapc is unused in rbd_req_sync_read() Alex Elder
2012-07-26 18:57 ` [PATCH 2/7] rbd: drop rbd_header_from_disk() gfp_flags parameter Alex Elder
2012-07-26 18:57 ` [PATCH 3/7] rbd: drop rbd_dev parameter in snap functions Alex Elder
2012-07-26 18:57 ` [PATCH 4/7] rbd: drop "object_name" from rbd_req_sync_watch() Alex Elder
2012-07-26 18:57 ` [PATCH 5/7] rbd: drop "object_name" from rbd_req_sync_notify() Alex Elder
2012-07-26 18:57 ` [PATCH 6/7] rbd: drop "object_name" from rbd_req_sync_notify_ack() Alex Elder
2012-07-26 18:57 ` Alex Elder [this message]
2012-07-26 19:35 ` [PATCH 0/7] rbd: drop unused parameters from functions Josh Durgin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=50119333.50908@inktank.com \
    --to=elder@inktank.com \
    --cc=ceph-devel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.