[parisc-linux-cvs] [PATCH] Fix zalon support for ncr53c8xx with driverfs

Ryan Bradetich rbradetich@uswest.net
01 Nov 2002 20:57:15 -0700


--=-26L4yOugjlLdMrtvgQzR
Content-Type: text/plain
Content-Transfer-Encoding: 7bit

Log message:
Fix ncr53c8xx with Zalon support.

Explaination:
Zalon on parisc is actually on the GSC/HSC bus, not on the pci
bus.  We assign the ncr53c8xx driver a fake pci device under
ccio to correctly assign the device to the proper IOMMU.
Driverfs is using fields out of the fake pci device which have
not been properly filled out, thus causing a code 26 (NULL ptr
dereference).  This probably broke driverfs, but I am not sure
what it is supposed to look like under driverfs.

Also fixed the Kconfig.... Zalon is not conflicting with the
sym2 driver.  I verified zalon support with both the sym1 and
sym2 driver on the C200.  

- Ryan


--=-26L4yOugjlLdMrtvgQzR
Content-Disposition: attachment; filename=zalon.diff
Content-Transfer-Encoding: quoted-printable
Content-Type: text/x-patch; name=zalon.diff; charset=ISO-8859-1

Index: Makefile
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: /var/cvs/linux-2.5/Makefile,v
retrieving revision 1.23
diff -u -p -r1.23 Makefile
--- Makefile	2 Nov 2002 03:00:28 -0000	1.23
+++ Makefile	2 Nov 2002 03:28:12 -0000
@@ -1,7 +1,7 @@
 VERSION =3D 2
 PATCHLEVEL =3D 5
 SUBLEVEL =3D 45
-EXTRAVERSION =3D -pa4
+EXTRAVERSION =3D -pa5
=20
 # *DOCUMENTATION*
 # To see a list of typical targets execute "make help"
Index: drivers/scsi/Kconfig
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: /var/cvs/linux-2.5/drivers/scsi/Kconfig,v
retrieving revision 1.2
diff -u -p -r1.2 Kconfig
--- drivers/scsi/Kconfig	31 Oct 2002 23:30:09 -0000	1.2
+++ drivers/scsi/Kconfig	2 Nov 2002 03:28:18 -0000
@@ -995,7 +995,7 @@ config SCSI_SYM53C8XX_2
=20
 config SCSI_ZALON
 	tristate "Zalon SCSI support"
-	depends on GSC && SCSI && SCSI_SYM53C8XX_2!=3Dy
+	depends on GSC && SCSI
 	help
 	  The Zalon is a GSC/HSC bus interface chip that sits between the
 	  PA-RISC processor and the NCR 53c720 SCSI controller on C100,
Index: drivers/scsi/ncr53c8xx.c
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: /var/cvs/linux-2.5/drivers/scsi/ncr53c8xx.c,v
retrieving revision 1.5
diff -u -p -r1.5 ncr53c8xx.c
--- drivers/scsi/ncr53c8xx.c	1 Nov 2002 15:28:36 -0000	1.5
+++ drivers/scsi/ncr53c8xx.c	2 Nov 2002 03:28:20 -0000
@@ -3826,7 +3826,9 @@ ncr_attach (Scsi_Host_Template *tpnt, in
 	instance->dma_channel	=3D 0;
 	instance->cmd_per_lun	=3D MAX_TAGS;
 	instance->can_queue	=3D (MAX_START-4);
+#ifndef ENABLE_SCSI_ZALON
 	scsi_set_pci_device(instance, device->pdev);
+#endif
=20
 #ifdef SCSI_NCR_INTEGRITY_CHECKING
 	np->check_integrity	  =3D 0;

--=-26L4yOugjlLdMrtvgQzR--