linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sven Schnelle <svens@stackframe.org>
To: Alan Stern <stern@rowland.harvard.edu>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-usb@vger.kernel.org, usb-storage@lists.one-eyed-alien.net,
	linux-kernel@vger.kernel.org,
	Sven Schnelle <svens@stackframe.org>
Subject: [PATCH 1/2] usb/storage: add SCSI ID and LUN to debug output
Date: Sun,  2 Feb 2020 10:37:48 +0100	[thread overview]
Message-ID: <20200202093750.4439-2-svens@stackframe.org> (raw)
In-Reply-To: <20200202093750.4439-1-svens@stackframe.org>

Add the LUN and SCSI ID to the debug output so it is a bit easier to
figure out which device is actually adressed.

Signed-off-by: Sven Schnelle <svens@stackframe.org>
---
 drivers/usb/storage/debug.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/usb/storage/debug.c b/drivers/usb/storage/debug.c
index d7f50b7a079e..4787656b4f4f 100644
--- a/drivers/usb/storage/debug.c
+++ b/drivers/usb/storage/debug.c
@@ -136,7 +136,8 @@ void usb_stor_show_command(const struct us_data *us, struct scsi_cmnd *srb)
 	case WRITE_LONG_2: what = "WRITE_LONG_2"; break;
 	default: what = "(unknown command)"; break;
 	}
-	usb_stor_dbg(us, "Command %s (%d bytes)\n", what, srb->cmd_len);
+	usb_stor_dbg(us, "ID %d:%lld Command %s (%d bytes)\n",
+		srb->device->id, srb->device->lun, what, srb->cmd_len);
 	usb_stor_dbg(us, "bytes: %*ph\n", min_t(int, srb->cmd_len, 16),
 		     (const unsigned char *)srb->cmnd);
 }
-- 
2.24.1


  reply	other threads:[~2020-02-02 10:10 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-02  9:37 Add support for Ratoc U2SCX Sven Schnelle
2020-02-02  9:37 ` Sven Schnelle [this message]
2020-02-02  9:37 ` [PATCH 2/2] usb-storage: Add support for Ratoc U2SCX multiple device mode Sven Schnelle
2020-02-02 16:47   ` Alan Stern

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=20200202093750.4439-2-svens@stackframe.org \
    --to=svens@stackframe.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=stern@rowland.harvard.edu \
    --cc=usb-storage@lists.one-eyed-alien.net \
    /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 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).