All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Christoph Böhmwalder" <christoph.boehmwalder@linbit.com>
To: Jens Axboe <axboe@kernel.dk>
Cc: drbd-dev@lists.linbit.com, linux-kernel@vger.kernel.org,
	"Lars Ellenberg" <lars.ellenberg@linbit.com>,
	"Philipp Reisner" <philipp.reisner@linbit.com>,
	linux-block@vger.kernel.org, "Cai Huoqing" <caihuoqing@baidu.com>,
	"Christoph Böhmwalder" <christoph.boehmwalder@linbit.com>
Subject: [PATCH 5/7] drbd: Replace "unsigned" with "unsigned int"
Date: Wed,  6 Apr 2022 21:07:13 +0200	[thread overview]
Message-ID: <20220406190715.1938174-6-christoph.boehmwalder@linbit.com> (raw)
In-Reply-To: <20220406190715.1938174-1-christoph.boehmwalder@linbit.com>

From: Cai Huoqing <caihuoqing@baidu.com>

when run checkpath.pl for the first patch, found that
WARNING: Prefer 'unsigned int' to bare use of 'unsigned'.
so fix it. BTW

Signed-off-by: Cai Huoqing <caihuoqing@baidu.com>
Acked-by: Christoph Böhmwalder <christoph.boehmwalder@linbit.com>
---
 drivers/block/drbd/drbd_receiver.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/block/drbd/drbd_receiver.c b/drivers/block/drbd/drbd_receiver.c
index c6c1843452ba..0825766ce910 100644
--- a/drivers/block/drbd/drbd_receiver.c
+++ b/drivers/block/drbd/drbd_receiver.c
@@ -364,7 +364,7 @@ drbd_alloc_peer_req(struct drbd_peer_device *peer_device, u64 id, sector_t secto
 	struct drbd_device *device = peer_device->device;
 	struct drbd_peer_request *peer_req;
 	struct page *page = NULL;
-	unsigned nr_pages = PFN_UP(payload_size);
+	unsigned int nr_pages = PFN_UP(payload_size);
 
 	if (drbd_insert_fault(device, DRBD_FAULT_AL_EE))
 		return NULL;
@@ -1629,9 +1629,9 @@ int drbd_submit_peer_request(struct drbd_device *device,
 	struct bio *bio;
 	struct page *page = peer_req->pages;
 	sector_t sector = peer_req->i.sector;
-	unsigned data_size = peer_req->i.size;
-	unsigned n_bios = 0;
-	unsigned nr_pages = PFN_UP(data_size);
+	unsigned int data_size = peer_req->i.size;
+	unsigned int n_bios = 0;
+	unsigned int nr_pages = PFN_UP(data_size);
 
 	/* TRIM/DISCARD: for now, always use the helper function
 	 * blkdev_issue_zeroout(..., discard=true).
-- 
2.35.1


  parent reply	other threads:[~2022-04-06 20:49 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-06 19:07 [PATCH 0/7] DRBD updates for 5.19 Christoph Böhmwalder
2022-04-06 19:07 ` [PATCH 1/7] drbd: fix duplicate array initializer Christoph Böhmwalder
2022-04-06 19:07 ` [PATCH 2/7] drbd: address enum mismatch warnings Christoph Böhmwalder
2022-04-06 19:07 ` [PATCH 3/7] block: drbd: drbd_receiver: Remove redundant assignment to err Christoph Böhmwalder
2022-04-06 19:07 ` [PATCH 4/7] drbd: Make use of PFN_UP helper macro Christoph Böhmwalder
2022-04-06 19:07 ` Christoph Böhmwalder [this message]
2022-04-06 19:07 ` [PATCH 6/7] drdb: Switch to kvfree_rcu() API Christoph Böhmwalder
2022-04-06 19:07 ` [PATCH 7/7] drbd: Return true/false (not 1/0) from bool functions Christoph Böhmwalder
2022-04-06 22:37 ` [PATCH 0/7] DRBD updates for 5.19 Jens Axboe

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=20220406190715.1938174-6-christoph.boehmwalder@linbit.com \
    --to=christoph.boehmwalder@linbit.com \
    --cc=axboe@kernel.dk \
    --cc=caihuoqing@baidu.com \
    --cc=drbd-dev@lists.linbit.com \
    --cc=lars.ellenberg@linbit.com \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=philipp.reisner@linbit.com \
    /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.