From: Hannes Reinecke <hare@suse.de>
To: Alan Stern <stern@rowland.harvard.edu>
Cc: Oliver Neukum <oneukum@suse.de>,
linux-usb@vger.kernel.org, usb-storage@lists.one-eyed-alien.net,
Hannes Reinecke <hare@suse.de>
Subject: [PATCH] sierra-ms: do not call scsi_get_host_dev()
Date: Tue, 5 May 2020 16:30:19 +0200 [thread overview]
Message-ID: <20200505143019.57418-1-hare@suse.de> (raw)
scsi_get_host_dev() will create a virtual device such that either
the target id is ignored from scanning (if 'this_id' is set to
something which can be reached during scanning) or if the driver
needs a scsi device for the HBA to send commands to.
Neither is true for sierra-ms; 'this_id' remains at the default
value '-1' and the created device is never ever used within
the driver.
So kill it.
Signed-off-by: Hannes Reinecke <hare@suse.de>
---
drivers/usb/storage/sierra_ms.c | 4 ----
1 file changed, 4 deletions(-)
diff --git a/drivers/usb/storage/sierra_ms.c b/drivers/usb/storage/sierra_ms.c
index e605cbc3d8bf..b9f78ef3edc3 100644
--- a/drivers/usb/storage/sierra_ms.c
+++ b/drivers/usb/storage/sierra_ms.c
@@ -129,15 +129,11 @@ int sierra_ms_init(struct us_data *us)
int result, retries;
struct swoc_info *swocInfo;
struct usb_device *udev;
- struct Scsi_Host *sh;
retries = 3;
result = 0;
udev = us->pusb_dev;
- sh = us_to_host(us);
- scsi_get_host_dev(sh);
-
/* Force Modem mode */
if (swi_tru_install == TRU_FORCE_MODEM) {
usb_stor_dbg(us, "SWIMS: Forcing Modem Mode\n");
--
2.16.4
next reply other threads:[~2020-05-05 14:30 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-05 14:30 Hannes Reinecke [this message]
2020-05-05 15:46 ` [PATCH] sierra-ms: do not call scsi_get_host_dev() 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=20200505143019.57418-1-hare@suse.de \
--to=hare@suse.de \
--cc=linux-usb@vger.kernel.org \
--cc=oneukum@suse.de \
--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