linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] target: stop using bdevname
@ 2021-10-18  6:50 Christoph Hellwig
  2021-10-19  3:10 ` Martin K. Petersen
  2021-10-21  3:42 ` Martin K. Petersen
  0 siblings, 2 replies; 3+ messages in thread
From: Christoph Hellwig @ 2021-10-18  6:50 UTC (permalink / raw)
  To: martin.petersen; +Cc: linux-scsi, linux-kernel

Just use the %pg format specifier instead.

Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 drivers/target/target_core_iblock.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/target/target_core_iblock.c b/drivers/target/target_core_iblock.c
index 4069a1edcfa34..3113c4440735a 100644
--- a/drivers/target/target_core_iblock.c
+++ b/drivers/target/target_core_iblock.c
@@ -634,12 +634,10 @@ static ssize_t iblock_show_configfs_dev_params(struct se_device *dev, char *b)
 {
 	struct iblock_dev *ib_dev = IBLOCK_DEV(dev);
 	struct block_device *bd = ib_dev->ibd_bd;
-	char buf[BDEVNAME_SIZE];
 	ssize_t bl = 0;
 
 	if (bd)
-		bl += sprintf(b + bl, "iBlock device: %s",
-				bdevname(bd, buf));
+		bl += sprintf(b + bl, "iBlock device: %pg", bd);
 	if (ib_dev->ibd_flags & IBDF_HAS_UDEV_PATH)
 		bl += sprintf(b + bl, "  UDEV PATH: %s",
 				ib_dev->ibd_udev_path);
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] target: stop using bdevname
  2021-10-18  6:50 [PATCH] target: stop using bdevname Christoph Hellwig
@ 2021-10-19  3:10 ` Martin K. Petersen
  2021-10-21  3:42 ` Martin K. Petersen
  1 sibling, 0 replies; 3+ messages in thread
From: Martin K. Petersen @ 2021-10-19  3:10 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: martin.petersen, linux-scsi, linux-kernel


Christoph,

> Just use the %pg format specifier instead.

Applied to 5.16/scsi-staging, thanks!

-- 
Martin K. Petersen	Oracle Linux Engineering

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] target: stop using bdevname
  2021-10-18  6:50 [PATCH] target: stop using bdevname Christoph Hellwig
  2021-10-19  3:10 ` Martin K. Petersen
@ 2021-10-21  3:42 ` Martin K. Petersen
  1 sibling, 0 replies; 3+ messages in thread
From: Martin K. Petersen @ 2021-10-21  3:42 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: Martin K . Petersen, linux-kernel, linux-scsi

On Mon, 18 Oct 2021 08:50:52 +0200, Christoph Hellwig wrote:

> Just use the %pg format specifier instead.
> 
> 

Applied to 5.16/scsi-queue, thanks!

[1/1] target: stop using bdevname
      https://git.kernel.org/mkp/scsi/c/1b74ab77d62f

-- 
Martin K. Petersen	Oracle Linux Engineering

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-10-21  3:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-18  6:50 [PATCH] target: stop using bdevname Christoph Hellwig
2021-10-19  3:10 ` Martin K. Petersen
2021-10-21  3:42 ` Martin K. Petersen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).