linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] usb-storage: SCSI glue: use pr_fmt and pr_err
@ 2019-09-17 23:10 Matthias Maennich
  2019-09-18 14:39 ` Alan Stern
                   ` (3 more replies)
  0 siblings, 4 replies; 10+ messages in thread
From: Matthias Maennich @ 2019-09-17 23:10 UTC (permalink / raw)
  To: linux-kernel
  Cc: kernel-team, maennich, Alan Stern, Greg Kroah-Hartman, usb-storage

Follow common practice and retire printk(KERN_ERR ...) in favor of
pr_fmt and pr_err.

Cc: Alan Stern <stern@rowland.harvard.edu>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: usb-storage@lists.one-eyed-alien.net
Signed-off-by: Matthias Maennich <maennich@google.com>
---
 drivers/usb/storage/scsiglue.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/usb/storage/scsiglue.c b/drivers/usb/storage/scsiglue.c
index 6737fab94959..0b6fa225b352 100644
--- a/drivers/usb/storage/scsiglue.c
+++ b/drivers/usb/storage/scsiglue.c
@@ -28,6 +28,8 @@
  * status of a command.
  */
 
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include <linux/blkdev.h>
 #include <linux/dma-mapping.h>
 #include <linux/module.h>
@@ -379,8 +381,7 @@ static int queuecommand_lck(struct scsi_cmnd *srb,
 
 	/* check for state-transition errors */
 	if (us->srb != NULL) {
-		printk(KERN_ERR "usb-storage: Error in %s: us->srb = %p\n",
-			__func__, us->srb);
+		pr_err("Error in %s: us->srb = %p\n", __func__, us->srb);
 		return SCSI_MLQUEUE_HOST_BUSY;
 	}
 
-- 
2.23.0.237.gc6a4ce50a0-goog


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

end of thread, other threads:[~2019-10-07 11:26 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-17 23:10 [PATCH] usb-storage: SCSI glue: use pr_fmt and pr_err Matthias Maennich
2019-09-18 14:39 ` Alan Stern
2019-09-18 17:53 ` [PATCH v2] " Matthias Maennich
2019-09-18 18:39   ` Alan Stern
2019-10-02 11:03 ` [PATCH v3] usb-storage: SCSI glue: use dev_err instead of printk Matthias Maennich
2019-10-04  9:57 ` [PATCH] depmod: create and use System.map.no_namespaces Matthias Maennich
2019-10-04 18:25   ` Lucas De Marchi
2019-10-05  7:53     ` Masahiro Yamada
2019-10-07  6:46       ` Matthias Maennich
2019-10-07 11:25         ` Jessica Yu

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).