Skip to contentSkip to conversation

more ncr updates

PATCH In review Christoph Hellwig 2 participants 3 messages Sep 26, 2003 SCSI

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 more ncr updates

- kill pre-2.4 'dma mapping' code
- kill nvram support
- kill pci leftovers

drivers/scsi/Makefile +2 -4
@@ -136,11 +136,9 @@
 ncr53c8xx-flags-$(CONFIG_SCSI_ZALON) \
 		:= -DCONFIG_NCR53C8XX_PREFETCH \
 			-DCONFIG_SCSI_NCR53C8XX_NO_WORD_TRANSFERS \
-			-DCONFIG_SCSI_NCR53C8XX_NO_NVRAM \
 			-DSCSI_NCR_BIG_ENDIAN -DSIMULATED_INTFLY
-ncr53c8xx-flags-$(CONFIG_SCSI_NCR_Q720) \
-		:= -DCONFIG_SCSI_NCR53C8XX_NO_NVRAM \
-			-DSIMULATED_INTFLY
+ncr53c8xx-flags-$(CONFIG_SCSI_NCR_Q720)	\
+		:= -DSIMULATED_INTFLY
 CFLAGS_ncr53c8xx.o	:= $(ncr53c8xx-flags-y) $(ncr53c8xx-flags-m)
 zalon7xx-objs	:= zalon.o ncr53c8xx.o
 NCR_Q720_mod-objs	:= NCR_Q720.o ncr53c8xx.o
drivers/scsi/ncr53c8xx.c +9 -141

215 lines not on this page · raw message

===== drivers/scsi/ncr53c8xx.h 1.14 vs edited =====

drivers/scsi/ncr53c8xx.h +0 -19
@@ -71,24 +71,6 @@
 
 /*==========================================================
 **
-**	Structure used to store the NVRAM content.
-**
-**==========================================================
-*/
-typedef struct {
-	int type;
-#define	SCSI_NCR_SYMBIOS_NVRAM	(1)
-#define	SCSI_NCR_TEKRAM_NVRAM	(2)
-#ifdef	SCSI_NCR_NVRAM_SUPPORT
-	union {
-		Symbios_nvram Symbios;
-		Tekram_nvram Tekram;
-	} data;
-#endif
-} ncr_nvram;
-
-/*==========================================================
-**
 **	Structure used by detection routine to save data on 
 **	each detected board for attach.
 **
@@ -98,7 +80,6 @@
 	struct device  *dev;
 	ncr_slot  slot;
 	ncr_chip  chip;
-	ncr_nvram *nvram;
 	u_char host_id;
 #ifdef	SCSI_NCR_PQS_PDS_SUPPORT
 	u_char pqs_pds;

===== drivers/scsi/sym53c8xx_comm.h 1.14 vs edited =====

drivers/scsi/sym53c8xx_comm.h +0 -698

767 lines not on this page · raw message

===== drivers/scsi/sym53c8xx_defs.h 1.12 vs edited =====

drivers/scsi/sym53c8xx_defs.h +0 -316

346 lines not on this page · raw message

#1 lore raw
Quoted 3 lines · Christoph Hellwig

- kill pre-2.4 'dma mapping' code
- kill nvram support
- kill pci leftovers

I'd already done most of this in the parisc 2.6 tree ...

Quoted 6 lines
drivers/scsi/Makefile +0 -0
@@ -136,11 +136,9 @@
 ncr53c8xx-flags-$(CONFIG_SCSI_ZALON) \
 		:= -DCONFIG_NCR53C8XX_PREFETCH \
 			-DCONFIG_SCSI_NCR53C8XX_NO_WORD_TRANSFERS \

drivers/scsi/Makefile line 144

Quoted 10 lines
drivers/scsi/Makefile +2 -4
-			-DCONFIG_SCSI_NCR53C8XX_NO_NVRAM \
 			-DSCSI_NCR_BIG_ENDIAN -DSIMULATED_INTFLY
-ncr53c8xx-flags-$(CONFIG_SCSI_NCR_Q720) \
-		:= -DCONFIG_SCSI_NCR53C8XX_NO_NVRAM \
-			-DSIMULATED_INTFLY
+ncr53c8xx-flags-$(CONFIG_SCSI_NCR_Q720)	\
+		:= -DSIMULATED_INTFLY
 CFLAGS_ncr53c8xx.o	:= $(ncr53c8xx-flags-y) $(ncr53c8xx-flags-m)
 zalon7xx-objs	:= zalon.o ncr53c8xx.o
 NCR_Q720_mod-objs	:= NCR_Q720.o ncr53c8xx.o

Missed this bit, applied.

drivers/scsi/Makefile line 3404

Quoted 11 lines
drivers/scsi/Makefile +1 -3
@@ -3478,9 +3398,7 @@
 	**	that drive the LED directly.
 	**	Also probe initial setting of GPIO0 as output.
 	*/
-	if ((driver_setup.led_pin ||
-	     (nvram && nvram->type == SCSI_NCR_SYMBIOS_NVRAM)) &&
-	    !(np->features & FE_LEDC) && !(np->sv_gpcntl & 0x01))
+	if (driver_setup.led_pin)
 		np->features |= FE_LED0;
 
 	/*

Are you sure this is right? I have:

        if ((driver_setup.led_pin) &&
            !(np->features & FE_LEDC) && !(np->sv_gpcntl & 0x01))
                np->features |= FE_LED0;

drivers/scsi/Makefile line 3427

Quoted 4 lines
drivers/scsi/Makefile +0 -0
@@ -3507,43 +3425,18 @@
 		tcb_p tp = &np->target[i];
 
 		tp->usrsync = 255;

heh, you made the same mistake I did ;-) this line can also be dropped ...

drivers/scsi/Makefile line 3428

Quoted 2 lines
drivers/scsi/Makefile +1 -1
-		}
+		tp->usrsync = driver_setup.default_sync;

... because this is the next line in the new order. But I didn't notice till I was checking your patch.

drivers/scsi/Makefile line 3513

Quoted 3 lines
drivers/scsi/Makefile +0 -3
-/*
- * DMAable pools.
- */

I thought it was worth leaving this comment in. No big deal either way, I guess.

Quoted 41 lines
drivers/scsi/Makefile +0 -39
-/*==========================================================
-**
-**	SCSI data transfer direction
-**
-**	Until some linux kernel version near 2.3.40, 
-**	low-level scsi drivers were not told about data 
-**	transfer direction. We check the existence of this 
-**	feature that has been expected for a _long_ time by 
-**	all SCSI driver developers by just testing against 
-**	the definition of SCSI_DATA_UNKNOWN. Indeed this is 
-**	a hack, but testing against a kernel version would 
-**	have been a shame. ;-)
-**
-**==========================================================
-*/
-#ifdef	SCSI_DATA_UNKNOWN
-
 #define scsi_data_direction(cmd)	(cmd->sc_data_direction)
 
-#else
-
-#define	SCSI_DATA_UNKNOWN	0
-#define	SCSI_DATA_WRITE		1
-#define	SCSI_DATA_READ		2
-#define	SCSI_DATA_NONE		3
-
-static __inline__ int scsi_data_direction(Scsi_Cmnd *cmd)
-{
-	int direction;
-
-	switch((int) cmd->cmnd[0]) {
-	case 0x08:  /*	READ(6)				08 */
-	case 0x28:  /*	READ(10)			28 */
-	case 0xA8:  /*	READ(12)			A8 */
-		direction = SCSI_DATA_READ;
-		break;
-	case 0x0A:  /*	WRITE(6)			0A */
-	case 0x2A:  /*	WRITE(10)			2A */
-	case 0xAA:  /*	WRITE(12)			AA */
-		direction = SCSI_DATA_WRITE;
-		break;

drivers/scsi/Makefile

Quoted 10 lines
drivers/scsi/Makefile +0 -10
-	default:
-		direction = SCSI_DATA_UNKNOWN;
-		break;
-	}
-
-	return direction;
-}
-
-#endif	/* SCSI_DATA_UNKNOWN */
-

Forgot to take that out. Done.

drivers/scsi/Makefile line 599

Quoted 3 lines
drivers/scsi/Makefile +0 -0
@@ -619,71 +598,6 @@
 #define PSEUDO_720_ID 0x5a00
 #endif

I went further than this and took out PSEUDO_720_ID and all places that filled it in and checked its value. ncr53c8xx is now really ncr53c720.

Signature · 3 lines
"It's not Hollywood.  War is real, war is primarily not about defeat or
victory, it is about death.  I've seen thousands and thousands of dead bodies.
Do you think I want to have an academic debate on this subject?" -- Robert Fisk
#2 lore raw
Quoted 6 lines · Matthew Wilcox
Quoted 6 lines
drivers/scsi/ncr53c8xx.c +1 -3
-	if ((driver_setup.led_pin ||
-	     (nvram && nvram->type == SCSI_NCR_SYMBIOS_NVRAM)) &&
-	    !(np->features & FE_LEDC) && !(np->sv_gpcntl & 0x01))
+	if (driver_setup.led_pin)
 		np->features |= FE_LED0;
Quoted 7 lines
Quoted 1 line

/*

Are you sure this is right? I have:

        if ((driver_setup.led_pin) &&
            !(np->features & FE_LEDC) && !(np->sv_gpcntl & 0x01))
                np->features |= FE_LED0;

Yes, you're right.