linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@kernel.org>
To: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: linux-arch@vger.kernel.org,
	Miquel van Smoorenburg <mikevs@xs4all.net>,
	linux-parisc@vger.kernel.org, Arnd Bergmann <arnd@arndb.de>,
	linuxppc-dev@lists.ozlabs.org,
	"Maciej W . Rozycki" <macro@orcam.me.uk>,
	linux-m68k@lists.linux-m68k.org,
	Denis Efremov <efremov@linux.com>,
	Mark Salyzyn <salyzyn@android.com>,
	Christoph Hellwig <hch@infradead.org>,
	iommu@lists.linux-foundation.org, Matt Wang <wwentao@vmware.com>,
	linux-alpha@vger.kernel.org, Jakub Kicinski <kuba@kernel.org>,
	Khalid Aziz <khalid@gonehiking.org>,
	Robin Murphy <robin.murphy@arm.com>,
	Marek Szyprowski <m.szyprowski@samsung.com>
Subject: [PATCH v2 1/3] scsi: dpt_i2o: drop stale VIRT_TO_BUS dependency
Date: Fri, 17 Jun 2022 14:57:48 +0200	[thread overview]
Message-ID: <20220617125750.728590-2-arnd@kernel.org> (raw)
In-Reply-To: <20220617125750.728590-1-arnd@kernel.org>

From: Arnd Bergmann <arnd@arndb.de>

The dpt_i2o driver was fixed to stop using virt_to_bus() in 2008, but
it still has a stale reference in an error handling code path that could
never work.

Fix it up to build without VIRT_TO_BUS and remove the Kconfig dependency.

The alternative to this would be to just remove the driver, as it is
clearly obsolete. The i2o driver layer was removed in 2015 with commit
4a72a7af462d ("staging: remove i2o subsystem"), but the even older
dpt_i2o scsi driver stayed around.

The last non-cleanup patches I could find were from Miquel van Smoorenburg
and Mark Salyzyn back in 2008, they might know if there is any chance
of the hardware still being used anywhere.

Fixes: 67af2b060e02 ("[SCSI] dpt_i2o: move from virt_to_bus/bus_to_virt to dma_alloc_coherent")
Cc: Miquel van Smoorenburg <mikevs@xs4all.net>
Cc: Mark Salyzyn <salyzyn@android.com>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/scsi/Kconfig   | 2 +-
 drivers/scsi/dpt_i2o.c | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/scsi/Kconfig b/drivers/scsi/Kconfig
index a9fe5152addd..cf75588a2587 100644
--- a/drivers/scsi/Kconfig
+++ b/drivers/scsi/Kconfig
@@ -460,7 +460,7 @@ config SCSI_MVUMI
 
 config SCSI_DPT_I2O
 	tristate "Adaptec I2O RAID support "
-	depends on SCSI && PCI && VIRT_TO_BUS
+	depends on SCSI && PCI
 	help
 	  This driver supports all of Adaptec's I2O based RAID controllers as 
 	  well as the DPT SmartRaid V cards.  This is an Adaptec maintained
diff --git a/drivers/scsi/dpt_i2o.c b/drivers/scsi/dpt_i2o.c
index 2e9155ba7408..55dfe7011912 100644
--- a/drivers/scsi/dpt_i2o.c
+++ b/drivers/scsi/dpt_i2o.c
@@ -52,11 +52,11 @@ MODULE_DESCRIPTION("Adaptec I2O RAID Driver");
 
 #include <linux/timer.h>
 #include <linux/string.h>
+#include <linux/io.h>
 #include <linux/ioport.h>
 #include <linux/mutex.h>
 
 #include <asm/processor.h>	/* for boot_cpu_data */
-#include <asm/io.h>		/* for virt_to_bus, etc. */
 
 #include <scsi/scsi.h>
 #include <scsi/scsi_cmnd.h>
@@ -2112,7 +2112,7 @@ static irqreturn_t adpt_isr(int irq, void *dev_id)
 		} else {
 			/* Ick, we should *never* be here */
 			printk(KERN_ERR "dpti: reply frame not from pool\n");
-			reply = (u8 *)bus_to_virt(m);
+			goto out;
 		}
 
 		if (readl(reply) & MSG_FAIL) {
-- 
2.29.2


  reply	other threads:[~2022-06-17 12:59 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-17 12:57 [PATCH v2 0/3] phase out CONFIG_VIRT_TO_BUS Arnd Bergmann
2022-06-17 12:57 ` Arnd Bergmann [this message]
2022-06-21  8:43   ` [PATCH v2 1/3] scsi: dpt_i2o: drop stale VIRT_TO_BUS dependency Hannes Reinecke
2022-06-17 12:57 ` [PATCH v2 2/3] scsi: BusLogic remove bus_to_virt Arnd Bergmann
2022-06-17 14:02   ` Robin Murphy
2022-06-21  8:45   ` Hannes Reinecke
2022-06-21 21:56   ` Khalid Aziz
2022-06-23 14:47     ` Arnd Bergmann
2022-06-24 15:38       ` Khalid Aziz
2022-06-24 15:43         ` Arnd Bergmann
2022-06-17 12:57 ` [PATCH v2 3/3] arch/*/: remove CONFIG_VIRT_TO_BUS Arnd Bergmann
2022-06-18  1:06   ` Michael Schmitz
2022-06-24  9:10     ` Arnd Bergmann
2022-06-26  5:21       ` Michael Schmitz
2022-06-26  8:36         ` Arnd Bergmann
2022-06-27  8:09           ` Michael Schmitz
2022-06-27  8:26     ` Geert Uytterhoeven
2022-06-27 21:12       ` Michael Schmitz
2022-06-28  3:25         ` Michael Schmitz
2022-06-28  7:03           ` Geert Uytterhoeven
2022-06-28 21:03             ` Michael Schmitz
2022-06-28 21:50               ` Arnd Bergmann
2022-06-28 23:09                 ` Michael Schmitz
2022-06-28 23:50                   ` Bart Van Assche
2022-06-29  0:01                     ` Michael Schmitz
2022-06-29  0:14                       ` Michael Schmitz
2022-06-29  6:21                   ` Christoph Hellwig
2022-06-30 19:21                     ` Michael Schmitz
2022-06-30  8:04                   ` David Laight
2022-06-30  9:40                     ` Christophe Leroy
2022-06-30 10:32                       ` David Laight
2022-06-28  7:08           ` Arnd Bergmann
2022-06-28 21:38             ` Michael Schmitz
2022-06-28 21:55               ` Arnd Bergmann
2022-06-28 23:43                 ` Michael Schmitz
2022-06-29  6:25               ` Christoph Hellwig
2022-06-30 19:26                 ` Michael Schmitz

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=20220617125750.728590-2-arnd@kernel.org \
    --to=arnd@kernel.org \
    --cc=arnd@arndb.de \
    --cc=efremov@linux.com \
    --cc=hch@infradead.org \
    --cc=iommu@lists.linux-foundation.org \
    --cc=khalid@gonehiking.org \
    --cc=kuba@kernel.org \
    --cc=linux-alpha@vger.kernel.org \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-m68k@lists.linux-m68k.org \
    --cc=linux-parisc@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=m.szyprowski@samsung.com \
    --cc=macro@orcam.me.uk \
    --cc=mikevs@xs4all.net \
    --cc=robin.murphy@arm.com \
    --cc=salyzyn@android.com \
    --cc=wwentao@vmware.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 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).