## Automatically generated incremental diff
## From:   linux-2.0.37-pre6
## To:     linux-2.0.37-pre7
## Robot:  $Id: make-incremental-diff,v 1.11 2002/02/20 02:59:33 hpa Exp $

diff -urN linux-2.0.37-pre6/arch/i386/mm/init.c linux-2.0.37-pre7/arch/i386/mm/init.c
--- linux-2.0.37-pre6/arch/i386/mm/init.c	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/arch/i386/mm/init.c	2003-08-15 15:04:36.000000000 -0700
@@ -139,18 +139,22 @@
 		 *	the error...
 		 */
 		if (!smp_scan_config(639*0x400,0x400))	/* Scan the top 1K of base RAM */
-			smp_scan_config(0xF0000,0x10000);	/* Scan the 64K of bios */
-		/*
-		 * If it is an SMP machine we should know now, unless the
-		 * configuration is in an EISA/MCA bus machine with an
-		 * extended bios data area. 
-		 *
-		 * there is a real-mode segmented pointer pointing to the
-		 * 4K EBDA area at 0x40E, calculate and scan it here:
-		 */
-		address = *(unsigned short *)phys_to_virt(0x40E);
-		address<<=4;
-		smp_scan_config(address, 0x1000);
+		{
+			if(!(smp_scan_config(0xF0000,0x10000)) /* Scan the 64K of bios */
+			{
+				/*
+				 * If it is an SMP machine we should know now, unless the
+				 * configuration is in an EISA/MCA bus machine with an
+				 * extended bios data area. 
+				 *
+				 * there is a real-mode segmented pointer pointing to the
+				 * 4K EBDA area at 0x40E, calculate and scan it here:
+				 */
+				address = *(unsigned short *)phys_to_virt(0x40E);
+				address<<=4;
+				smp_scan_config(address, 0x1000);
+			}
+		}
 	}
 	/*
 	 *	If it is an SMP machine we should know now, unless the configuration
diff -urN linux-2.0.37-pre6/Documentation/Configure.help linux-2.0.37-pre7/Documentation/Configure.help
--- linux-2.0.37-pre6/Documentation/Configure.help	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/Documentation/Configure.help	2003-08-15 15:04:36.000000000 -0700
@@ -1244,6 +1244,65 @@
   IP always defragment.
   If you want this, say Y.
 
+IP: MS PPTP masq support (EXPERIMENTAL)
+CONFIG_IP_MASQUERADE_PPTP
+  Support for masquerading of the GRE data channel portion of the PPTP
+  Virtual Private Network protocol.
+  If you are masquerading a PPTP client or server you need to enable
+  this in addition to regular IP Masquerade.
+  See http://www.wolfenet.com/~jhardin/ip_masq_pptp.html for more details.
+
+IP: MS PPTP Call ID masq support (EXPERIMENTAL)
+CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+  Enabling this adds code to masquerade PPTP Call IDs, which allows
+  more than one masqueraded client to access the same server.
+  This only needs to be enabled if you are masquerading more than one
+  client, and if those clients will try to access the same PPTP server
+  at the same time.
+  You do NOT need to enable this if you are masquerading a PPTP
+  server, regardless of how many clients will be accessing it.
+
+IP: MS PPTP masq debugging
+DEBUG_IP_MASQUERADE_PPTP
+  Enables PPTP Masquerade debugging messages. This should be disabled
+  for normal use once you have PPTP masq working, as it will cause
+  your system logs to quickly grow rather large. Enable verbose
+  debugging for more detailed information.
+
+IP: IPSEC ESP & ISAKMP masq support (EXPERIMENTAL)
+CONFIG_IP_MASQUERADE_IPSEC
+  Support for limited masquerading of the IPSEC ESP network encryption
+  and ISAKMP key-exchange protocols.
+  If you are masquerading an IPSEC client you need to enable this in
+  addition to regular IP Masquerade.
+  Note that this may not successfully masquerade all types of
+  IPSEC-based encryption, as some options in the protocol offer a
+  cryptographic checksum across the IP addresses, which prevents the
+  masqueraded packets from being accepted.
+
+IP: IPSEC masq table lifetime (minutes)
+CONFIG_IP_MASQUERADE_IPSEC_EXPIRE
+  After a period of inactivity IPSEC masq table entries expire and are
+  removed. When this happens inbound traffic can no longer be routed
+  to the masqueraded host until new outbound traffic creates a new
+  masq table entry.
+  For greatest reliability, your IPSEC rekey interval should be less
+  than the table entry lifetime. If your rekey interval is greater
+  than thirty minutes you will improve security by reducing it to
+  thirty minutes. If you don't want to do that, then increase the masq
+  table entry lifetime. Note that doing this will increase the clutter
+  in the IPSEC masq table, as old table entries will persist for this
+  many minutes after a rekey.
+  The minimum lifetime is 15 minutes. Decreasing the lifetime will
+  interfere with sessions that are idle for long periods of time.
+
+IP: IPSEC masq debugging
+DEBUG_IP_MASQUERADE_IPSEC
+  Enables IPSEC Masquerade debugging messages. This should be disabled
+  for normal use once you have IPSEC masq working, as it will cause
+  your system logs to quickly grow rather large. Enable verbose
+  debugging for more detailed information.
+
 IP: ipautofw masquerading (EXPERIMENTAL)
 CONFIG_IP_MASQUERADE_IPAUTOFW
   Richard Lynch's ipautofw allows masquerading to work with protocols
@@ -2187,6 +2246,17 @@
        Winbond xxx837
        National Semiconductor PC87306 (early revisions)
 
+Initio INI-A100U2W SCSI support
+CONFIG_SCSI_INIA100
+  This is support for the Initio INI-A100U2W SCSI host adapter.
+  Please read the SCSI-HOWTO, available via FTP (user anonymous) at
+  ftp://metalab.unc.edu/pub/Linux/docs/HOWTO.
+
+  If you want to compile this as a module ( = code which can be
+  inserted in and removed from the running kernel whenever you want),
+  say M here and read Documenation/modules.txt. The module will be
+  called a100u2w.o
+
 Network device support?
 CONFIG_NETDEVICES
   You can say N here in case you don't intend to connect to any other
diff -urN linux-2.0.37-pre6/drivers/block/floppy.c linux-2.0.37-pre7/drivers/block/floppy.c
--- linux-2.0.37-pre6/drivers/block/floppy.c	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/drivers/block/floppy.c	2003-08-15 15:04:36.000000000 -0700
@@ -96,6 +96,11 @@
  * features to asm/floppy.h.
  */
 
+/*
+ * 1999/02/23 -- Paul Slootman -- floppy stopped working on Alpha after 24
+ * days, 6 hours, 32 minutes and 32 seconds (i.e. MAXINT jiffies; ints were
+ * being used to store jiffies, which are unsigned longs).
+ */
 
 #define FLOPPY_SANITY_CHECK
 #undef  FLOPPY_SILENT_DCL_CLEAR
@@ -573,10 +578,10 @@
 #define OLOGSIZE 20
 
 static void (*lasthandler)(void) = NULL;
-static int interruptjiffies=0;
-static int resultjiffies=0;
+static unsigned long interruptjiffies=0;
+static unsigned long resultjiffies=0;
 static int resultsize=0;
-static int lastredo=0;
+static unsigned long lastredo=0;
 
 static struct output_log {
 	unsigned char data;
@@ -679,7 +684,7 @@
 #ifdef DCL_DEBUG
 	if (UDP->flags & FD_DEBUG){
 		DPRINT("checking disk change line for drive %d\n",drive);
-		DPRINT("jiffies=%ld\n", jiffies);
+		DPRINT("jiffies=%lu\n", jiffies);
 		DPRINT("disk change line=%x\n",fd_inb(FD_DIR)&0x80);
 		DPRINT("flags=%x\n",UDRS->flags);
 	}
@@ -1226,7 +1231,7 @@
 static void fdc_specify(void)
 {
 	unsigned char spec1, spec2;
-	int srt, hlt, hut;
+	unsigned long srt, hlt, hut;
 	unsigned long dtr = NOMINAL_DTR;
 	unsigned long scale_dtr = NOMINAL_DTR;
 	int hlt_max_code = 0x7f;
@@ -1409,7 +1414,8 @@
  */
 static void setup_rw_floppy(void)
 {
-	int i,ready_date,r, flags,dflags;
+	int i,r, flags,dflags;
+	unsigned long ready_date;
 	timeout_fn function;
 
 	flags = raw_cmd->flags;
@@ -1482,7 +1488,7 @@
 #ifdef DCL_DEBUG
 		if (DP->flags & FD_DEBUG){
 			DPRINT("clearing NEWCHANGE flag because of effective seek\n");
-			DPRINT("jiffies=%ld\n", jiffies);
+			DPRINT("jiffies=%lu\n", jiffies);
 		}
 #endif
 		CLEARF(FD_DISK_NEWCHANGE); /* effective seek */
@@ -1762,20 +1768,20 @@
 	printk("\n");
 	printk("floppy driver state\n");
 	printk("-------------------\n");
-	printk("now=%ld last interrupt=%d last called handler=%p\n",
-	       jiffies, interruptjiffies, lasthandler);
+	printk("now=%lu last interrupt=%lu diff=%lu last called handler=%p\n",
+	       jiffies, interruptjiffies, jiffies-interruptjiffies, lasthandler);
 
 
 #ifdef FLOPPY_SANITY_CHECK
 	printk("timeout_message=%s\n", timeout_message);
 	printk("last output bytes:\n");
 	for (i=0; i < OLOGSIZE; i++)
-		printk("%2x %2x %ld\n",
+		printk("%2x %2x %lu\n",
 		       output_log[(i+output_log_pos) % OLOGSIZE].data,
 		       output_log[(i+output_log_pos) % OLOGSIZE].status,
 		       output_log[(i+output_log_pos) % OLOGSIZE].jiffies);
-	printk("last result at %d\n", resultjiffies);
-	printk("last redo_fd_request at %d\n", lastredo);
+	printk("last result at %lu\n", resultjiffies);
+	printk("last redo_fd_request at %lu\n", lastredo);
 	for (i=0; i<resultsize; i++){
 		printk("%2x ", reply_buffer[i]);
 	}
@@ -1792,8 +1798,8 @@
 		printk("fd_timer.function=%p\n", fd_timer.function);
 	if (fd_timeout.prev){
 		printk("timer_table=%p\n",fd_timeout.function);
-		printk("expires=%ld\n",fd_timeout.expires-jiffies);
-		printk("now=%ld\n",jiffies);
+		printk("expires=%lu\n",fd_timeout.expires-jiffies);
+		printk("now=%lu\n",jiffies);
 	}
 	printk("cont=%p\n", cont);
 	printk("CURRENT=%p\n", CURRENT);
@@ -3714,7 +3720,7 @@
 	if (UTESTF(FD_DISK_CHANGED) || UTESTF(FD_VERIFY))
 		return 1;
 
-	if (UDP->checkfreq < jiffies - UDRS->last_checked){
+	if (UDP->checkfreq < (int)(jiffies - UDRS->last_checked)) {
 		lock_fdc(drive,0);
 		poll_drive(0,0);
 		process_fd_request();
diff -urN linux-2.0.37-pre6/drivers/block/ll_rw_blk.c linux-2.0.37-pre7/drivers/block/ll_rw_blk.c
--- linux-2.0.37-pre6/drivers/block/ll_rw_blk.c	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/drivers/block/ll_rw_blk.c	2003-08-15 15:04:36.000000000 -0700
@@ -359,7 +359,7 @@
 	lock_buffer(bh);
 
 	if (blk_size[major])
-		if (blk_size[major][MINOR(bh->b_rdev)] < (sector + count)>>1) {
+		if (((blk_size[major][MINOR(bh->b_rdev)]<<1)+count) < sector) {
 			bh->b_state &= (1 << BH_Lock) | (1 << BH_FreeOnIO);
                         /* This may well happen - the kernel calls bread()
                            without checking the size of the device, e.g.,
diff -urN linux-2.0.37-pre6/drivers/net/ne.c linux-2.0.37-pre7/drivers/net/ne.c
--- linux-2.0.37-pre6/drivers/net/ne.c	1998-06-03 15:17:47.000000000 -0700
+++ linux-2.0.37-pre7/drivers/net/ne.c	2003-08-15 15:04:36.000000000 -0700
@@ -97,6 +97,7 @@
     {"ET-100","ET-200", {0x00, 0x45, 0x54}}, /* YANG and YA clone */
     {"COMPEX","COMPEX16",{0x00,0x80,0x48}}, /* Broken ISA Compex cards */
     {"E-LAN100", "E-LAN200", {0x00, 0x00, 0x5d}}, /* Broken ne1000 clones */
+    {"PCM-4823", "PCM-4823", {0x00, 0xc0, 0x6c}}, /* Broken Advantech MoBo */
     {0,}
 };
 #endif
diff -urN linux-2.0.37-pre6/drivers/net/wavelan.c linux-2.0.37-pre7/drivers/net/wavelan.c
--- linux-2.0.37-pre6/drivers/net/wavelan.c	1998-11-15 10:33:04.000000000 -0800
+++ linux-2.0.37-pre7/drivers/net/wavelan.c	2003-08-15 15:04:36.000000000 -0700
@@ -290,24 +290,26 @@
   wv_16_on(ioaddr, hacr);
 } /* psa_write */
 
-#ifdef PSA_CRC
+#ifdef SET_PSA_CRC
 /*------------------------------------------------------------------*/
 /*
- * Calculate the PSA CRC (not tested yet)
- * As the WaveLAN drivers don't use the CRC, I won't use it either.
+ * Calculate the PSA CRC
  * Thanks to Valster, Nico <NVALSTER@wcnd.nl.lucent.com> for the code
  * NOTE: By specifying a length including the CRC position the
  * returned value should be zero. (i.e. a correct checksum in the PSA)
+ *
+ * The Windows drivers don't use the CRC, but the AP and the PtP tool
+ * depend on it.
  */
-static u_short
-psa_crc(u_short *	psa,	/* The PSA */
+static inline u_short
+psa_crc(u_char *	psa,	/* The PSA */
 	int		size)	/* Number of short for CRC */
 {
   int		byte_cnt;	/* Loop on the PSA */
   u_short	crc_bytes = 0;	/* Data in the PSA */
   int		bit_cnt;	/* Loop on the bits of the short */
 
-  for(byte_cnt = 0; byte_cnt <= size; byte_cnt++ )
+  for(byte_cnt = 0; byte_cnt < size; byte_cnt++ )
     {
       crc_bytes ^= psa[byte_cnt];	/* Its an xor */
 
@@ -322,7 +324,47 @@
 
   return crc_bytes;
 } /* psa_crc */
-#endif	/* PSA_CRC */
+
+/*------------------------------------------------------------------*/
+/*
+ * update the checksum field in the Wavelan's PSA
+ */
+static void
+update_psa_checksum(device *	dev,
+		    u_long	ioaddr,
+		    u_short	hacr)
+{
+  psa_t		psa;
+  u_short	crc;
+
+  /* read the parameter storage area */
+  psa_read(ioaddr, hacr, 0, (unsigned char *) &psa, sizeof(psa));
+
+  /* update the checksum */
+  crc = psa_crc((unsigned char *) &psa,
+		sizeof(psa) - sizeof(psa.psa_crc[0]) - sizeof(psa.psa_crc[1])
+		- sizeof(psa.psa_crc_status));
+
+  psa.psa_crc[0] = crc & 0xFF;
+  psa.psa_crc[1] = (crc & 0xFF00) >> 8;
+
+  /* Write it ! */
+  psa_write(ioaddr, hacr, (char *)&psa.psa_crc - (char *)&psa,
+	    (unsigned char *)&psa.psa_crc, 2);
+
+#ifdef DEBUG_IOCTL_INFO
+  printk (KERN_DEBUG "%s: update_psa_checksum(): crc = 0x%02x%02x\n",
+          dev->name, psa.psa_crc[0], psa.psa_crc[1]);
+
+  /* Check again (luxury !) */
+  crc = psa_crc ((unsigned char *) &psa,
+		 sizeof(psa) - sizeof(psa.psa_crc_status));
+
+  if(crc != 0)
+    printk(KERN_WARNING "%s: update_psa_checksum(): CRC does not agree with PSA data (even after recalculating)\n", dev->name);
+#endif /* DEBUG_IOCTL_INFO */
+} /* update_psa_checksum */
+#endif	/* SET_PSA_CRC */
 
 /*------------------------------------------------------------------*/
 /*
@@ -706,21 +748,21 @@
       unsigned short	ias_addr;
 
       /* Check mc_config command */
-      if(status & AC_SFLD_OK != 0)
+      if((status & AC_SFLD_OK) != 0)
 	printk(KERN_INFO "wv_config_complete(): set_multicast_address failed; status = 0x%x\n",
 	       dev->name, str, status);
 
       /* check ia-config command */
       ias_addr = mcs_addr - sizeof(ac_ias_t);
       obram_read(ioaddr, acoff(ias_addr, ac_status), (unsigned char *)&status, sizeof(status));
-      if(status & AC_SFLD_OK != 0)
+      if((status & AC_SFLD_OK) != 0)
 	printk(KERN_INFO "wv_config_complete(): set_MAC_address; status = 0x%x\n",
 	       dev->name, str, status);
 
       /* Check config command */
       cfg_addr = ias_addr - sizeof(ac_cfg_t);
       obram_read(ioaddr, acoff(cfg_addr, ac_status), (unsigned char *)&status, sizeof(status));
-      if(status & AC_SFLD_OK != 0)
+      if((status & AC_SFLD_OK) != 0)
 	printk(KERN_INFO "wv_config_complete(): configure; status = 0x%x\n",
 	       dev->name, str, status);
 #endif	/* DEBUG_CONFIG_ERROR */
@@ -1898,6 +1940,10 @@
 	  /* Disable nwid in the mmc (no filtering) */
 	  mmc_out(ioaddr, mmwoff(0, mmw_loopt_sel), MMW_LOOPT_SEL_DIS_NWID);
 	}
+#ifdef SET_PSA_CRC
+      /* update the Wavelan checksum */
+      update_psa_checksum(dev, ioaddr, lp->hacr);
+#endif
       break;
 
     case SIOCGIWNWID:
@@ -1955,6 +2001,10 @@
       psa.psa_thr_pre_set = wrq->u.sensitivity & 0x3F;
       psa_write(ioaddr, lp->hacr, (char *)&psa.psa_thr_pre_set - (char *)&psa,
 	       (unsigned char *) &psa.psa_thr_pre_set, 1);
+#ifdef SET_PSA_CRC
+      /* update the Wavelan checksum */
+      update_psa_checksum(dev, ioaddr, lp->hacr);
+#endif
       mmc_out(ioaddr, mmwoff(0, mmw_thr_pre_set), psa.psa_thr_pre_set);
       break;
 
@@ -2002,6 +2052,10 @@
 
 	   mmc_out(ioaddr, mmwoff(0, mmw_encr_enable), 0);
 	 }
+#ifdef SET_PSA_CRC
+       /* update the Wavelan checksum */
+       update_psa_checksum(dev, ioaddr, lp->hacr);
+#endif
        break;
 
      case SIOCGIWENCODE:
@@ -2215,6 +2269,10 @@
       psa.psa_quality_thr = *(wrq->u.name) & 0x0F;
       psa_write(ioaddr, lp->hacr, (char *)&psa.psa_quality_thr - (char *)&psa,
 	       (unsigned char *)&psa.psa_quality_thr, 1);
+#ifdef SET_PSA_CRC
+      /* update the Wavelan checksum */
+      update_psa_checksum(dev, ioaddr, lp->hacr);
+#endif
       mmc_out(ioaddr, mmwoff(0, mmw_quality_thr), psa.psa_quality_thr);
       break;
 
@@ -2325,7 +2383,7 @@
   mmc_out(ioaddr, mmwoff(0, mmw_freeze), 0);
 
   /* Copy data to wireless stuff */
-  wstats->status = m.mmr_dce_status;
+  wstats->status = m.mmr_dce_status & MMR_DCE_STATUS;
   wstats->qual.qual = m.mmr_sgnl_qual & MMR_SGNL_QUAL;
   wstats->qual.level = m.mmr_signal_lvl & MMR_SIGNAL_LVL;
   wstats->qual.noise = m.mmr_silence_lvl & MMR_SILENCE_LVL;
@@ -2909,6 +2967,10 @@
 		(unsigned char *)&psa.psa_quality_thr, 1);
       psa_write(ioaddr, lp->hacr, (char *)&psa.psa_conf_status - (char *)&psa,
 		(unsigned char *)&psa.psa_conf_status, 1);
+#ifdef SET_PSA_CRC
+      /* update the Wavelan checksum */
+      update_psa_checksum(dev, ioaddr, lp->hacr);
+#endif
 #endif
     }
 
@@ -2935,21 +2997,18 @@
   m.mmw_thr_pre_set = psa.psa_thr_pre_set & 0x3F;
   m.mmw_quality_thr = psa.psa_quality_thr & 0x0F;
 
-  /* Missing: encryption stuff... */
-
   /*
    * Set default modem control parameters.
    * See NCR document 407-0024326 Rev. A.
    */
   m.mmw_jabber_enable = 0x01;
+  m.mmw_freeze = 0;
   m.mmw_anten_sel = MMW_ANTEN_SEL_ALG_EN;
   m.mmw_ifs = 0x20;
   m.mmw_mod_delay = 0x04;
   m.mmw_jam_time = 0x38;
 
-  m.mmw_encr_enable = 0;
   m.mmw_des_io_invert = 0;
-  m.mmw_freeze = 0;
   m.mmw_decay_prm = 0;
   m.mmw_decay_updat_prm = 0;
 
@@ -3414,39 +3473,29 @@
   /* Create a configure action */
   memset(&cfg, 0x00, sizeof(cfg));
 
-#if	0
-  /*
-   * The default board configuration
-   */
-  cfg.fifolim_bytecnt 	= 0x080c;
-  cfg.addrlen_mode  	= 0x2600;
-  cfg.linprio_interframe	= 0x7820;	/* IFS=120, ACS=2 */
-  cfg.slot_time      	= 0xf00c;	/* slottime=12    */
-  cfg.hardware	     	= 0x0008;	/* tx even without CD */
-  cfg.min_frame_len   	= 0x0040;
-#endif	/* 0 */
-
   /*
    * For Linux we invert AC_CFG_ALOC(..) so as to conform
    * to the way that net packets reach us from above.
    * (See also ac_tx_t.)
+   *
+   * Updated from Wavelan Manual WCIN085B
    */
   cfg.cfg_byte_cnt = AC_CFG_BYTE_CNT(sizeof(ac_cfg_t) - sizeof(ach_t));
-  cfg.cfg_fifolim = AC_CFG_FIFOLIM(8);
-  cfg.cfg_byte8 = AC_CFG_SAV_BF(0) |
+  cfg.cfg_fifolim = AC_CFG_FIFOLIM(4);
+  cfg.cfg_byte8 = AC_CFG_SAV_BF(1) |
 		  AC_CFG_SRDY(0);
   cfg.cfg_byte9 = AC_CFG_ELPBCK(0) |
 		  AC_CFG_ILPBCK(0) |
 		  AC_CFG_PRELEN(AC_CFG_PLEN_2) |
 		  AC_CFG_ALOC(1) |
 		  AC_CFG_ADDRLEN(WAVELAN_ADDR_SIZE);
-  cfg.cfg_byte10 = AC_CFG_BOFMET(0) |
-		   AC_CFG_ACR(0) |
+  cfg.cfg_byte10 = AC_CFG_BOFMET(1) |
+		   AC_CFG_ACR(6) |
 		   AC_CFG_LINPRIO(0);
-  cfg.cfg_ifs = 32;
-  cfg.cfg_slotl = 0;
+  cfg.cfg_ifs = 0x20;
+  cfg.cfg_slotl = 0x0C;
   cfg.cfg_byte13 = AC_CFG_RETRYNUM(15) |
-		   AC_CFG_SLTTMHI(2);
+		   AC_CFG_SLTTMHI(0);
   cfg.cfg_byte14 = AC_CFG_FLGPAD(0) |
 		   AC_CFG_BTSTF(0) |
 		   AC_CFG_CRC16(0) |
@@ -4045,6 +4094,10 @@
 #endif
 	  psa_write(ioaddr, HACR_DEFAULT,
 		    psaoff(0, psa_int_req_no), &irq_mask, 1);
+#ifdef SET_PSA_CRC
+	  /* update the Wavelan checksum */
+	  update_psa_checksum(dev, ioaddr, HACR_DEFAULT);
+#endif
 	  wv_hacr_reset(ioaddr);
 	}
     }
@@ -4227,7 +4280,7 @@
 init_module(void)
 {
   mac_addr	mac;		/* MAC address (check WaveLAN existence) */
-  int		ret = 0;
+  int		ret = -EIO;	/* Return error if no cards found */
   int		i;
 
 #ifdef DEBUG_MODULE_TRACE
@@ -4272,7 +4325,11 @@
 	      /* DeAllocate everything */
 	      /* Note : if dev->priv is mallocated, there is no way to fail */
 	      kfree_s(dev, sizeof(struct device));
-	      ret = -EIO;
+	    }
+	  else
+	    {
+              /* If at least one device OK, we do not fail */
+              ret = 0;
 	    }
 	}	/* if there is something at the address */
     }		/* Loop on all addresses. */
diff -urN linux-2.0.37-pre6/drivers/net/wavelan.h linux-2.0.37-pre7/drivers/net/wavelan.h
--- linux-2.0.37-pre6/drivers/net/wavelan.h	1997-03-06 10:03:51.000000000 -0800
+++ linux-2.0.37-pre7/drivers/net/wavelan.h	2003-08-15 15:04:36.000000000 -0700
@@ -28,6 +28,8 @@
 {
   { 0x08, 0x00, 0x0E },		/* AT&T Wavelan (standard) & DEC RoamAbout */
   { 0x08, 0x00, 0x6A },		/* AT&T Wavelan (alternate) */
+  { 0x00, 0x00, 0xE1 },		/* Hitachi Wavelan */
+  { 0x00, 0x60, 0x1D }		/* Lucent Wavelan (another one) */
   /* Add your card here and send me the patch ! */
 };
 
@@ -293,6 +295,7 @@
 #define	MMR_DCE_STATUS_LOOPT_IND	0x02	/* loop test indicated */
 #define	MMR_DCE_STATUS_TX_BUSY		0x04	/* transmitter on */
 #define	MMR_DCE_STATUS_JBR_EXPIRED	0x08	/* jabber timer expired */
+#define MMR_DCE_STATUS			0x0F	/* mask to get the bits */
   unsigned char	mmr_dsp_id;		/* DSP id (AA = Daedalus rev A) */
   unsigned char	mmr_unused2[2];		/* unused */
   unsigned char	mmr_correct_nwid_l;	/* # of correct NWID's rxd (low) */
diff -urN linux-2.0.37-pre6/drivers/net/wavelan.p.h linux-2.0.37-pre7/drivers/net/wavelan.p.h
--- linux-2.0.37-pre6/drivers/net/wavelan.p.h	1997-10-15 15:23:20.000000000 -0700
+++ linux-2.0.37-pre7/drivers/net/wavelan.p.h	2003-08-15 15:04:36.000000000 -0700
@@ -16,15 +16,9 @@
 /************************** DOCUMENTATION **************************/
 /*
  * This driver provide a Linux interface to the Wavelan ISA hardware
- * The Wavelan is a product of Lucent ("http://wavelan.netland.nl/").
+ * The Wavelan is a product of Lucent ("http://www.wavelan.com/").
  * This division was formerly part of NCR and then AT&T.
- * Wavelan are also distributed by DEC (RoamAbout), Digital Ocean and
- * Aironet (Arlan). If you have one of those product, you will need to
- * make some changes below...
- *
- * This driver is still a beta software. A lot of bugs have been corrected,
- * a lot of functionalities are implemented, the whole appear pretty stable,
- * but there is still some area of improvement (encryption, performance...).
+ * Wavelan are also distributed by DEC (RoamAbout DS) and Digital Ocean.
  *
  * To know how to use this driver, read the NET3 HOWTO.
  * If you want to exploit the many other fonctionalities, look comments
@@ -35,12 +29,22 @@
 
 /* ------------------------ SPECIFIC NOTES ------------------------ */
 /*
+ * Web page
+ * --------
+ *	I try to maintain a web page with the Wireless LAN Howto at :
+ *		http://www-uk.hpl.hp.com/people/jt/Linux/Wavelan.html
+ *
  * wavelan.o is darn too big
  * -------------------------
  *	That's true ! There is a very simple way to reduce the driver
  *	object by 33% (yes !). Comment out the following line :
  *		#include <linux/wireless.h>
  *
+ * Debugging and options
+ * ---------------------
+ *	You will find below a set of '#define" allowing a very fine control
+ *	on the driver behaviour and the debug messages printed.
+ *
  * MAC address and hardware detection :
  * ----------------------------------
  *	The detection code of the wavelan chech that the first 3
@@ -60,23 +64,6 @@
  *	3) Compile & verify
  *	4) Send me the MAC code - I will include it in the next version...
  *
- * "CU Inactive" message at boot up :
- * -----------------------------------
- *	It seem that there is some weird timings problems with the
- *	Intel microcontroler. In fact, this message is triggered by a
- *	bad reading of the on board ram the first time we read the
- *	control block. If you ignore this message, all is ok (but in
- *	fact, currently, it reset the wavelan hardware).
- *
- *	To get rid of that problem, there is two solution. The first
- *	is to add a dummy read of the scb at the end of
- *	wv_82586_config. The second is to add the timers
- *	wv_synchronous_cmd and wv_ack (the udelay just after the
- *	waiting loops - seem that the controler is not totally ready
- *	when it say it is !).
- *
- *	In the current code, I use the second solution (to be
- *	consistent with the original solution of Bruce Janson).
  */
 
 /* --------------------- WIRELESS EXTENSIONS --------------------- */
@@ -271,6 +258,22 @@
  *	- Encryption setting from Brent Elphick (thanks a lot !)
  *	- 'ioaddr' to 'u_long' for the Alpha (thanks to Stanislav Sinyagin)
  *
+ * Other changes (not by me) :
+ * -------------------------
+ *	- Spelling and gramar "rectification".
+ *
+ * Changes made for release in 2.0.37 & 2.2.2 :
+ * ------------------------------------------
+ *	- Correct status in /proc/net/wireless
+ *	- Set PSA CRC to make PtP diagnostic tool happy (Bob Gray)
+ *	- Module init code don't fail if we found at least one card in
+ *	  the address list (Karlis Peisenieks)
+ *	- Missing parenthesis (Christopher Peterson)
+ *	- Correct i82586 configuration parameters
+ *	- Encryption initialisation bug (Robert McCormack)
+ *	- New mac addresses detected in the probe
+ *	- Increase watchdog for busy envirnoments
+ *
  * Wishes & dreams :
  * ---------------
  *	- Roaming
@@ -338,9 +341,9 @@
 
 /* Options : */
 #define USE_PSA_CONFIG		/* Use info from the PSA */
+#define SET_PSA_CRC		/* Calculate and set the CRC on PSA */
 #define IGNORE_NORMAL_XMIT_ERRS	/* Don't bother with normal conditions */
 #undef STRUCT_CHECK		/* Verify padding of structures */
-#undef PSA_CRC			/* Check CRC in PSA */
 #undef OLDIES			/* Old code (to redo) */
 #undef RECORD_SNR		/* To redo */
 #undef EEPROM_IS_PROTECTED	/* Doesn't seem to be necessary */
@@ -355,11 +358,11 @@
 /************************ CONSTANTS & MACROS ************************/
 
 #ifdef DEBUG_VERSION_SHOW
-static const char	*version	= "wavelan.c : v16 (wireless extensions) 17/4/97\n";
+static const char	*version	= "wavelan.c : v18 (wireless extensions) 18/2/99\n";
 #endif
 
 /* Watchdog temporisation */
-#define	WATCHDOG_JIFFIES	32	/* TODO: express in HZ. */
+#define	WATCHDOG_JIFFIES	256	/* TODO: express in HZ. */
 
 /* Macro to get the number of elements in an array */
 #define	NELS(a)				(sizeof(a) / sizeof(a[0]))
diff -urN linux-2.0.37-pre6/drivers/scsi/Config.in linux-2.0.37-pre7/drivers/scsi/Config.in
--- linux-2.0.37-pre6/drivers/scsi/Config.in	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/drivers/scsi/Config.in	2003-08-15 15:04:36.000000000 -0700
@@ -54,6 +54,7 @@
 		Memory CONFIG_SCSI_G_NCR5380_MEM" Port
 fi
 dep_tristate 'Initio 91XX support' CONFIG_SCSI_INITIO $CONFIG_SCSI
+dep_tristate 'Initio INI-A100U2W support' CONFIG_SCSI_INIA100 $CONFIG_SCSI
 dep_tristate 'NCR53c406a SCSI support' CONFIG_SCSI_NCR53C406A $CONFIG_SCSI
 dep_tristate 'symbios 53c416 SCSI support' CONFIG_SCSI_SYM53C416 $CONFIG_SCSI
 if [ "$CONFIG_PCI" = "y" ]; then
@@ -97,6 +98,7 @@
   fi
 fi
 dep_tristate 'Trantor T128/T128F/T228 SCSI support' CONFIG_SCSI_T128 $CONFIG_SCSI
+dep_tristate 'Tripace TC-2550x SCSI support' CONFIG_SCSI_TC2550 $CONFIG_SCSI
 dep_tristate 'UltraStor 14F/34F support' CONFIG_SCSI_U14_34F $CONFIG_SCSI
   if [ "$CONFIG_SCSI_U14_34F" != "n" ]; then
     bool '  enable elevator sorting' CONFIG_SCSI_U14_34F_LINKED_COMMANDS
diff -urN linux-2.0.37-pre6/drivers/scsi/hosts.c linux-2.0.37-pre7/drivers/scsi/hosts.c
--- linux-2.0.37-pre6/drivers/scsi/hosts.c	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/drivers/scsi/hosts.c	2003-08-15 15:04:36.000000000 -0700
@@ -193,6 +193,14 @@
 #include "ini9100u.h"
 #endif
 
+#ifdef CONFIG_SCSI_TC2550
+#include "tripace.h"
+#endif
+
+#ifdef CONFIG_SCSI_INIA100
+#include "inia100.h"
+#endif
+
 #ifdef CONFIG_SCSI_DEBUG
 #include "scsi_debug.h"
 #endif
@@ -334,6 +342,9 @@
 #ifdef CONFIG_SCSI_MEGARAID
     MEGARAID,
 #endif
+#ifdef CONFIG_SCSI_INIA100
+    INIA100,
+#endif
 #ifdef CONFIG_SCSI_PPA
     PPA,
 #endif
diff -urN linux-2.0.37-pre6/drivers/scsi/i60uscsi.c linux-2.0.37-pre7/drivers/scsi/i60uscsi.c
--- linux-2.0.37-pre6/drivers/scsi/i60uscsi.c	1969-12-31 16:00:00.000000000 -0800
+++ linux-2.0.37-pre7/drivers/scsi/i60uscsi.c	2003-08-15 15:04:36.000000000 -0700
@@ -0,0 +1,956 @@
+/**************************************************************************
+ * Initio A100 device driver for Linux.
+ *
+ * Copyright (c) 1994-1998 Initio Corporation
+ * All rights reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2, or (at your option)
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; see the file COPYING.  If not, write to
+ * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+ *
+ * --------------------------------------------------------------------------
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions, and the following disclaimer,
+ *    without modification, immediately at the beginning of the file.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ * 3. The name of the author may not be used to endorse or promote products
+ *    derived from this software without specific prior written permission.
+ *
+ * Where this Software is combined with software released under the terms of 
+ * the GNU Public License ("GPL") and the terms of the GPL would require the 
+ * combined work to also be released under the terms of the GPL, the terms
+ * and conditions of this License will apply in addition to those of the
+ * GPL with the exception of any terms or conditions of this License that
+ * conflict with, or are expressly prohibited by, the GPL.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR
+ * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ *************************************************************************
+ *
+ * module: i60uscsi.c 
+ * DESCRIPTION:
+ * 	This is the Linux low-level SCSI driver for Initio INIA100 SCSI host
+ * adapters
+ *
+ * 07/02/98 hl	- v.91n Initial drivers.
+ * 09/14/98 hl - v1.01 Support new Kernel.
+ * 09/22/98 hl - v1.01a Support reset.
+ * 09/24/98 hl - v1.01b Fixed reset.
+ * 10/05/98 hl - v1.02 split the source code and release.
+ * 12/19/98 bv - v1.02a Use spinlocks for 2.1.95 and up
+ **************************************************************************/
+
+#ifndef CVT_LINUX_VERSION
+#define CVT_LINUX_VERSION(V,P,S)        (V * 65536 + P * 256 + S)
+#endif
+
+#include <linux/sched.h>
+#include <asm/io.h>
+#include "i60uscsi.h"
+
+
+/* ---- INTERNAL FUNCTIONS ---- */
+static UCHAR waitChipReady(ORC_HCS * hcsp);
+static UCHAR waitFWReady(ORC_HCS * hcsp);
+static UCHAR waitFWReady(ORC_HCS * hcsp);
+static UCHAR waitSCSIRSTdone(ORC_HCS * hcsp);
+static UCHAR waitHDOoff(ORC_HCS * hcsp);
+static UCHAR waitHDIset(ORC_HCS * hcsp, UCHAR * pData);
+static unsigned short get_FW_version(ORC_HCS * hcsp);
+static UCHAR set_NVRAM(ORC_HCS * hcsp, unsigned char address, unsigned char value);
+static UCHAR get_NVRAM(ORC_HCS * hcsp, unsigned char address, unsigned char *pDataIn);
+static int se2_rd_all(ORC_HCS * hcsp);
+static void se2_update_all(ORC_HCS * hcsp);	/* setup default pattern        */
+static void read_eeprom(ORC_HCS * hcsp);
+static UCHAR load_FW(ORC_HCS * hcsp);
+static void setup_SCBs(ORC_HCS * hcsp);
+static void initAFlag(ORC_HCS * hcsp);
+ORC_SCB *orc_alloc_scb(ORC_HCS * hcsp);
+
+/* ---- EXTERNAL FUNCTIONS ---- */
+extern void inia100SCBPost(BYTE * pHcb, BYTE * pScb);
+
+/* ---- INTERNAL VARIABLES ---- */
+ORC_HCS orc_hcs[MAX_SUPPORTED_ADAPTERS];
+static INIA100_ADPT_STRUCT inia100_adpt[MAX_SUPPORTED_ADAPTERS];
+/* set by inia100_setup according to the command line */
+int orc_num_scb;
+
+NVRAM nvram, *nvramp = &nvram;
+static UCHAR dftNvRam[64] =
+{
+/*----------header -------------*/
+	0x01,			/* 0x00: Sub System Vendor ID 0 */
+	0x11,			/* 0x01: Sub System Vendor ID 1 */
+	0x60,			/* 0x02: Sub System ID 0        */
+	0x10,			/* 0x03: Sub System ID 1        */
+	0x00,			/* 0x04: SubClass               */
+	0x01,			/* 0x05: Vendor ID 0            */
+	0x11,			/* 0x06: Vendor ID 1            */
+	0x60,			/* 0x07: Device ID 0            */
+	0x10,			/* 0x08: Device ID 1            */
+	0x00,			/* 0x09: Reserved               */
+	0x00,			/* 0x0A: Reserved               */
+	0x01,			/* 0x0B: Revision of Data Structure     */
+				/* -- Host Adapter Structure --- */
+	0x01,			/* 0x0C: Number Of SCSI Channel */
+	0x01,			/* 0x0D: BIOS Configuration 1   */
+	0x00,			/* 0x0E: BIOS Configuration 2   */
+	0x00,			/* 0x0F: BIOS Configuration 3   */
+				/* --- SCSI Channel 0 Configuration --- */
+	0x07,			/* 0x10: H/A ID                 */
+	0x83,			/* 0x11: Channel Configuration  */
+	0x20,			/* 0x12: MAX TAG per target     */
+	0x0A,			/* 0x13: SCSI Reset Recovering time     */
+	0x00,			/* 0x14: Channel Configuration4 */
+	0x00,			/* 0x15: Channel Configuration5 */
+				/* SCSI Channel 0 Target Configuration  */
+				/* 0x16-0x25                    */
+	0xC8, 0xC8, 0xC8, 0xC8, 0xC8, 0xC8, 0xC8, 0xC8,
+	0xC8, 0xC8, 0xC8, 0xC8, 0xC8, 0xC8, 0xC8, 0xC8,
+				/* --- SCSI Channel 1 Configuration --- */
+	0x07,			/* 0x26: H/A ID                 */
+	0x83,			/* 0x27: Channel Configuration  */
+	0x20,			/* 0x28: MAX TAG per target     */
+	0x0A,			/* 0x29: SCSI Reset Recovering time     */
+	0x00,			/* 0x2A: Channel Configuration4 */
+	0x00,			/* 0x2B: Channel Configuration5 */
+				/* SCSI Channel 1 Target Configuration  */
+				/* 0x2C-0x3B                    */
+	0xC8, 0xC8, 0xC8, 0xC8, 0xC8, 0xC8, 0xC8, 0xC8,
+	0xC8, 0xC8, 0xC8, 0xC8, 0xC8, 0xC8, 0xC8, 0xC8,
+	0x00,			/* 0x3C: Reserved               */
+	0x00,			/* 0x3D: Reserved               */
+	0x00,			/* 0x3E: Reserved               */
+	0x00			/* 0x3F: Checksum               */
+};
+
+
+/***************************************************************************/
+static void waitForPause(unsigned amount)
+{
+	ULONG the_time = jiffies + amount;	/* 0.01 seconds per jiffy */
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+	while (time_before_eq(jiffies, the_time));
+#else
+	while (jiffies < the_time);
+#endif
+}
+
+/***************************************************************************/
+UCHAR waitChipReady(ORC_HCS * hcsp)
+{
+	int i;
+
+	for (i = 0; i < 2000; i++) {	/* Wait 1 second for report timeout     */
+		if (ORC_RD(hcsp->HCS_Base, ORC_HCTRL) & HOSTSTOP)	/* Wait HOSTSTOP set */
+			return (TRUE);
+		waitForPause(5);	/* wait 500ms before try again  */
+	}
+	return (FALSE);
+}
+
+/***************************************************************************/
+UCHAR waitFWReady(ORC_HCS * hcsp)
+{
+	int i;
+
+	for (i = 0; i < 2000; i++) {	/* Wait 1 second for report timeout     */
+		if (ORC_RD(hcsp->HCS_Base, ORC_HSTUS) & RREADY)		/* Wait READY set */
+			return (TRUE);
+		waitForPause(5);	/* wait 500ms before try again  */
+	}
+	return (FALSE);
+}
+
+/***************************************************************************/
+UCHAR waitSCSIRSTdone(ORC_HCS * hcsp)
+{
+	int i;
+
+	for (i = 0; i < 2000; i++) {	/* Wait 1 second for report timeout     */
+		if (!(ORC_RD(hcsp->HCS_Base, ORC_HCTRL) & SCSIRST))	/* Wait SCSIRST done */
+			return (TRUE);
+		waitForPause(5);	/* wait 500ms before try again  */
+	}
+	return (FALSE);
+}
+
+/***************************************************************************/
+UCHAR waitHDOoff(ORC_HCS * hcsp)
+{
+	int i;
+
+	for (i = 0; i < 2000; i++) {	/* Wait 1 second for report timeout     */
+		if (!(ORC_RD(hcsp->HCS_Base, ORC_HCTRL) & HDO))		/* Wait HDO off */
+			return (TRUE);
+		waitForPause(5);	/* wait 500ms before try again  */
+	}
+	return (FALSE);
+}
+
+/***************************************************************************/
+UCHAR waitHDIset(ORC_HCS * hcsp, UCHAR * pData)
+{
+	int i;
+
+	for (i = 0; i < 2000; i++) {	/* Wait 1 second for report timeout     */
+		if ((*pData = ORC_RD(hcsp->HCS_Base, ORC_HSTUS)) & HDI)
+			return (TRUE);	/* Wait HDI set */
+		waitForPause(5);	/* wait 500ms before try again  */
+	}
+	return (FALSE);
+}
+
+/***************************************************************************/
+unsigned short get_FW_version(ORC_HCS * hcsp)
+{
+	UCHAR bData;
+	union {
+		unsigned short sVersion;
+		unsigned char cVersion[2];
+	} Version;
+
+	ORC_WR(hcsp->HCS_Base + ORC_HDATA, ORC_CMD_VERSION);
+	ORC_WR(hcsp->HCS_Base + ORC_HCTRL, HDO);
+	if (waitHDOoff(hcsp) == FALSE)	/* Wait HDO off   */
+		return (FALSE);
+
+	if (waitHDIset(hcsp, &bData) == FALSE)	/* Wait HDI set   */
+		return (FALSE);
+	Version.cVersion[0] = ORC_RD(hcsp->HCS_Base, ORC_HDATA);
+	ORC_WR(hcsp->HCS_Base + ORC_HSTUS, bData);	/* Clear HDI            */
+
+	if (waitHDIset(hcsp, &bData) == FALSE)	/* Wait HDI set   */
+		return (FALSE);
+	Version.cVersion[1] = ORC_RD(hcsp->HCS_Base, ORC_HDATA);
+	ORC_WR(hcsp->HCS_Base + ORC_HSTUS, bData);	/* Clear HDI            */
+
+	return (Version.sVersion);
+}
+
+/***************************************************************************/
+UCHAR set_NVRAM(ORC_HCS * hcsp, unsigned char address, unsigned char value)
+{
+	ORC_WR(hcsp->HCS_Base + ORC_HDATA, ORC_CMD_SET_NVM);	/* Write command */
+	ORC_WR(hcsp->HCS_Base + ORC_HCTRL, HDO);
+	if (waitHDOoff(hcsp) == FALSE)	/* Wait HDO off   */
+		return (FALSE);
+
+	ORC_WR(hcsp->HCS_Base + ORC_HDATA, address);	/* Write address */
+	ORC_WR(hcsp->HCS_Base + ORC_HCTRL, HDO);
+	if (waitHDOoff(hcsp) == FALSE)	/* Wait HDO off   */
+		return (FALSE);
+
+	ORC_WR(hcsp->HCS_Base + ORC_HDATA, value);	/* Write value  */
+	ORC_WR(hcsp->HCS_Base + ORC_HCTRL, HDO);
+	if (waitHDOoff(hcsp) == FALSE)	/* Wait HDO off   */
+		return (FALSE);
+
+	return (TRUE);
+}
+
+/***************************************************************************/
+UCHAR get_NVRAM(ORC_HCS * hcsp, unsigned char address, unsigned char *pDataIn)
+{
+	unsigned char bData;
+
+	ORC_WR(hcsp->HCS_Base + ORC_HDATA, ORC_CMD_GET_NVM);	/* Write command */
+	ORC_WR(hcsp->HCS_Base + ORC_HCTRL, HDO);
+	if (waitHDOoff(hcsp) == FALSE)	/* Wait HDO off   */
+		return (FALSE);
+
+	ORC_WR(hcsp->HCS_Base + ORC_HDATA, address);	/* Write address */
+	ORC_WR(hcsp->HCS_Base + ORC_HCTRL, HDO);
+	if (waitHDOoff(hcsp) == FALSE)	/* Wait HDO off   */
+		return (FALSE);
+
+	if (waitHDIset(hcsp, &bData) == FALSE)	/* Wait HDI set   */
+		return (FALSE);
+	*pDataIn = ORC_RD(hcsp->HCS_Base, ORC_HDATA);
+	ORC_WR(hcsp->HCS_Base + ORC_HSTUS, bData);	/* Clear HDI    */
+
+	return (TRUE);
+}
+
+/***************************************************************************/
+void orc_exec_scb(ORC_HCS * hcsp, ORC_SCB * scbp)
+{
+	scbp->SCB_Status = SCB_POST;
+	ORC_WR(hcsp->HCS_Base + ORC_PQUEUE, scbp->SCB_ScbIdx);
+	return;
+}
+
+
+/***********************************************************************
+ Read SCSI H/A configuration parameters from serial EEPROM
+************************************************************************/
+int se2_rd_all(ORC_HCS * hcsp)
+{
+	int i;
+	UCHAR *np, chksum = 0;
+
+	np = (UCHAR *) nvramp;
+	for (i = 0; i < 64; i++, np++) {	/* <01> */
+		if (get_NVRAM(hcsp, (unsigned char) i, np) == FALSE)
+			return -1;
+//      *np++ = get_NVRAM(hcsp, (unsigned char ) i);
+	}
+
+/*------ Is ckecksum ok ? ------*/
+	np = (UCHAR *) nvramp;
+	for (i = 0; i < 63; i++)
+		chksum += *np++;
+
+	if (nvramp->CheckSum != (UCHAR) chksum)
+		return -1;
+	return 1;
+}
+
+/************************************************************************
+ Update SCSI H/A configuration parameters from serial EEPROM
+*************************************************************************/
+void se2_update_all(ORC_HCS * hcsp)
+{				/* setup default pattern  */
+	int i;
+	UCHAR *np, *np1, chksum = 0;
+
+	/* Calculate checksum first   */
+	np = (UCHAR *) dftNvRam;
+	for (i = 0; i < 63; i++)
+		chksum += *np++;
+	*np = chksum;
+
+	np = (UCHAR *) dftNvRam;
+	np1 = (UCHAR *) nvramp;
+	for (i = 0; i < 64; i++, np++, np1++) {
+		if (*np != *np1) {
+			set_NVRAM(hcsp, (unsigned char) i, *np);
+		}
+	}
+	return;
+}
+
+/*************************************************************************
+ Function name  : read_eeprom
+**************************************************************************/
+void read_eeprom(ORC_HCS * hcsp)
+{
+	if (se2_rd_all(hcsp) != 1) {
+		se2_update_all(hcsp);	/* setup default pattern        */
+		se2_rd_all(hcsp);	/* load again                   */
+	}
+}
+
+
+/***************************************************************************/
+UCHAR load_FW(ORC_HCS * hcsp)
+{
+	U32 dData;
+	USHORT wBIOSAddress;
+	USHORT i;
+	UCHAR *pData, bData;
+
+
+	bData = ORC_RD(hcsp->HCS_Base, ORC_GCFG);
+	ORC_WR(hcsp->HCS_Base + ORC_GCFG, bData | EEPRG);	/* Enable EEPROM programming */
+	ORC_WR(hcsp->HCS_Base + ORC_EBIOSADR2, 0x00);
+	ORC_WRSHORT(hcsp->HCS_Base + ORC_EBIOSADR0, 0x00);
+	if (ORC_RD(hcsp->HCS_Base, ORC_EBIOSDATA) != 0x55) {
+		ORC_WR(hcsp->HCS_Base + ORC_GCFG, bData);	/* Disable EEPROM programming */
+		return (FALSE);
+	}
+	ORC_WRSHORT(hcsp->HCS_Base + ORC_EBIOSADR0, 0x01);
+	if (ORC_RD(hcsp->HCS_Base, ORC_EBIOSDATA) != 0xAA) {
+		ORC_WR(hcsp->HCS_Base + ORC_GCFG, bData);	/* Disable EEPROM programming */
+		return (FALSE);
+	}
+	ORC_WR(hcsp->HCS_Base + ORC_RISCCTL, PRGMRST | DOWNLOAD);	/* Enable SRAM programming */
+	pData = (UCHAR *) & dData;
+	dData = 0;		/* Initial FW address to 0 */
+	ORC_WRSHORT(hcsp->HCS_Base + ORC_EBIOSADR0, 0x10);
+	*pData = ORC_RD(hcsp->HCS_Base, ORC_EBIOSDATA);		/* Read from BIOS */
+	ORC_WRSHORT(hcsp->HCS_Base + ORC_EBIOSADR0, 0x11);
+	*(pData + 1) = ORC_RD(hcsp->HCS_Base, ORC_EBIOSDATA);	/* Read from BIOS */
+	ORC_WRSHORT(hcsp->HCS_Base + ORC_EBIOSADR0, 0x12);
+	*(pData + 2) = ORC_RD(hcsp->HCS_Base, ORC_EBIOSDATA);	/* Read from BIOS */
+	ORC_WR(hcsp->HCS_Base + ORC_EBIOSADR2, *(pData + 2));
+	ORC_WRLONG(hcsp->HCS_Base + ORC_FWBASEADR, dData);	/* Write FW address */
+
+	wBIOSAddress = (USHORT) dData;	/* FW code locate at BIOS address + ? */
+	for (i = 0, pData = (UCHAR *) & dData;	/* Download the code    */
+	     i < 0x1000;	/* Firmware code size = 4K      */
+	     i++, wBIOSAddress++) {
+		ORC_WRSHORT(hcsp->HCS_Base + ORC_EBIOSADR0, wBIOSAddress);
+		*pData++ = ORC_RD(hcsp->HCS_Base, ORC_EBIOSDATA);	/* Read from BIOS */
+		if ((i % 4) == 3) {
+			ORC_WRLONG(hcsp->HCS_Base + ORC_RISCRAM, dData);	/* Write every 4 bytes */
+			pData = (UCHAR *) & dData;
+		}
+	}
+
+	ORC_WR(hcsp->HCS_Base + ORC_RISCCTL, PRGMRST | DOWNLOAD);	/* Reset program count 0 */
+	wBIOSAddress -= 0x1000;	/* Reset the BIOS adddress      */
+	for (i = 0, pData = (UCHAR *) & dData;	/* Check the code       */
+	     i < 0x1000;	/* Firmware code size = 4K      */
+	     i++, wBIOSAddress++) {
+		ORC_WRSHORT(hcsp->HCS_Base + ORC_EBIOSADR0, wBIOSAddress);
+		*pData++ = ORC_RD(hcsp->HCS_Base, ORC_EBIOSDATA);	/* Read from BIOS */
+		if ((i % 4) == 3) {
+			if (ORC_RDLONG(hcsp->HCS_Base, ORC_RISCRAM) != dData) {
+				ORC_WR(hcsp->HCS_Base + ORC_RISCCTL, PRGMRST);	/* Reset program to 0 */
+				ORC_WR(hcsp->HCS_Base + ORC_GCFG, bData);	/*Disable EEPROM programming */
+				return (FALSE);
+			}
+			pData = (UCHAR *) & dData;
+		}
+	}
+	ORC_WR(hcsp->HCS_Base + ORC_RISCCTL, PRGMRST);	/* Reset program to 0   */
+	ORC_WR(hcsp->HCS_Base + ORC_GCFG, bData);	/* Disable EEPROM programming */
+	return (TRUE);
+}
+
+/***************************************************************************/
+void setup_SCBs(ORC_HCS * hcsp)
+{
+	ORC_SCB *pVirScb;
+	int i;
+	UCHAR j;
+	ESCB *pVirEscb;
+	PVOID pPhysEscb;
+	PVOID tPhysEscb;
+
+	j = 0;
+	pVirScb = NULL;
+	tPhysEscb = (PVOID) NULL;
+	pPhysEscb = (PVOID) NULL;
+	/* Setup SCB HCS_Base and SCB Size registers */
+	ORC_WR(hcsp->HCS_Base + ORC_SCBSIZE, orc_num_scb);	/* Total number of SCBs */
+	/* SCB HCS_Base address 0      */
+	ORC_WRLONG(hcsp->HCS_Base + ORC_SCBBASE0, hcsp->HCS_physScbArray);
+	/* SCB HCS_Base address 1      */
+	ORC_WRLONG(hcsp->HCS_Base + ORC_SCBBASE1, hcsp->HCS_physScbArray);
+
+	/* setup scatter list address with one buffer */
+	pVirScb = (ORC_SCB *) hcsp->HCS_virScbArray;
+	pVirEscb = (ESCB *) hcsp->HCS_virEscbArray;
+
+	for (i = 0; i < orc_num_scb; i++) {
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+		pPhysEscb = (PVOID) ((ULONG) hcsp->HCS_virEscbArray + (sizeof(ESCB) * i));
+		pVirScb->SCB_SGPAddr = (U32) VIRT_TO_BUS(pPhysEscb);
+		pVirScb->SCB_SensePAddr = (U32) VIRT_TO_BUS(pPhysEscb);
+#else
+		pPhysEscb = (PVOID) (hcsp->HCS_physEscbArray + (sizeof(ESCB) * i));
+		pVirScb->SCB_SGPAddr = (U32) pPhysEscb;
+		pVirScb->SCB_SensePAddr = (U32) pPhysEscb;
+#endif
+		pVirScb->SCB_EScb = pVirEscb;
+		pVirScb->SCB_ScbIdx = i;
+		pVirScb++;
+		pVirEscb++;
+	}
+
+	return;
+}
+
+/***************************************************************************/
+static void initAFlag(ORC_HCS * hcsp)
+{
+	UCHAR i, j;
+
+	for (i = 0; i < MAX_CHANNELS; i++) {
+		for (j = 0; j < 8; j++) {
+			hcsp->BitAllocFlag[i][j] = 0xffffffff;
+		}
+	}
+}
+
+/***************************************************************************/
+int init_orchid(ORC_HCS * hcsp)
+{
+	UBYTE *readBytep;
+	USHORT revision;
+	UCHAR i;
+
+	initAFlag(hcsp);
+	ORC_WR(hcsp->HCS_Base + ORC_GIMSK, 0xFF);	/* Disable all interrupt        */
+	if (ORC_RD(hcsp->HCS_Base, ORC_HSTUS) & RREADY) {	/* Orchid is ready              */
+		revision = get_FW_version(hcsp);
+		if (revision == 0xFFFF) {
+			ORC_WR(hcsp->HCS_Base + ORC_HCTRL, DEVRST);	/* Reset Host Adapter   */
+			if (waitChipReady(hcsp) == FALSE)
+				return (-1);
+			load_FW(hcsp);	/* Download FW                  */
+			setup_SCBs(hcsp);	/* Setup SCB HCS_Base and SCB Size registers */
+			ORC_WR(hcsp->HCS_Base + ORC_HCTRL, 0);	/* clear HOSTSTOP       */
+			if (waitFWReady(hcsp) == FALSE)
+				return (-1);
+			/* Wait for firmware ready     */
+		} else {
+			setup_SCBs(hcsp);	/* Setup SCB HCS_Base and SCB Size registers */
+		}
+	} else {		/* Orchid is not Ready          */
+		ORC_WR(hcsp->HCS_Base + ORC_HCTRL, DEVRST);	/* Reset Host Adapter   */
+		if (waitChipReady(hcsp) == FALSE)
+			return (-1);
+		load_FW(hcsp);	/* Download FW                  */
+		setup_SCBs(hcsp);	/* Setup SCB HCS_Base and SCB Size registers */
+		ORC_WR(hcsp->HCS_Base + ORC_HCTRL, HDO);	/* Do Hardware Reset &  */
+
+		/*     clear HOSTSTOP  */
+		if (waitFWReady(hcsp) == FALSE)		/* Wait for firmware ready      */
+			return (-1);
+	}
+
+/*------------- get serial EEProm settting -------*/
+
+	read_eeprom(hcsp);
+
+	if (nvramp->Revision != 1)
+		return (-1);
+
+	hcsp->HCS_SCSI_ID = nvramp->SCSI0Id;
+	hcsp->HCS_BIOS = nvramp->BIOSConfig1;
+	hcsp->HCS_MaxTar = MAX_TARGETS;
+	readBytep = (UCHAR *) & (nvramp->Target00Config);
+	for (i = 0; i < 16; readBytep++, i++) {
+		hcsp->TargetFlag[i] = *readBytep;
+		hcsp->MaximumTags[i] = orc_num_scb;
+	}			/* for                          */
+
+	if (nvramp->SCSI0Config & NCC_BUSRESET) {	/* Reset SCSI bus               */
+		hcsp->HCS_Flags |= HCF_SCSI_RESET;
+	}
+	ORC_WR(hcsp->HCS_Base + ORC_GIMSK, 0xFB);	/* enable RP FIFO interrupt     */
+	return (0);
+}
+
+/*****************************************************************************
+ Function name  : orc_reset_scsi_bus
+ Description    : Reset registers, reset a hanging bus and
+                  kill active and disconnected commands for target w/o soft reset
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+int orc_reset_scsi_bus(ORC_HCS * pHCB)
+{				/* I need Host Control Block Information */
+	ULONG flags;
+
+#if 0
+	printk("inia100: enter inia100_reset\n");
+#endif
+
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+	save_flags(flags);
+	cli();
+#else
+	spin_lock_irqsave(&(pHCB->BitAllocFlagLock), flags);
+#endif
+
+	initAFlag(pHCB);
+	/* reset scsi bus */
+	ORC_WR(pHCB->HCS_Base + ORC_HCTRL, SCSIRST);
+	if (waitSCSIRSTdone(pHCB) == FALSE) {
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+		restore_flags(flags);
+#else
+		spin_unlock_irqrestore(&(pHCB->BitAllocFlagLock), flags);
+#endif
+		return (SCSI_RESET_ERROR);
+	} else {
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+		restore_flags(flags);
+#else
+		spin_unlock_irqrestore(&(pHCB->BitAllocFlagLock), flags);
+#endif
+		return (SCSI_RESET_SUCCESS);
+	}
+}
+
+/*****************************************************************************
+ Function name  : orc_device_reset
+ Description    : Reset registers, reset a hanging bus and
+                  kill active and disconnected commands for target w/o soft reset
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+int orc_device_reset(ORC_HCS * pHCB, ULONG SCpnt, unsigned int target, unsigned int ResetFlags)
+{				/* I need Host Control Block Information */
+	ORC_SCB *pScb;
+	ESCB *pVirEscb;
+	ORC_SCB *pVirScb;
+	UCHAR i;
+	ULONG flags;
+
+#if 0
+	printk("inia100: enter inia100_reset\n");
+#endif
+
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+	save_flags(flags);
+	cli();
+#else
+	spin_lock_irqsave(&(pHCB->BitAllocFlagLock), flags);
+#endif
+	pScb = (ORC_SCB *) NULL;
+	pVirEscb = (ESCB *) NULL;
+
+	/* setup scatter list address with one buffer */
+	pVirScb = (ORC_SCB *) pHCB->HCS_virScbArray;
+
+	initAFlag(pHCB);
+	/* device reset */
+	for (i = 0; i < orc_num_scb; i++) {
+		pVirEscb = pVirScb->SCB_EScb;
+		if ((pVirScb->SCB_Status) && (pVirEscb->SCB_Srb == (unsigned char *) SCpnt))
+			break;
+		pVirScb++;
+	}
+
+	if (i == orc_num_scb) {
+		printk("Unable to Reset - No SCB Found\n");
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+		restore_flags(flags);
+#else
+		spin_unlock_irqrestore(&(pHCB->BitAllocFlagLock), flags);
+#endif
+		return (SCSI_RESET_NOT_RUNNING);
+	}
+	if ((pScb = orc_alloc_scb(pHCB)) == NULL) {
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+		restore_flags(flags);
+#else
+		spin_unlock_irqrestore(&(pHCB->BitAllocFlagLock), flags);
+#endif
+		return (SCSI_RESET_NOT_RUNNING);
+	}
+	pScb->SCB_Opcode = ORC_BUSDEVRST;
+	pScb->SCB_Target = target;
+	pScb->SCB_HaStat = 0;
+	pScb->SCB_TaStat = 0;
+	pScb->SCB_Status = 0x0;
+	pScb->SCB_Link = 0xFF;
+	pScb->SCB_Reserved0 = 0;
+	pScb->SCB_Reserved1 = 0;
+	pScb->SCB_XferLen = 0;
+	pScb->SCB_SGLen = 0;
+
+	pVirEscb->SCB_Srb = 0;
+	if (ResetFlags & SCSI_RESET_SYNCHRONOUS) {
+		pVirEscb->SCB_Srb = (unsigned char *) SCpnt;
+	}
+	orc_exec_scb(pHCB, pScb);	/* Start execute SCB            */
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+	restore_flags(flags);
+#else
+	spin_unlock_irqrestore(&(pHCB->BitAllocFlagLock), flags);
+#endif
+	return SCSI_RESET_PENDING;
+}
+
+
+/***************************************************************************/
+ORC_SCB *orc_alloc_scb(ORC_HCS * hcsp)
+{
+	ORC_SCB *pTmpScb;
+	UCHAR Ch;
+	ULONG idx;
+	UCHAR index;
+	UCHAR i;
+	ULONG flags;
+
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+	save_flags(flags);
+	cli();
+#else
+	spin_lock_irqsave(&(hcsp->BitAllocFlagLock), flags);
+#endif
+	Ch = hcsp->HCS_Index;
+	for (i = 0; i < 8; i++) {
+		for (index = 0; index < 32; index++) {
+			if ((hcsp->BitAllocFlag[Ch][i] >> index) & 0x01) {
+				hcsp->BitAllocFlag[Ch][i] &= ~(1 << index);
+				break;
+			}
+		}
+		idx = index + 32 * i;
+		pTmpScb = (PVOID) ((ULONG) hcsp->HCS_virScbArray + (idx * sizeof(ORC_SCB)));
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+		restore_flags(flags);
+#else
+		spin_unlock_irqrestore(&(hcsp->BitAllocFlagLock), flags);
+#endif
+		return (pTmpScb);
+	}
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+	restore_flags(flags);
+#else
+	spin_unlock_irqrestore(&(hcsp->BitAllocFlagLock), flags);
+#endif
+	return (NULL);
+}
+
+
+/***************************************************************************/
+void orc_release_scb(ORC_HCS * hcsp, ORC_SCB * scbp)
+{
+	ULONG flags;
+	UCHAR Index;
+	UCHAR i;
+	UCHAR Ch;
+
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+	save_flags(flags);
+	cli();
+#else
+	spin_lock_irqsave(&(hcsp->BitAllocFlagLock), flags);
+#endif
+	Ch = hcsp->HCS_Index;
+	Index = scbp->SCB_ScbIdx;
+	i = Index / 32;
+	Index %= 32;
+	hcsp->BitAllocFlag[Ch][i] |= (1 << Index);
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+	restore_flags(flags);
+#else
+	spin_unlock_irqrestore(&(hcsp->BitAllocFlagLock), flags);
+#endif
+}
+
+
+/*****************************************************************************
+ Function name	: Addinia100_into_Adapter_table
+ Description	: This function will scan PCI bus to get all Orchid card
+ Input		: None.
+ Output		: None.
+ Return		: SUCCESSFUL	- Successful scan
+ ohterwise	- No drives founded
+*****************************************************************************/
+int Addinia100_into_Adapter_table(WORD wBIOS, WORD wBASE, BYTE bInterrupt,
+				  BYTE bBus, BYTE bDevice)
+{
+	unsigned int i, j;
+
+	for (i = 0; i < MAX_SUPPORTED_ADAPTERS; i++) {
+		if (inia100_adpt[i].ADPT_BIOS < wBIOS)
+			continue;
+		if (inia100_adpt[i].ADPT_BIOS == wBIOS) {
+			if (inia100_adpt[i].ADPT_BASE == wBASE)
+				if (inia100_adpt[i].ADPT_Bus != 0xFF)
+					return (FAILURE);
+				else if (inia100_adpt[i].ADPT_BASE < wBASE)
+					continue;
+		}
+		for (j = MAX_SUPPORTED_ADAPTERS - 1; j > i; j--) {
+			inia100_adpt[j].ADPT_BASE = inia100_adpt[j - 1].ADPT_BASE;
+			inia100_adpt[j].ADPT_INTR = inia100_adpt[j - 1].ADPT_INTR;
+			inia100_adpt[j].ADPT_BIOS = inia100_adpt[j - 1].ADPT_BIOS;
+			inia100_adpt[j].ADPT_Bus = inia100_adpt[j - 1].ADPT_Bus;
+			inia100_adpt[j].ADPT_Device = inia100_adpt[j - 1].ADPT_Device;
+		}
+		inia100_adpt[i].ADPT_BASE = wBASE;
+		inia100_adpt[i].ADPT_INTR = bInterrupt;
+		inia100_adpt[i].ADPT_BIOS = wBIOS;
+		inia100_adpt[i].ADPT_Bus = bBus;
+		inia100_adpt[i].ADPT_Device = bDevice;
+		return (SUCCESSFUL);
+	}
+	return (FAILURE);
+}
+
+
+/*****************************************************************************
+ Function name	: init_inia100Adapter_table
+ Description	: This function will scan PCI bus to get all Orchid card
+ Input		: None.
+ Output		: None.
+ Return		: SUCCESSFUL	- Successful scan
+ ohterwise	- No drives founded
+*****************************************************************************/
+void init_inia100Adapter_table(void)
+{
+	int i;
+
+	for (i = 0; i < MAX_SUPPORTED_ADAPTERS; i++) {	/* Initialize adapter structure */
+		inia100_adpt[i].ADPT_BIOS = 0xffff;
+		inia100_adpt[i].ADPT_BASE = 0xffff;
+		inia100_adpt[i].ADPT_INTR = 0xff;
+		inia100_adpt[i].ADPT_Bus = 0xff;
+		inia100_adpt[i].ADPT_Device = 0xff;
+	}
+}
+
+/*****************************************************************************
+ Function name  : get_orcPCIConfig
+ Description    : 
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+void get_orcPCIConfig(ORC_HCS * pCurHcb, int ch_idx)
+{
+	pCurHcb->HCS_Base = inia100_adpt[ch_idx].ADPT_BASE;	/* Supply base address  */
+	pCurHcb->HCS_BIOS = inia100_adpt[ch_idx].ADPT_BIOS;	/* Supply BIOS address  */
+	pCurHcb->HCS_Intr = inia100_adpt[ch_idx].ADPT_INTR;	/* Supply interrupt line */
+	return;
+}
+
+
+/*****************************************************************************
+ Function name  : abort_SCB
+ Description    : Abort a queued command.
+	                 (commands that are on the bus can't be aborted easily)
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+int abort_SCB(ORC_HCS * hcsp, ORC_SCB * pScb)
+{
+	unsigned char bData, bStatus;
+
+	ORC_WR(hcsp->HCS_Base + ORC_HDATA, ORC_CMD_ABORT_SCB);	/* Write command */
+	ORC_WR(hcsp->HCS_Base + ORC_HCTRL, HDO);
+	if (waitHDOoff(hcsp) == FALSE)	/* Wait HDO off   */
+		return (FALSE);
+
+	ORC_WR(hcsp->HCS_Base + ORC_HDATA, pScb->SCB_ScbIdx);	/* Write address */
+	ORC_WR(hcsp->HCS_Base + ORC_HCTRL, HDO);
+	if (waitHDOoff(hcsp) == FALSE)	/* Wait HDO off   */
+		return (FALSE);
+
+	if (waitHDIset(hcsp, &bData) == FALSE)	/* Wait HDI set   */
+		return (FALSE);
+	bStatus = ORC_RD(hcsp->HCS_Base, ORC_HDATA);
+	ORC_WR(hcsp->HCS_Base + ORC_HSTUS, bData);	/* Clear HDI    */
+
+	if (bStatus == 1)	/* 0 - Successfully               */
+		return (FALSE);	/* 1 - Fail                     */
+	return (TRUE);
+}
+
+/*****************************************************************************
+ Function name  : inia100_abort
+ Description    : Abort a queued command.
+	                 (commands that are on the bus can't be aborted easily)
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+int orc_abort_srb(ORC_HCS * hcsp, ULONG SCpnt)
+{
+	ESCB *pVirEscb;
+	ORC_SCB *pVirScb;
+	UCHAR i;
+	ULONG flags;
+
+#if 0
+	printk("inia100: abort SRB \n");
+#endif
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+	save_flags(flags);
+	cli();
+#else
+	spin_lock_irqsave(&(hcsp->BitAllocFlagLock), flags);
+#endif
+
+	pVirScb = (ORC_SCB *) hcsp->HCS_virScbArray;
+
+	for (i = 0; i < orc_num_scb; i++, pVirScb++) {
+		pVirEscb = pVirScb->SCB_EScb;
+		if ((pVirScb->SCB_Status) && (pVirEscb->SCB_Srb == (unsigned char *) SCpnt)) {
+			if (pVirScb->SCB_TagMsg == 0) {
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+				restore_flags(flags);
+#else
+				spin_unlock_irqrestore(&(hcsp->BitAllocFlagLock), flags);
+#endif
+				return (SCSI_ABORT_BUSY);
+			} else {
+				if (abort_SCB(hcsp, pVirScb)) {
+					pVirEscb->SCB_Srb = NULL;
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+					restore_flags(flags);
+#else
+					spin_unlock_irqrestore(&(hcsp->BitAllocFlagLock), flags);
+#endif
+					return (SCSI_ABORT_SUCCESS);
+				} else {
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+					restore_flags(flags);
+#else
+					spin_unlock_irqrestore(&(hcsp->BitAllocFlagLock), flags);
+#endif
+					return (SCSI_ABORT_NOT_RUNNING);
+				}
+			}
+		}
+	}
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2,1,95)
+	restore_flags(flags);
+#else
+	spin_unlock_irqrestore(&(hcsp->BitAllocFlagLock), flags);
+#endif
+	return (SCSI_ABORT_NOT_RUNNING);
+}
+
+/***********************************************************************
+ Routine Description:
+	  This is the interrupt service routine for the Orchid SCSI adapter.
+	  It reads the interrupt register to determine if the adapter is indeed
+	  the source of the interrupt and clears the interrupt at the device.
+ Arguments:
+	  HwDeviceExtension - HBA miniport driver's adapter data storage
+ Return Value:
+***********************************************************************/
+void orc_interrupt(
+			  ORC_HCS * hcsp
+)
+{
+	BYTE bScbIdx;
+	ORC_SCB *pScb;
+
+	if (ORC_RD(hcsp->HCS_Base, ORC_RQUEUECNT) == 0) {
+		return;		// (FALSE);
+
+	}
+	do {
+		bScbIdx = ORC_RD(hcsp->HCS_Base, ORC_RQUEUE);
+
+		pScb = (ORC_SCB *) ((ULONG) hcsp->HCS_virScbArray + (ULONG) (sizeof(ORC_SCB) * bScbIdx));
+		pScb->SCB_Status = 0x0;
+
+		inia100SCBPost((BYTE *) hcsp, (BYTE *) pScb);
+	} while (ORC_RD(hcsp->HCS_Base, ORC_RQUEUECNT));
+	return;			//(TRUE);
+
+}				/* End of I1060Interrupt() */
diff -urN linux-2.0.37-pre6/drivers/scsi/i60uscsi.h linux-2.0.37-pre7/drivers/scsi/i60uscsi.h
--- linux-2.0.37-pre6/drivers/scsi/i60uscsi.h	1969-12-31 16:00:00.000000000 -0800
+++ linux-2.0.37-pre7/drivers/scsi/i60uscsi.h	2003-08-15 15:04:36.000000000 -0700
@@ -0,0 +1,572 @@
+/**************************************************************************
+ * Initio A100 device driver for Linux.
+ *
+ * Copyright (c) 1994-1998 Initio Corporation
+ * All rights reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2, or (at your option)
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; see the file COPYING.  If not, write to
+ * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+ *
+ * --------------------------------------------------------------------------
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions, and the following disclaimer,
+ *    without modification, immediately at the beginning of the file.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ * 3. The name of the author may not be used to endorse or promote products
+ *    derived from this software without specific prior written permission.
+ *
+ * Where this Software is combined with software released under the terms of 
+ * the GNU Public License ("GPL") and the terms of the GPL would require the 
+ * combined work to also be released under the terms of the GPL, the terms
+ * and conditions of this License will apply in addition to those of the
+ * GPL with the exception of any terms or conditions of this License that
+ * conflict with, or are expressly prohibited by, the GPL.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR
+ * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ **************************************************************************
+ *
+ * Module: inia100.h
+ * Description: INI-A100U2W LINUX device driver header
+ * Revision History:
+ *	06/18/98 HL, Initial Version 1.02
+ *	12/19/98 bv, v1.02a Use spinlocks for 2.1.95 and up.
+ **************************************************************************/
+
+#define ULONG   unsigned long
+#define PVOID   void *
+#define USHORT  unsigned short
+#define UCHAR   unsigned char
+#define BYTE    unsigned char
+#define WORD    unsigned short
+#define DWORD   unsigned long
+#define UBYTE   unsigned char
+#define UWORD   unsigned short
+#define UDWORD  unsigned long
+#ifdef ALPHA
+#define U32     unsigned int
+#else
+#define U32     unsigned long
+#endif
+
+#ifndef NULL
+#define NULL     0		/* zero          */
+#endif
+#ifndef TRUE
+#define TRUE     (1)		/* boolean true  */
+#endif
+#ifndef FALSE
+#define FALSE    (0)		/* boolean false */
+#endif
+#ifndef FAILURE
+#define FAILURE  (-1)
+#endif
+#if 1
+#define ORC_MAXQUEUE		245
+#else
+#define ORC_MAXQUEUE		25
+#endif
+
+#define TOTAL_SG_ENTRY		32
+#define MAX_TARGETS		16
+#define IMAX_CDB			15
+#define SENSE_SIZE		14
+#define MAX_SUPPORTED_ADAPTERS  4
+#define SUCCESSFUL              0x00
+
+#define I920_DEVICE_ID	0x0002	/* Initio's inic-950 product ID   */
+
+/************************************************************************/
+/*              Scatter-Gather Element Structure                        */
+/************************************************************************/
+typedef struct ORC_SG_Struc {
+	U32 SG_Ptr;		/* Data Pointer */
+	U32 SG_Len;		/* Data Length */
+} ORC_SG;
+
+typedef struct inia100_Adpt_Struc {
+	UWORD ADPT_BIOS;	/* 0 */
+	UWORD ADPT_BASE;	/* 1 */
+	UBYTE ADPT_Bus;		/* 2 */
+	UBYTE ADPT_Device;	/* 3 */
+	UBYTE ADPT_INTR;	/* 4 */
+} INIA100_ADPT_STRUCT;
+
+
+/* SCSI related definition                                              */
+#define DISC_NOT_ALLOW          0x80	/* Disconnect is not allowed    */
+#define DISC_ALLOW              0xC0	/* Disconnect is allowed        */
+
+
+#define ORC_OFFSET_SCB			16
+#define ORC_MAX_SCBS		    250
+#define MAX_CHANNELS       2
+#define MAX_ESCB_ELE				64
+#define TCF_DRV_255_63     0x0400
+
+/********************************************************/
+/*      Orchid Configuration Register Set               */
+/********************************************************/
+#define ORC_PVID	0x00	/* Vendor ID                      */
+#define ORC_VENDOR_ID	0x1101	/* Orchid vendor ID               */
+#define ORC_PDID        0x02	/* Device ID                    */
+#define ORC_DEVICE_ID	0x1060	/* Orchid device ID               */
+#define ORC_COMMAND	0x04	/* Command                        */
+#define BUSMS		0x04	/* BUS MASTER Enable              */
+#define IOSPA		0x01	/* IO Space Enable                */
+#define ORC_STATUS	0x06	/* Status register                */
+#define ORC_REVISION	0x08	/* Revision number                */
+#define ORC_BASE	0x10	/* Base address                   */
+#define ORC_BIOS	0x50	/* Expansion ROM base address     */
+#define ORC_INT_NUM	0x3C	/* Interrupt line         */
+#define ORC_INT_PIN	0x3D	/* Interrupt pin          */
+
+
+/********************************************************/
+/*      Orchid Host Command Set                         */
+/********************************************************/
+#define ORC_CMD_NOP		0x00	/* Host command - NOP             */
+#define ORC_CMD_VERSION		0x01	/* Host command - Get F/W version */
+#define ORC_CMD_ECHO		0x02	/* Host command - ECHO            */
+#define ORC_CMD_SET_NVM		0x03	/* Host command - Set NVRAM       */
+#define ORC_CMD_GET_NVM		0x04	/* Host command - Get NVRAM       */
+#define ORC_CMD_GET_BUS_STATUS	0x05	/* Host command - Get SCSI bus status */
+#define ORC_CMD_ABORT_SCB	0x06	/* Host command - Abort SCB       */
+#define ORC_CMD_ISSUE_SCB	0x07	/* Host command - Issue SCB       */
+
+/********************************************************/
+/*              Orchid Register Set                     */
+/********************************************************/
+#define ORC_GINTS	0xA0	/* Global Interrupt Status        */
+#define QINT		0x04	/* Reply Queue Interrupt  */
+#define ORC_GIMSK	0xA1	/* Global Interrupt MASK  */
+#define MQINT		0x04	/* Mask Reply Queue Interrupt     */
+#define	ORC_GCFG	0xA2	/* Global Configure               */
+#define EEPRG		0x01	/* Enable EEPROM programming */
+#define	ORC_GSTAT	0xA3	/* Global status          */
+#define WIDEBUS		0x10	/* Wide SCSI Devices connected    */
+#define ORC_HDATA	0xA4	/* Host Data                      */
+#define ORC_HCTRL	0xA5	/* Host Control                   */
+#define SCSIRST		0x80	/* SCSI bus reset         */
+#define HDO			0x40	/* Host data out          */
+#define HOSTSTOP		0x02	/* Host stop RISC engine  */
+#define DEVRST		0x01	/* Device reset                   */
+#define ORC_HSTUS	0xA6	/* Host Status                    */
+#define HDI			0x02	/* Host data in                   */
+#define RREADY		0x01	/* RISC engine is ready to receive */
+#define	ORC_NVRAM	0xA7	/* Nvram port address             */
+#define SE2CS		0x008
+#define SE2CLK		0x004
+#define SE2DO		0x002
+#define SE2DI		0x001
+#define ORC_PQUEUE	0xA8	/* Posting queue FIFO             */
+#define ORC_PQCNT	0xA9	/* Posting queue FIFO Cnt */
+#define ORC_RQUEUE	0xAA	/* Reply queue FIFO               */
+#define ORC_RQUEUECNT	0xAB	/* Reply queue FIFO Cnt           */
+#define	ORC_FWBASEADR	0xAC	/* Firmware base address  */
+
+#define	ORC_EBIOSADR0 0xB0	/* External Bios address */
+#define	ORC_EBIOSADR1 0xB1	/* External Bios address */
+#define	ORC_EBIOSADR2 0xB2	/* External Bios address */
+#define	ORC_EBIOSDATA 0xB3	/* External Bios address */
+
+#define	ORC_SCBSIZE	0xB7	/* SCB size register              */
+#define	ORC_SCBBASE0	0xB8	/* SCB base address 0             */
+#define	ORC_SCBBASE1	0xBC	/* SCB base address 1             */
+
+#define	ORC_RISCCTL	0xE0	/* RISC Control                   */
+#define PRGMRST		0x002
+#define DOWNLOAD		0x001
+#define	ORC_PRGMCTR0	0xE2	/* RISC program counter           */
+#define	ORC_PRGMCTR1	0xE3	/* RISC program counter           */
+#define	ORC_RISCRAM	0xEC	/* RISC RAM data port 4 bytes     */
+
+typedef struct orc_extended_scb {	/* Extended SCB                 */
+	ORC_SG ESCB_SGList[TOTAL_SG_ENTRY];	/*0 Start of SG list              */
+	unsigned char *SCB_Srb;	/*50 SRB Pointer */
+//         Scsi_Cmnd    *SCB_Srb;       /*50 SRB Pointer */
+} ESCB;
+
+/***********************************************************************
+		SCSI Control Block
+************************************************************************/
+typedef struct orc_scb {	/* Scsi_Ctrl_Blk                */
+	UBYTE SCB_Opcode;	/*00 SCB command code&residual  */
+	UBYTE SCB_Flags;	/*01 SCB Flags                  */
+	UBYTE SCB_Target;	/*02 Target Id                  */
+	UBYTE SCB_Lun;		/*03 Lun                        */
+	U32 SCB_Reserved0;	/*04 Reserved for ORCHID must 0 */
+	U32 SCB_XferLen;	/*08 Data Transfer Length       */
+	U32 SCB_Reserved1;	/*0C Reserved for ORCHID must 0 */
+	U32 SCB_SGLen;		/*10 SG list # * 8              */
+	U32 SCB_SGPAddr;	/*14 SG List Buf physical Addr  */
+	U32 SCB_SGPAddrHigh;	/*18 SG Buffer high physical Addr */
+	UBYTE SCB_HaStat;	/*1C Host Status                */
+	UBYTE SCB_TaStat;	/*1D Target Status              */
+	UBYTE SCB_Status;	/*1E SCB status                 */
+	UBYTE SCB_Link;		/*1F Link pointer, default 0xFF */
+	UBYTE SCB_SenseLen;	/*20 Sense Allocation Length    */
+	UBYTE SCB_CDBLen;	/*21 CDB Length                 */
+	UBYTE SCB_Ident;	/*22 Identify                   */
+	UBYTE SCB_TagMsg;	/*23 Tag Message                */
+	UBYTE SCB_CDB[IMAX_CDB];	/*24 SCSI CDBs                  */
+	UBYTE SCB_ScbIdx;	/*3C Index for this ORCSCB      */
+	U32 SCB_SensePAddr;	/*34 Sense Buffer physical Addr */
+
+	ESCB *SCB_EScb;		/*38 Extended SCB Pointer       */
+#ifndef ALPHA
+	UBYTE SCB_Reserved2[4];	/*3E Reserved for Driver use    */
+#endif
+} ORC_SCB;
+
+/* Opcodes of ORCSCB_Opcode */
+#define ORC_EXECSCSI	0x00	/* SCSI initiator command with residual */
+#define ORC_BUSDEVRST	0x01	/* SCSI Bus Device Reset  */
+
+/* Status of ORCSCB_Status */
+#define SCB_COMPLETE	0x00	/* SCB request completed  */
+#define SCB_POST	0x01	/* SCB is posted by the HOST      */
+
+/* Bit Definition for ORCSCB_Flags */
+#define SCF_DISINT	0x01	/* Disable HOST interrupt */
+#define SCF_DIR		0x18	/* Direction bits         */
+#define SCF_NO_DCHK	0x00	/* Direction determined by SCSI   */
+#define SCF_DIN		0x08	/* From Target to Initiator       */
+#define SCF_DOUT	0x10	/* From Initiator to Target       */
+#define SCF_NO_XF	0x18	/* No data transfer               */
+#define SCF_POLL   0x40
+
+/* Error Codes for ORCSCB_HaStat */
+#define HOST_SEL_TOUT	0x11
+#define HOST_DO_DU	0x12
+#define HOST_BUS_FREE	0x13
+#define HOST_BAD_PHAS	0x14
+#define HOST_INV_CMD	0x16
+#define HOST_SCSI_RST	0x1B
+#define HOST_DEV_RST	0x1C
+
+
+/* Error Codes for ORCSCB_TaStat */
+#define TARGET_CHK_COND	0x02
+#define TARGET_BUSY	0x08
+#define TARGET_TAG_FULL	0x28
+
+
+/* Queue tag msg: Simple_quque_tag, Head_of_queue_tag, Ordered_queue_tag */
+#define MSG_STAG	0x20
+#define MSG_HTAG	0x21
+#define MSG_OTAG	0x22
+
+#define MSG_IGNOREWIDE	0x23
+
+#define MSG_IDENT	0x80
+#define MSG_DISC	0x40	/* Disconnect allowed             */
+
+
+/* SCSI MESSAGE */
+#define	MSG_EXTEND	0x01
+#define	MSG_SDP		0x02
+#define	MSG_ABORT	0x06
+#define	MSG_REJ		0x07
+#define	MSG_NOP		0x08
+#define	MSG_PARITY	0x09
+#define	MSG_DEVRST	0x0C
+#define	MSG_STAG	0x20
+
+/***********************************************************************
+		Target Device Control Structure
+**********************************************************************/
+
+typedef struct ORC_Tar_Ctrl_Struc {
+	UBYTE TCS_DrvDASD;	/* 6 */
+	UBYTE TCS_DrvSCSI;	/* 7 */
+	UBYTE TCS_DrvHead;	/* 8 */
+	UWORD TCS_DrvFlags;	/* 4 */
+	UBYTE TCS_DrvSector;	/* 7 */
+} ORC_TCS, *PORC_TCS;
+
+/* Bit Definition for TCF_DrvFlags */
+#define	TCS_DF_NODASD_SUPT	0x20	/* Suppress OS/2 DASD Mgr support */
+#define	TCS_DF_NOSCSI_SUPT	0x40	/* Suppress OS/2 SCSI Mgr support */
+
+
+/***********************************************************************
+              Host Adapter Control Structure
+************************************************************************/
+typedef struct ORC_Ha_Ctrl_Struc {
+	USHORT HCS_Base;	/* 00 */
+	UBYTE HCS_Index;	/* 02 */
+	UBYTE HCS_Intr;		/* 04 */
+	UBYTE HCS_SCSI_ID;	/* 06    H/A SCSI ID */
+	UBYTE HCS_BIOS;		/* 07    BIOS configuration */
+
+	UBYTE HCS_Flags;	/* 0B */
+	UBYTE HCS_HAConfig1;	/* 1B    SCSI0MAXTags */
+	UBYTE HCS_MaxTar;	/* 1B    SCSI0MAXTags */
+
+	USHORT HCS_Units;	/* Number of units this adapter  */
+	USHORT HCS_AFlags;	/* Adapter info. defined flags   */
+	ULONG HCS_Timeout;	/* Adapter timeout value   */
+	PVOID HCS_virScbArray;	/* 28 Virtual Pointer to SCB array     */
+	U32 HCS_physScbArray;	/* Scb Physical address */
+	PVOID HCS_virEscbArray;	/* Virtual pointer to ESCB Scatter list */
+	U32 HCS_physEscbArray;	/* scatter list Physical address */
+	UBYTE TargetFlag[16];	/* 30  target configuration, TCF_EN_TAG */
+	UBYTE MaximumTags[16];	/* 40  ORC_MAX_SCBS */
+	UBYTE ActiveTags[16][16];	/* 50 */
+	ORC_TCS HCS_Tcs[16];	/* 28 */
+	U32 BitAllocFlag[MAX_CHANNELS][8];	/* Max STB is 256, So 256/32 */
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+	spinlock_t BitAllocFlagLock;
+#endif
+	ULONG pSRB_head;
+	ULONG pSRB_tail;
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+	spinlock_t pSRB_lock;
+#endif
+} ORC_HCS;
+
+/* Bit Definition for HCS_Flags */
+
+#define HCF_SCSI_RESET	0x01	/* SCSI BUS RESET         */
+#define HCF_PARITY    	0x02	/* parity card                    */
+#define HCF_LVDS     	0x10	/* parity card                    */
+
+/* Bit Definition for TargetFlag */
+
+#define TCF_EN_255	    0x08
+#define TCF_EN_TAG	    0x10
+#define TCF_BUSY	      0x20
+#define TCF_DISCONNECT	0x40
+#define TCF_SPIN_UP	  0x80
+
+/* Bit Definition for HCS_AFlags */
+#define	HCS_AF_IGNORE		0x01	/* Adapter ignore         */
+#define	HCS_AF_DISABLE_RESET	0x10	/* Adapter disable reset  */
+#define	HCS_AF_DISABLE_ADPT	0x80	/* Adapter disable                */
+
+
+/*---------------------------------------*/
+/* TimeOut for RESET to complete (30s)   */
+/*                                       */
+/* After a RESET the drive is checked    */
+/* every 200ms.                          */
+/*---------------------------------------*/
+#define DELAYED_RESET_MAX       (30*1000L)
+#define DELAYED_RESET_INTERVAL  200L
+
+/*----------------------------------------------*/
+/* TimeOut for IRQ from last interrupt (5s)     */
+/*----------------------------------------------*/
+#define IRQ_TIMEOUT_INTERVAL    (5*1000L)
+
+/*----------------------------------------------*/
+/* Retry Delay interval (200ms)                 */
+/*----------------------------------------------*/
+#define DELAYED_RETRY_INTERVAL  200L
+
+#define	INQUIRY_SIZE		36
+#define	CAPACITY_SIZE		8
+#define	DEFAULT_SENSE_LEN	14
+
+#define	DEVICE_NOT_FOUND	0x86
+
+/*----------------------------------------------*/
+/* Definition for PCI device                    */
+/*----------------------------------------------*/
+#define	MAX_PCI_DEVICES	21
+#define	MAX_PCI_BUSES	8
+
+typedef struct Adpt_Struc {
+	USHORT ADPT_BIOS;	/* 0 */
+	UBYTE ADPT_BASE;	/* 1 */
+	UBYTE ADPT_Bus;		/* 2 */
+	UBYTE ADPT_Device;	/* 3 */
+	UBYTE ADPT_Reserved[3];
+} JACS, *PJACS;
+
+typedef struct _NVRAM {
+/*----------header ---------------*/
+	UCHAR SubVendorID0;	/* 00 - Sub Vendor ID           */
+	UCHAR SubVendorID1;	/* 00 - Sub Vendor ID           */
+	UCHAR SubSysID0;	/* 02 - Sub System ID           */
+	UCHAR SubSysID1;	/* 02 - Sub System ID           */
+	UCHAR SubClass;		/* 04 - Sub Class               */
+	UCHAR VendorID0;	/* 05 - Vendor ID               */
+	UCHAR VendorID1;	/* 05 - Vendor ID               */
+	UCHAR DeviceID0;	/* 07 - Device ID               */
+	UCHAR DeviceID1;	/* 07 - Device ID               */
+	UCHAR Reserved0[2];	/* 09 - Reserved                */
+	UCHAR Revision;		/* 0B - Revision of data structure */
+	/* ----Host Adapter Structure ---- */
+	UCHAR NumOfCh;		/* 0C - Number of SCSI channel  */
+	UCHAR BIOSConfig1;	/* 0D - BIOS configuration 1    */
+	UCHAR BIOSConfig2;	/* 0E - BIOS boot channel&target ID */
+	UCHAR BIOSConfig3;	/* 0F - BIOS configuration 3    */
+	/* ----SCSI channel Structure ---- */
+	/* from "CTRL-I SCSI Host Adapter SetUp menu "  */
+	UCHAR SCSI0Id;		/* 10 - Channel 0 SCSI ID       */
+	UCHAR SCSI0Config;	/* 11 - Channel 0 SCSI configuration */
+	UCHAR SCSI0MaxTags;	/* 12 - Channel 0 Maximum tags  */
+	UCHAR SCSI0ResetTime;	/* 13 - Channel 0 Reset recovering time */
+	UCHAR ReservedforChannel0[2];	/* 14 - Reserved                */
+
+	/* ----SCSI target Structure ----  */
+	/* from "CTRL-I SCSI device SetUp menu "                        */
+	UCHAR Target00Config;	/* 16 - Channel 0 Target 0 config */
+	UCHAR Target01Config;	/* 17 - Channel 0 Target 1 config */
+	UCHAR Target02Config;	/* 18 - Channel 0 Target 2 config */
+	UCHAR Target03Config;	/* 19 - Channel 0 Target 3 config */
+	UCHAR Target04Config;	/* 1A - Channel 0 Target 4 config */
+	UCHAR Target05Config;	/* 1B - Channel 0 Target 5 config */
+	UCHAR Target06Config;	/* 1C - Channel 0 Target 6 config */
+	UCHAR Target07Config;	/* 1D - Channel 0 Target 7 config */
+	UCHAR Target08Config;	/* 1E - Channel 0 Target 8 config */
+	UCHAR Target09Config;	/* 1F - Channel 0 Target 9 config */
+	UCHAR Target0AConfig;	/* 20 - Channel 0 Target A config */
+	UCHAR Target0BConfig;	/* 21 - Channel 0 Target B config */
+	UCHAR Target0CConfig;	/* 22 - Channel 0 Target C config */
+	UCHAR Target0DConfig;	/* 23 - Channel 0 Target D config */
+	UCHAR Target0EConfig;	/* 24 - Channel 0 Target E config */
+	UCHAR Target0FConfig;	/* 25 - Channel 0 Target F config */
+
+	UCHAR SCSI1Id;		/* 26 - Channel 1 SCSI ID       */
+	UCHAR SCSI1Config;	/* 27 - Channel 1 SCSI configuration */
+	UCHAR SCSI1MaxTags;	/* 28 - Channel 1 Maximum tags  */
+	UCHAR SCSI1ResetTime;	/* 29 - Channel 1 Reset recovering time */
+	UCHAR ReservedforChannel1[2];	/* 2A - Reserved                */
+
+	/* ----SCSI target Structure ----  */
+	/* from "CTRL-I SCSI device SetUp menu "                                          */
+	UCHAR Target10Config;	/* 2C - Channel 1 Target 0 config */
+	UCHAR Target11Config;	/* 2D - Channel 1 Target 1 config */
+	UCHAR Target12Config;	/* 2E - Channel 1 Target 2 config */
+	UCHAR Target13Config;	/* 2F - Channel 1 Target 3 config */
+	UCHAR Target14Config;	/* 30 - Channel 1 Target 4 config */
+	UCHAR Target15Config;	/* 31 - Channel 1 Target 5 config */
+	UCHAR Target16Config;	/* 32 - Channel 1 Target 6 config */
+	UCHAR Target17Config;	/* 33 - Channel 1 Target 7 config */
+	UCHAR Target18Config;	/* 34 - Channel 1 Target 8 config */
+	UCHAR Target19Config;	/* 35 - Channel 1 Target 9 config */
+	UCHAR Target1AConfig;	/* 36 - Channel 1 Target A config */
+	UCHAR Target1BConfig;	/* 37 - Channel 1 Target B config */
+	UCHAR Target1CConfig;	/* 38 - Channel 1 Target C config */
+	UCHAR Target1DConfig;	/* 39 - Channel 1 Target D config */
+	UCHAR Target1EConfig;	/* 3A - Channel 1 Target E config */
+	UCHAR Target1FConfig;	/* 3B - Channel 1 Target F config */
+	UCHAR reserved[3];	/* 3C - Reserved                */
+	/* ---------- CheckSum ----------       */
+	UCHAR CheckSum;		/* 3F - Checksum of NVRam       */
+} NVRAM, *PNVRAM;
+
+/* Bios Configuration for nvram->BIOSConfig1                            */
+#define NBC_BIOSENABLE	0x01	/* BIOS enable                    */
+#define NBC_CDROM	0x02	/* Support bootable CDROM */
+#define NBC_REMOVABLE	0x04	/* Support removable drive        */
+
+/* Bios Configuration for nvram->BIOSConfig2                            */
+#define	NBB_TARGET_MASK	0x0F	/* Boot SCSI target ID number     */
+#define	NBB_CHANL_MASK	0xF0	/* Boot SCSI channel number       */
+
+/* Bit definition for nvram->SCSIConfig                                 */
+#define NCC_BUSRESET	0x01	/* Reset SCSI bus at power up     */
+#define NCC_PARITYCHK	0x02	/* SCSI parity enable             */
+#define NCC_LVDS	0x10	/* Enable LVDS                    */
+#define NCC_ACTTERM1	0x20	/* Enable active terminator 1     */
+#define NCC_ACTTERM2	0x40	/* Enable active terminator 2     */
+#define NCC_AUTOTERM	0x80	/* Enable auto termination        */
+
+/* Bit definition for nvram->TargetxConfig                              */
+#define	NTC_PERIOD	0x07	/* Maximum Sync. Speed            */
+#define NTC_1GIGA	0x08	/* 255 head / 63 sectors (64/32) */
+#define NTC_NO_SYNC	0x10	/* NO SYNC. NEGO          */
+#define NTC_NO_WIDESYNC	0x20	/* NO WIDE SYNC. NEGO             */
+#define	NTC_DISC_ENABLE	0x40	/* Enable SCSI disconnect */
+#define NTC_SPINUP	0x80	/* Start disk drive               */
+
+/* Default NVRam values                                                 */
+#define NBC_DEFAULT	(NBC_ENABLE)
+#define NCC_DEFAULT	(NCC_BUSRESET | NCC_AUTOTERM | NCC_PARITYCHK)
+#define NCC_MAX_TAGS	0x20	/* Maximum tags per target        */
+#define	NCC_RESET_TIME	0x0A	/* SCSI RESET recovering time     */
+#define NTC_DEFAULT	(NTC_1GIGA | NTC_NO_WIDESYNC | NTC_DISC_ENABLE)
+
+typedef union {			/* Union define for mechanism 1   */
+	struct {
+		unsigned char RegNum;
+		unsigned char FcnNum:3;
+		unsigned char DeviceNum:5;
+		unsigned char BusNum;
+		unsigned char Reserved:7;
+		unsigned char Enable:1;
+	} sConfigAdr;
+	unsigned long lConfigAdr;
+} CONFIG_ADR;
+
+typedef union {			/* Union define for mechanism 2   */
+	struct {
+		unsigned char RegNum;
+		unsigned char DeviceNum;
+		unsigned short Reserved;
+	} sHostAdr;
+	unsigned long lHostAdr;
+} HOST_ADR;
+
+#define ORC_RD(x,y)             (UCHAR)(inb(  (int)((ULONG)((ULONG)x+(UCHAR)y)) ))
+#define ORC_RDLONG(x,y)         (long)(inl((int)((ULONG)((ULONG)x+(UCHAR)y)) ))
+
+#define ORC_WR(     adr,data)   outb( (UCHAR)(data), (int)(adr))
+#define ORC_WRSHORT(adr,data)   outw( (UWORD)(data), (int)(adr))
+#define ORC_WRLONG( adr,data)   outl( (ULONG)(data), (int)(adr))
+
+
+#define SCSI_ABORT_SNOOZE 0
+#define SCSI_ABORT_SUCCESS 1
+#define SCSI_ABORT_PENDING 2
+#define SCSI_ABORT_BUSY 3
+#define SCSI_ABORT_NOT_RUNNING 4
+#define SCSI_ABORT_ERROR 5
+
+#define SCSI_RESET_SNOOZE 0
+#define SCSI_RESET_PUNT 1
+#define SCSI_RESET_SUCCESS 2
+#define SCSI_RESET_PENDING 3
+#define SCSI_RESET_WAKEUP 4
+#define SCSI_RESET_NOT_RUNNING 5
+#define SCSI_RESET_ERROR 6
+
+#define SCSI_RESET_SYNCHRONOUS		0x01
+#define SCSI_RESET_ASYNCHRONOUS		0x02
+#define SCSI_RESET_SUGGEST_BUS_RESET	0x04
+#define SCSI_RESET_SUGGEST_HOST_RESET	0x08
+
+#define SCSI_RESET_BUS_RESET 0x100
+#define SCSI_RESET_HOST_RESET 0x200
+#define SCSI_RESET_ACTION   0xff
diff -urN linux-2.0.37-pre6/drivers/scsi/i91uscsi.c linux-2.0.37-pre7/drivers/scsi/i91uscsi.c
--- linux-2.0.37-pre6/drivers/scsi/i91uscsi.c	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/drivers/scsi/i91uscsi.c	2003-08-15 15:04:36.000000000 -0700
@@ -71,6 +71,7 @@
 	12/13/98 bv, Use spinlocks instead of cli() for serialized
 		     access to HCS_Semaph, HCS_FirstAvail and HCS_LastAvail
 		     members of the HCS structure.
+	01/09/98 bv, Fix a deadlock on SMP system.
 **********************************************************************/
 
 #define DEBUG_INTERRUPT 0
@@ -89,7 +90,9 @@
 
 #include <linux/sched.h>
 #include <linux/delay.h>
+#include <linux/blk.h>
 #include <asm/io.h>
+
 #include "i91uscsi.h"
 
 /*--- external functions --*/
@@ -219,18 +222,7 @@
 	unsigned long the_time = jiffies + amount;	/* 0.01 seconds per jiffy */
 
 #if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
-	/*
-	 * We need to release the io_request_lock 
-	 * to make sure that the jiffies are updated
-	 */
-	spin_unlock_irq(&io_request_lock);
-
 	while (time_before_eq(jiffies, the_time));
-
-	/*
-	 * Acquire the io_request_lock again
-	 */
-	spin_lock_irq(&io_request_lock);
 #else
 	while (jiffies < the_time);
 #endif
@@ -518,10 +510,10 @@
 		if (i91u_adpt[i].ADPT_BIOS < wBIOS)
 			continue;
 		if (i91u_adpt[i].ADPT_BIOS == wBIOS) {
-			if (i91u_adpt[i].ADPT_BASE == wBASE)
+			if (i91u_adpt[i].ADPT_BASE == wBASE) {
 				if (i91u_adpt[i].ADPT_Bus != 0xFF)
 					return (FAILURE);
-				else if (i91u_adpt[i].ADPT_BASE < wBASE)
+			} else if (i91u_adpt[i].ADPT_BASE < wBASE)
 					continue;
 		}
 		for (j = MAX_SUPPORTED_ADAPTERS - 1; j > i; j--) {
@@ -1035,8 +1027,17 @@
 	if ((pCurHcb->HCS_Semaph == 0) && (pCurHcb->HCS_ActScb == NULL)) {
 		TUL_WR(pCurHcb->HCS_Base + TUL_Mask, 0x1F);
 		/* disable Jasmin SCSI Int        */
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+                spin_unlock_irqrestore(&(pCurHcb->HCS_SemaphLock), flags);
+#endif
+
 		tulip_main(pCurHcb);
 
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+        	spin_lock_irqsave(&(pCurHcb->HCS_SemaphLock), flags);
+#endif
+
 		pCurHcb->HCS_Semaph = 1;
 		TUL_WR(pCurHcb->HCS_Base + TUL_Mask, 0x0F);
 
@@ -1174,8 +1175,17 @@
 		if ((pCurHcb->HCS_Semaph == 0) && (pCurHcb->HCS_ActScb == NULL)) {
 			TUL_WR(pCurHcb->HCS_Base + TUL_Mask, 0x1F);
 			/* disable Jasmin SCSI Int        */
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+        		spin_unlock_irqrestore(&(pCurHcb->HCS_SemaphLock), flags);
+#endif
+
 			tulip_main(pCurHcb);
 
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+        		spin_lock_irqsave(&(pCurHcb->HCS_SemaphLock), flags);
+#endif
+
 			pCurHcb->HCS_Semaph = 1;
 			TUL_WR(pCurHcb->HCS_Base + TUL_Mask, 0x0F);
 
@@ -1228,8 +1238,16 @@
 		/* disable Jasmin SCSI Int        */
 		pCurHcb->HCS_Semaph = 0;
 
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+        	spin_unlock_irqrestore(&(pCurHcb->HCS_SemaphLock), flags);
+#endif
+
 		tulip_main(pCurHcb);
 
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+                spin_lock_irqsave(&(pCurHcb->HCS_SemaphLock), flags);
+#endif
+
 		pCurHcb->HCS_Semaph = 1;
 		TUL_WR(pCurHcb->HCS_Base + TUL_Mask, 0x0F);
 	}
@@ -1272,8 +1290,16 @@
 #endif
 	tul_post_scsi_rst(pCurHcb);
 
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+        spin_unlock_irqrestore(&(pCurHcb->HCS_SemaphLock), flags);
+#endif
+
 	tulip_main(pCurHcb);
 
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+        spin_lock_irqsave(&(pCurHcb->HCS_SemaphLock), flags);
+#endif
+
 	pCurHcb->HCS_Semaph = 1;
 	TUL_WR(pCurHcb->HCS_Base + TUL_Mask, 0x0F);
 #if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
@@ -1295,7 +1321,7 @@
 	pCurScb->SCB_SGMax = pCurScb->SCB_SGLen;
 
 #if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
-	spin_lock_irqsave(&(pCurScb->HCS_SemaphLock), flags);
+	spin_lock_irqsave(&(pCurHcb->HCS_SemaphLock), flags);
 #else
 	save_flags(flags);
 	cli();
@@ -1309,8 +1335,16 @@
 		/* disable Jasmin SCSI Int        */
 		pCurHcb->HCS_Semaph = 0;
 
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+        	spin_unlock_irqrestore(&(pCurHcb->HCS_SemaphLock), flags);
+#endif
+
 		tulip_main(pCurHcb);
 
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+        	spin_lock_irqsave(&(pCurHcb->HCS_SemaphLock), flags);
+#endif
+
 		pCurHcb->HCS_Semaph = 1;
 		TUL_WR(pCurHcb->HCS_Base + TUL_Mask, 0x0F);
 	}
diff -urN linux-2.0.37-pre6/drivers/scsi/i91uscsi.h linux-2.0.37-pre7/drivers/scsi/i91uscsi.h
--- linux-2.0.37-pre6/drivers/scsi/i91uscsi.h	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/drivers/scsi/i91uscsi.h	2003-08-15 15:04:36.000000000 -0700
@@ -53,6 +53,8 @@
  *
  **************************************************************************/
 
+#include <linux/config.h>
+
 #define ULONG   unsigned long
 #define USHORT  unsigned short
 #define UCHAR   unsigned char
diff -urN linux-2.0.37-pre6/drivers/scsi/ini9100u.c linux-2.0.37-pre7/drivers/scsi/ini9100u.c
--- linux-2.0.37-pre6/drivers/scsi/ini9100u.c	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/drivers/scsi/ini9100u.c	2003-08-15 15:04:36.000000000 -0700
@@ -99,6 +99,9 @@
  *		- Add support for the Domex 3192U PCI SCSI
  *		  This is a slightly modified patch by
  *		  Brian Macy <bmacy@sunshinecomputing.com>
+ * 22/02/99 bv	- v1.03f
+ *		- Didn't detect the INIC-950 in 2.0.x correctly.
+ *		  Now fixed.
  **************************************************************************/
 
 #define CVT_LINUX_VERSION(V,P,S)        (V * 65536 + P * 256 + S)
@@ -179,7 +182,7 @@
 char *i91uCopyright = "Copyright (C) 1996-98";
 char *i91uInitioName = "by Initio Corporation";
 char *i91uProductName = "INI-9X00U/UW";
-char *i91uVersion = "v1.03e";
+char *i91uVersion = "v1.03f";
 
 #if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
 struct proc_dir_entry proc_scsi_ini9100u =
@@ -402,57 +405,25 @@
 		unsigned long page_offset, base;
 #endif
 
-#if LINUX_VERSION_CODE > CVT_LINUX_VERSION(2,1,92)
-		struct pci_dev *pdev = NULL;
-#else
 		int index;
 		unsigned char pci_bus, pci_devfn;
-#endif
 
 		bPCIBusNum = 0;
 		bPCIDeviceNum = 0;
 		init_i91uAdapter_table();
 		for (i = 0; i < TULSZ(i91u_pci_devices); i++) {
-#if LINUX_VERSION_CODE > CVT_LINUX_VERSION(2,1,92)
-			pdev = NULL;
-			while ((pdev = pci_find_device(i91u_pci_devices[i].vendor_id,
-					   i91u_pci_devices[i].device_id,
-						       pdev)))
-#else
 			index = 0;
 			while (!(pcibios_find_device(i91u_pci_devices[i].vendor_id,
 					   i91u_pci_devices[i].device_id,
 					 index++, &pci_bus, &pci_devfn)))
-#endif
 			{
-				if (i == 0) {
-					/*
+				if (i == 2) {
 					   printk("i91u: The RAID controller is not supported by\n");
 					   printk("i91u:         this driver, we are ignoring it.\n");
-					 */
 				} else {
 					/*
 					 * Read sundry information from PCI BIOS.
 					 */
-#if LINUX_VERSION_CODE > CVT_LINUX_VERSION(2,1,92)
-					bPCIBusNum = pdev->bus->number;
-					bPCIDeviceNum = pdev->devfn;
-					dRegValue = pdev->base_address[0];
-					if (dRegValue == -1) {	/* Check return code            */
-						printk("\n\ri91u: tulip read configuration error.\n");
-						return (0);	/* Read configuration space error  */
-					}
-					/* <02> read from base address + 0x50 offset to get the wBIOS balue. */
-					wBASE = (WORD) dRegValue;
-
-					/* Now read the interrupt line  */
-					dRegValue = pdev->irq;
-					bInterrupt = dRegValue & 0xFF;	/* Assign interrupt line      */
-					pci_read_config_word(pdev, PCI_COMMAND, &command);
-					pci_write_config_word(pdev, PCI_COMMAND,
-							      command | PCI_COMMAND_MASTER | PCI_COMMAND_IO);
-
-#else
 					bPCIBusNum = pci_bus;
 					bPCIDeviceNum = pci_devfn;
 					pcibios_read_config_dword(pci_bus, pci_devfn, PCI_BASE_ADDRESS_0,
@@ -471,7 +442,6 @@
 					pcibios_read_config_word(pci_bus, pci_devfn, PCI_COMMAND, &command);
 					pcibios_write_config_word(pci_bus, pci_devfn, PCI_COMMAND,
 								  command | PCI_COMMAND_MASTER | PCI_COMMAND_IO);
-#endif
 					wBASE &= PCI_BASE_ADDRESS_IO_MASK;
 					wBIOS = TUL_RDWORD(wBASE, 0x50);
 
diff -urN linux-2.0.37-pre6/drivers/scsi/ini9100u.h linux-2.0.37-pre7/drivers/scsi/ini9100u.h
--- linux-2.0.37-pre6/drivers/scsi/ini9100u.h	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/drivers/scsi/ini9100u.h	2003-08-15 15:04:36.000000000 -0700
@@ -90,7 +90,7 @@
 extern int i91u_biosparam(Disk *, int, int *);	/*for linux v1.13 */
 #endif
 
-#define i91u_REVID "Initio INI-9X00U/UW SCSI device driver; Revision: 1.03e"
+#define i91u_REVID "Initio INI-9X00U/UW SCSI device driver; Revision: 1.03f"
 
 #if LINUX_VERSION_CODE < CVT_LINUX_VERSION(1, 3, 0)
 #define INI9100U	{ \
diff -urN linux-2.0.37-pre6/drivers/scsi/inia100.c linux-2.0.37-pre7/drivers/scsi/inia100.c
--- linux-2.0.37-pre6/drivers/scsi/inia100.c	1969-12-31 16:00:00.000000000 -0800
+++ linux-2.0.37-pre7/drivers/scsi/inia100.c	2003-08-15 15:04:36.000000000 -0700
@@ -0,0 +1,953 @@
+/**************************************************************************
+ * Initio A100 device driver for Linux.
+ *
+ * Copyright (c) 1994-1998 Initio Corporation
+ * All rights reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2, or (at your option)
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; see the file COPYING.  If not, write to
+ * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+ *
+ * --------------------------------------------------------------------------
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions, and the following disclaimer,
+ *    without modification, immediately at the beginning of the file.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ * 3. The name of the author may not be used to endorse or promote products
+ *    derived from this software without specific prior written permission.
+ *
+ * Where this Software is combined with software released under the terms of 
+ * the GNU Public License ("GPL") and the terms of the GPL would require the 
+ * combined work to also be released under the terms of the GPL, the terms
+ * and conditions of this License will apply in addition to those of the
+ * GPL with the exception of any terms or conditions of this License that
+ * conflict with, or are expressly prohibited by, the GPL.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR
+ * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ **************************************************************************
+ * 
+ * module: inia100.c
+ * DESCRIPTION:
+ * 	This is the Linux low-level SCSI driver for Initio INIA100 SCSI host
+ * 	adapters
+ * 09/24/98 hl - v1.02 initial production release.
+ * 12/19/98 bv - v1.02a Use spinlocks for 2.1.95 and up.
+ **************************************************************************/
+
+#define CVT_LINUX_VERSION(V,P,S)        (V * 65536 + P * 256 + S)
+
+#ifndef LINUX_VERSION_CODE
+#include <linux/version.h>
+#endif
+
+#ifdef MODULE
+#include <linux/module.h>
+#endif
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+#include <stdarg.h>
+#include <asm/io.h>
+#include <asm/irq.h>
+#include <linux/string.h>
+#include <linux/errno.h>
+#include <linux/kernel.h>
+#include <linux/ioport.h>
+#include <linux/delay.h>
+#include <linux/sched.h>
+#if LINUX_VERSION_CODE <= CVT_LINUX_VERSION(2,1,92)
+#include <linux/bios32.h>
+#endif
+#include <linux/pci.h>
+#include <linux/proc_fs.h>
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,23)
+#include <linux/init.h>
+#endif
+#include <linux/blk.h>
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+#include <asm/spinlock.h>
+#endif
+#include "sd.h"
+#include "scsi.h"
+#include "hosts.h"
+#include "inia100.h"
+#include <linux/stat.h>
+#include <linux/malloc.h>
+#include <linux/config.h>
+
+
+#else
+
+#include <linux/kernel.h>
+#include <linux/head.h>
+#include <linux/types.h>
+#include <linux/string.h>
+#include <linux/ioport.h>
+
+#include <linux/sched.h>
+#include <linux/proc_fs.h>
+#include <asm/system.h>
+#include <asm/io.h>
+#include "../block/blk.h"
+#include "scsi.h"
+#include "sd.h"
+#include "hosts.h"
+#include <linux/malloc.h>
+#include "inia100.h"
+#endif
+
+#ifdef MODULE
+Scsi_Host_Template driver_template = INIA100;
+#include "scsi_module.c"
+#endif
+
+#define ORC_RDWORD(x,y)         (short)(inl((int)((ULONG)((ULONG)x+(UCHAR)y)) ))
+
+char *inia100_Copyright = "Copyright (C) 1998-99";
+char *inia100_InitioName = "by Initio Corporation";
+char *inia100_ProductName = "INI-A100U2W";
+char *inia100_Version = "v1.02a";
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+struct proc_dir_entry proc_scsi_inia100 =
+{
+	PROC_SCSI_INIA100, 7, "INIA100",
+	S_IFDIR | S_IRUGO | S_IXUGO, 2,
+	0, 0, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL
+};
+#endif
+
+/* set by inia100_setup according to the command line */
+static int setup_called = 0;
+static int orc_num_ch = MAX_SUPPORTED_ADAPTERS;		/* Maximum 4 adapters           */
+
+/* ---- INTERNAL VARIABLES ---- */
+#define NUMBER(arr)     (sizeof(arr) / sizeof(arr[0]))
+static char *setup_str = (char *) NULL;
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+static void inia100_intr0(int irq, void *dev_id, struct pt_regs *);
+static void inia100_intr1(int irq, void *dev_id, struct pt_regs *);
+static void inia100_intr2(int irq, void *dev_id, struct pt_regs *);
+static void inia100_intr3(int irq, void *dev_id, struct pt_regs *);
+static void inia100_intr4(int irq, void *dev_id, struct pt_regs *);
+static void inia100_intr5(int irq, void *dev_id, struct pt_regs *);
+static void inia100_intr6(int irq, void *dev_id, struct pt_regs *);
+static void inia100_intr7(int irq, void *dev_id, struct pt_regs *);
+#else
+static void inia100_intr0(int irq, struct pt_regs *);
+static void inia100_intr1(int irq, struct pt_regs *);
+static void inia100_intr2(int irq, struct pt_regs *);
+static void inia100_intr3(int irq, struct pt_regs *);
+static void inia100_intr4(int irq, struct pt_regs *);
+static void inia100_intr5(int irq, struct pt_regs *);
+static void inia100_intr6(int irq, struct pt_regs *);
+static void inia100_intr7(int irq, struct pt_regs *);
+#endif
+
+static void inia100_panic(char *msg);
+void inia100SCBPost(BYTE * pHcb, BYTE * pScb);
+
+/* ---- EXTERNAL VARIABLES ---- */
+extern int Addinia100_into_Adapter_table(WORD, WORD, BYTE, BYTE, BYTE);
+extern void init_inia100Adapter_table(void);
+extern ORC_SCB *orc_alloc_scb(ORC_HCS * hcsp);
+extern void orc_exec_scb(ORC_HCS * hcsp, ORC_SCB * scbp);
+extern void orc_release_scb(ORC_HCS * hcsp, ORC_SCB * scbp);
+extern void orc_interrupt(ORC_HCS * hcsp);
+extern int orc_device_reset(ORC_HCS * pHCB, ULONG SCpnt, unsigned int target, unsigned int ResetFlags);
+extern int orc_reset_scsi_bus(ORC_HCS * pHCB);
+extern int abort_SCB(ORC_HCS * hcsp, ORC_SCB * pScb);
+extern int orc_abort_srb(ORC_HCS * hcsp, ULONG SCpnt);
+extern void get_orcPCIConfig(ORC_HCS * pCurHcb, int ch_idx);
+extern int init_orchid(ORC_HCS * hcsp);
+
+extern int orc_num_scb;
+extern ORC_HCS orc_hcs[];
+
+/*****************************************************************************
+ Function name  : inia100AppendSRBToQueue
+ Description    : This function will push current request into save list
+ Input          : pSRB  -       Pointer to SCSI request block.
+		  pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : None.
+*****************************************************************************/
+static void inia100AppendSRBToQueue(ORC_HCS * pHCB, Scsi_Cmnd * pSRB)
+{
+	ULONG flags;
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+	spin_lock_irqsave(&(pHCB->pSRB_lock), flags);
+#else
+	save_flags(flags);
+	cli();
+#endif
+
+	pSRB->next = NULL;	/* Pointer to next */
+	if (pHCB->pSRB_head == NULL)
+		pHCB->pSRB_head = pSRB;
+	else
+		pHCB->pSRB_tail->next = pSRB;	/* Pointer to next */
+	pHCB->pSRB_tail = pSRB;
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+	spin_unlock_irqrestore(&(pHCB->pSRB_lock), flags);
+#else
+	restore_flags(flags);
+#endif
+	return;
+}
+
+/*****************************************************************************
+ Function name  : inia100PopSRBFromQueue
+ Description    : This function will pop current request from save list
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+static Scsi_Cmnd *inia100PopSRBFromQueue(ORC_HCS * pHCB)
+{
+	Scsi_Cmnd *pSRB;
+	ULONG flags;
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+	spin_lock_irqsave(&(pHCB->pSRB_lock), flags);
+#else
+	save_flags(flags);
+	cli();
+#endif
+
+	if ((pSRB = (Scsi_Cmnd *) pHCB->pSRB_head) != NULL) {
+		pHCB->pSRB_head = pHCB->pSRB_head->next;
+		pSRB->next = NULL;
+	}
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+	spin_unlock_irqrestore(&(pHCB->pSRB_lock), flags);
+#else
+	restore_flags(flags);
+#endif
+	return (pSRB);
+}
+
+/*****************************************************************************
+ Function name  : inia100_setup
+ Description    : 
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+void inia100_setup(char *str, int *ints)
+{
+	if (setup_called)
+		inia100_panic("inia100: inia100_setup called twice.\n");
+
+	setup_called = ints[0];
+	setup_str = str;
+}
+
+/*****************************************************************************
+ Function name	: orc_ReturnNumberOfAdapters
+ Description	: This function will scan PCI bus to get all Orchid card
+ Input		: None.
+ Output		: None.
+ Return		: SUCCESSFUL	- Successful scan
+		  ohterwise	- No drives founded
+*****************************************************************************/
+int orc_ReturnNumberOfAdapters(void)
+{
+	unsigned int i, iAdapters;
+
+	iAdapters = 0;
+	/*
+	 * PCI-bus probe.
+	 */
+	if (pcibios_present()) {
+		struct {
+			unsigned short vendor_id;
+			unsigned short device_id;
+		} const inia100_pci_devices[] =
+		{
+			{ORC_VENDOR_ID, I920_DEVICE_ID},
+			{ORC_VENDOR_ID, ORC_DEVICE_ID}
+		};
+
+		unsigned int dRegValue;
+		unsigned short command;
+		WORD wBIOS, wBASE;
+		BYTE bPCIBusNum, bInterrupt, bPCIDeviceNum;
+
+#ifdef MMAPIO
+		unsigned long page_offset, base;
+#endif
+
+#if LINUX_VERSION_CODE > CVT_LINUX_VERSION(2,1,92)
+		struct pci_dev *pdev = NULL;
+#else
+		int index;
+		unsigned char pci_bus, pci_devfn;
+#endif
+
+		bPCIBusNum = 0;
+		bPCIDeviceNum = 0;
+		init_inia100Adapter_table();
+		for (i = 0; i < NUMBER(inia100_pci_devices); i++) {
+#if LINUX_VERSION_CODE > CVT_LINUX_VERSION(2,1,92)
+			pdev = NULL;
+			while ((pdev = pci_find_device(inia100_pci_devices[i].vendor_id,
+					inia100_pci_devices[i].device_id,
+						       pdev)))
+#else
+			index = 0;
+			while (!(pcibios_find_device(inia100_pci_devices[i].vendor_id,
+					inia100_pci_devices[i].device_id,
+					 index++, &pci_bus, &pci_devfn)))
+#endif
+			{
+				if (iAdapters >= MAX_SUPPORTED_ADAPTERS)
+					break;	/* Never greater than maximum   */
+
+				if (i == 0) {
+					/*
+					   printk("inia100: The RAID controller is not supported by\n");
+					   printk("inia100:         this driver, we are ignoring it.\n");
+					 */
+				} else {
+					/*
+					 * Read sundry information from PCI BIOS.
+					 */
+#if LINUX_VERSION_CODE > CVT_LINUX_VERSION(2,1,92)
+					bPCIBusNum = pdev->bus->number;
+					bPCIDeviceNum = pdev->devfn;
+					dRegValue = pdev->base_address[0];
+					if (dRegValue == -1) {	/* Check return code            */
+						printk("\n\rinia100: orchid read configuration error.\n");
+						return (0);	/* Read configuration space error  */
+					}
+					/* <02> read from base address + 0x50 offset to get the wBIOS balue. */
+					wBASE = (WORD) dRegValue;
+
+					/* Now read the interrupt line  */
+					dRegValue = pdev->irq;
+					bInterrupt = dRegValue & 0xFF;	/* Assign interrupt line      */
+					pci_read_config_word(pdev, PCI_COMMAND, &command);
+					pci_write_config_word(pdev, PCI_COMMAND,
+							      command | PCI_COMMAND_MASTER | PCI_COMMAND_IO);
+
+#else
+					bPCIBusNum = pci_bus;
+					bPCIDeviceNum = pci_devfn;
+					pcibios_read_config_dword(pci_bus, pci_devfn, PCI_BASE_ADDRESS_0,
+							     &dRegValue);
+					if (dRegValue == -1) {	/* Check return code            */
+						printk("\n\rinia100: Orchid read configuration error.\n");
+						return (0);	/* Read configuration space error  */
+					}
+					/* <02> read from base address + 0x50 offset to get the wBIOS balue. */
+					wBASE = (WORD) dRegValue;
+
+					/* Now read the interrupt line  */
+					pcibios_read_config_dword(pci_bus, pci_devfn, PCI_INTERRUPT_LINE,
+							     &dRegValue);
+					bInterrupt = dRegValue & 0xFF;	/* Assign interrupt line      */
+					pcibios_read_config_word(pci_bus, pci_devfn, PCI_COMMAND, &command);
+					pcibios_write_config_word(pci_bus, pci_devfn, PCI_COMMAND,
+								  command | PCI_COMMAND_MASTER | PCI_COMMAND_IO);
+#endif
+					wBASE &= PCI_BASE_ADDRESS_IO_MASK;
+					wBIOS = ORC_RDWORD(wBASE, 0x50);
+
+#ifdef MMAPIO
+					base = wBASE & PAGE_MASK;
+					page_offset = wBASE - base;
+
+					/*
+					 * replace the next line with this one if you are using 2.1.x:
+					 * temp_p->maddr = ioremap(base, page_offset + 256);
+					 */
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,0)
+					wBASE = ioremap(base, page_offset + 256);
+#else
+					wBASE = (WORD) vremap(base, page_offset + 256);
+#endif
+					if (wBASE) {
+						wBASE += page_offset;
+					}
+#endif
+
+					if (Addinia100_into_Adapter_table(wBIOS, wBASE, bInterrupt, bPCIBusNum,
+					    bPCIDeviceNum) == SUCCESSFUL)
+						iAdapters++;
+				}
+			}	/* while(pdev=....) */
+		}		/* for PCI_DEVICES */
+	}			/* PCI BIOS present */
+	return (iAdapters);
+}
+
+/*****************************************************************************
+ Function name  : inia100_detect
+ Description    : 
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+int inia100_detect(Scsi_Host_Template * tpnt)
+{
+	ORC_HCS *pHCB;
+	struct Scsi_Host *hreg;
+	U32 sz;
+	U32 i;			/* 01/14/98                     */
+	int ok = 0, iAdapters;
+	ULONG dBiosAdr;
+	BYTE *pbBiosAdr;
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+	tpnt->proc_dir = &proc_scsi_inia100;
+#endif
+	if (setup_called) {
+		/* Setup by inia100_setup          */
+		printk("inia100: processing commandline: ");
+	}
+	/* Get total number of adapters in the motherboard */
+	iAdapters = orc_ReturnNumberOfAdapters();
+
+	/* printk("inia100: Total Initio Adapters = %d\n", iAdapters); */
+	if (iAdapters == 0)	/* If no orc founded, return */
+		return (0);
+
+	orc_num_ch = (iAdapters > orc_num_ch) ? orc_num_ch : iAdapters;
+	orc_num_scb = ORC_MAXQUEUE;
+
+	/* clear the memory needed for HCS */
+	i = orc_num_ch * sizeof(ORC_HCS);
+	memset((unsigned char *) &orc_hcs[0], 0, i);	/* Initialize orc_hcs 0   */
+
+#if 0
+	printk("orc_num_scb= %x orc_num_ch= %x hcsize= %x scbsize= %x escbsize= %x\n",
+	       orc_num_scb, orc_num_ch, sizeof(ORC_HCS), sizeof(ORC_SCB), sizeof(ESCB));
+#endif
+
+	for (i = 0, pHCB = &orc_hcs[0];		/* Get pointer for control block */
+	     i < orc_num_ch;
+	     i++, pHCB++) {
+
+		pHCB->pSRB_head = NULL;		/* Initial SRB save queue       */
+		pHCB->pSRB_tail = NULL;		/* Initial SRB save queue       */
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+		pHCB->pSRB_lock = SPIN_LOCK_UNLOCKED; /* SRB save queue lock */
+#endif
+		/* Get total memory needed for SCB */
+		sz = orc_num_scb * sizeof(ORC_SCB);
+		if ((pHCB->HCS_virScbArray = (PVOID) kmalloc(sz, GFP_ATOMIC | GFP_DMA)) == NULL) {
+			printk("inia100: SCB memory allocation error\n");
+			return (0);
+		}
+		memset((unsigned char *) pHCB->HCS_virScbArray, 0, sz);
+		pHCB->HCS_physScbArray = (U32) VIRT_TO_BUS(pHCB->HCS_virScbArray);
+
+		/* Get total memory needed for ESCB */
+		sz = orc_num_scb * sizeof(ESCB);
+		if ((pHCB->HCS_virEscbArray = (PVOID) kmalloc(sz, GFP_ATOMIC | GFP_DMA)) == NULL) {
+			printk("inia100: ESCB memory allocation error\n");
+			return (0);
+		}
+		memset((unsigned char *) pHCB->HCS_virEscbArray, 0, sz);
+		pHCB->HCS_physEscbArray = (U32) VIRT_TO_BUS(pHCB->HCS_virEscbArray);
+
+		request_region(pHCB->HCS_Base, 0x100, "inia100");	/* Register */
+		get_orcPCIConfig(pHCB, i);
+
+		dBiosAdr = pHCB->HCS_BIOS;
+		dBiosAdr = (dBiosAdr << 4);
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+		pbBiosAdr = phys_to_virt(dBiosAdr);
+#endif
+
+		if (init_orchid(pHCB)) {	/* Initial orchid chip    */
+			printk("inia100: initial orchid fail!!\n");
+			return (0);
+		}
+		hreg = scsi_register(tpnt, sizeof(ORC_HCS));
+		if (hreg == NULL) {
+			printk("Invalid scsi_register pointer.\n");
+		}
+		hreg->io_port = pHCB->HCS_Base;
+		hreg->n_io_port = 0xff;
+		hreg->can_queue = orc_num_scb;	/* 03/05/98                   */
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+		hreg->unique_id = pHCB->HCS_Base;
+		hreg->max_id = pHCB->HCS_MaxTar;
+#endif
+
+		hreg->max_lun = 32;	/* 10/21/97                     */
+/*
+   hreg->max_lun = 8;
+   hreg->max_channel = 1;
+ */
+		hreg->irq = pHCB->HCS_Intr;
+		hreg->this_id = pHCB->HCS_SCSI_ID;	/* Assign HCS index           */
+		hreg->base = (UCHAR *) pHCB;
+
+#if 1
+		hreg->sg_tablesize = TOTAL_SG_ENTRY;	/* Maximun support is 32 */
+#else
+		hreg->sg_tablesize = SG_NONE;	/* No SG                        */
+#endif
+
+		/* Initial orc chip           */
+		switch (i) {
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+		case 0:
+			ok = request_irq(pHCB->HCS_Intr, inia100_intr0, SA_INTERRUPT | SA_SHIRQ, "inia100", NULL);
+			break;
+		case 1:
+			ok = request_irq(pHCB->HCS_Intr, inia100_intr1, SA_INTERRUPT | SA_SHIRQ, "inia100", NULL);
+			break;
+		case 2:
+			ok = request_irq(pHCB->HCS_Intr, inia100_intr2, SA_INTERRUPT | SA_SHIRQ, "inia100", NULL);
+			break;
+		case 3:
+			ok = request_irq(pHCB->HCS_Intr, inia100_intr3, SA_INTERRUPT | SA_SHIRQ, "inia100", NULL);
+			break;
+		case 4:
+			ok = request_irq(pHCB->HCS_Intr, inia100_intr4, SA_INTERRUPT | SA_SHIRQ, "inia100", NULL);
+			break;
+		case 5:
+			ok = request_irq(pHCB->HCS_Intr, inia100_intr5, SA_INTERRUPT | SA_SHIRQ, "inia100", NULL);
+			break;
+		case 6:
+			ok = request_irq(pHCB->HCS_Intr, inia100_intr6, SA_INTERRUPT | SA_SHIRQ, "inia100", NULL);
+			break;
+		case 7:
+			ok = request_irq(pHCB->HCS_Intr, inia100_intr7, SA_INTERRUPT | SA_SHIRQ, "inia100", NULL);
+			break;
+		default:
+			inia100_panic("inia100: Too many host adapters\n");
+			break;
+		}
+
+		if (ok < 0) {
+			if (ok == -EINVAL) {
+				printk("inia100: bad IRQ %d.\n", pHCB->HCS_Intr);
+				printk("         Contact author.\n");
+			} else {
+				if (ok == -EBUSY)
+					printk("inia100: IRQ %d already in use. Configure another.\n", pHCB->HCS_Intr);
+				else {
+					printk("\ninia100: Unexpected error code on requesting IRQ %d.\n",
+					       pHCB->HCS_Intr);
+					printk("         Contact author.\n");
+				}
+			}
+			inia100_panic("inia100: driver needs an IRQ.\n");
+		}
+#endif
+	}
+
+	tpnt->this_id = -1;
+	tpnt->can_queue = 1;
+	return 1;
+}
+
+/*****************************************************************************
+ Function name  : inia100BuildSCB
+ Description    : 
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+static void inia100BuildSCB(ORC_HCS * pHCB, ORC_SCB * pSCB, Scsi_Cmnd * SCpnt)
+{				/* Create corresponding SCB     */
+	struct scatterlist *pSrbSG;
+	ORC_SG *pSG;		/* Pointer to SG list           */
+	int i;
+	U32 TotalLen;
+	ESCB *pEScb;
+
+	pEScb = pSCB->SCB_EScb;
+	pEScb->SCB_Srb = SCpnt;
+	pSG = NULL;
+
+	pSCB->SCB_Opcode = ORC_EXECSCSI;
+	pSCB->SCB_Flags = SCF_NO_DCHK;	/* Clear done bit               */
+	pSCB->SCB_Target = SCpnt->target;
+	pSCB->SCB_Lun = SCpnt->lun;
+	pSCB->SCB_Reserved0 = 0;
+	pSCB->SCB_Reserved1 = 0;
+	pSCB->SCB_SGLen = 0;
+
+	if ((pSCB->SCB_XferLen = (U32) SCpnt->request_bufflen)) {
+		pSG = (ORC_SG *) & pEScb->ESCB_SGList[0];
+		if (SCpnt->use_sg) {
+			TotalLen = 0;
+			pSCB->SCB_SGLen = (U32) (SCpnt->use_sg * 8);
+			pSrbSG = (struct scatterlist *) SCpnt->request_buffer;
+			for (i = 0; i < SCpnt->use_sg; i++, pSG++, pSrbSG++) {
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+				pSG->SG_Ptr = (U32) (VIRT_TO_BUS(pSrbSG->address));
+#else
+				pSG->SG_Ptr = (U32) pSrbSG->address;
+#endif
+				pSG->SG_Len = (U32) pSrbSG->length;
+				TotalLen += (U32) pSrbSG->length;
+			}
+		} else {	/* Non SG                       */
+			pSCB->SCB_SGLen = 0x8;
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+			pSG->SG_Ptr = (U32) (VIRT_TO_BUS(SCpnt->request_buffer));
+#else
+			pSG->SG_PTR = (U32) SCpnt->request_buffer;
+#endif
+			pSG->SG_Len = (U32) SCpnt->request_bufflen;
+		}
+	}
+	pSCB->SCB_SGPAddr = (U32) pSCB->SCB_SensePAddr;
+	pSCB->SCB_HaStat = 0;
+	pSCB->SCB_TaStat = 0;
+	pSCB->SCB_Link = 0xFF;
+	pSCB->SCB_SenseLen = SENSE_SIZE;
+	pSCB->SCB_CDBLen = SCpnt->cmd_len;
+	if (pSCB->SCB_CDBLen >= IMAX_CDB) {
+		printk("max cdb length= %x\b", SCpnt->cmd_len);
+		pSCB->SCB_CDBLen = IMAX_CDB;
+	}
+	pSCB->SCB_Ident = SCpnt->lun | DISC_ALLOW;
+	if (SCpnt->device->tagged_supported) {	/* Tag Support                  */
+		pSCB->SCB_TagMsg = SIMPLE_QUEUE_TAG;	/* Do simple tag only   */
+	} else {
+		pSCB->SCB_TagMsg = 0;	/* No tag support               */
+	}
+	memcpy(&pSCB->SCB_CDB[0], &SCpnt->cmnd, pSCB->SCB_CDBLen);
+	return;
+}
+
+/*****************************************************************************
+ Function name  : inia100_queue
+ Description    : Queue a command and setup interrupts for a free bus.
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+int inia100_queue(Scsi_Cmnd * SCpnt, void (*done) (Scsi_Cmnd *))
+{
+	register ORC_SCB *pSCB;
+	ORC_HCS *pHCB;		/* Point to Host adapter control block */
+
+	if (SCpnt->lun > 16) {
+		SCpnt->result = (DID_TIME_OUT << 16);
+		done(SCpnt);	/* Notify system DONE           */
+		return (0);
+	}
+	pHCB = (ORC_HCS *) SCpnt->host->base;
+	SCpnt->scsi_done = done;
+	/* Get free SCSI control block  */
+	if ((pSCB = orc_alloc_scb(pHCB)) == NULL) {
+		inia100AppendSRBToQueue(pHCB, SCpnt);	/* Buffer this request  */
+		/* printk("inia100_entry: can't allocate SCB\n"); */
+		return (0);
+	}
+	inia100BuildSCB(pHCB, pSCB, SCpnt);
+	orc_exec_scb(pHCB, pSCB);	/* Start execute SCB            */
+
+	return (0);
+}
+
+/*****************************************************************************
+ Function name  : inia100_command
+ Description    : We only support command in interrupt-driven fashion
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+int inia100_command(Scsi_Cmnd * SCpnt)
+{
+	printk("inia100: interrupt driven driver; use inia100_queue()\n");
+	return -1;
+}
+
+/*****************************************************************************
+ Function name  : inia100_abort
+ Description    : Abort a queued command.
+	                 (commands that are on the bus can't be aborted easily)
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+int inia100_abort(Scsi_Cmnd * SCpnt)
+{
+	ORC_HCS *hcsp;
+
+	hcsp = (ORC_HCS *) SCpnt->host->base;
+	return orc_abort_srb(hcsp, (ULONG) SCpnt);
+}
+
+/*****************************************************************************
+ Function name  : inia100_reset
+ Description    : Reset registers, reset a hanging bus and
+                  kill active and disconnected commands for target w/o soft reset
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+int inia100_reset(Scsi_Cmnd * SCpnt, unsigned int reset_flags)
+{				/* I need Host Control Block Information */
+	ORC_HCS *pHCB;
+	pHCB = (ORC_HCS *) SCpnt->host->base;
+
+	if (reset_flags & (SCSI_RESET_SUGGEST_BUS_RESET | SCSI_RESET_SUGGEST_HOST_RESET))
+		return orc_reset_scsi_bus(pHCB);
+	else
+		return orc_device_reset(pHCB, (ULONG) SCpnt, SCpnt->target, reset_flags);
+
+}
+
+/*****************************************************************************
+ Function name  : inia100SCBPost
+ Description    : This is callback routine be called when orc finish one
+			SCSI command.
+ Input          : pHCB  -       Pointer to host adapter control block.
+		  pSCB  -       Pointer to SCSI control block.
+ Output         : None.
+ Return         : None.
+*****************************************************************************/
+void inia100SCBPost(BYTE * pHcb, BYTE * pScb)
+{
+	Scsi_Cmnd *pSRB;	/* Pointer to SCSI request block */
+	ORC_HCS *pHCB;
+	ORC_SCB *pSCB;
+	ESCB *pEScb;
+
+	pHCB = (ORC_HCS *) pHcb;
+	pSCB = (ORC_SCB *) pScb;
+	pEScb = pSCB->SCB_EScb;
+	if ((pSRB = (Scsi_Cmnd *) pEScb->SCB_Srb) == 0) {
+		printk("inia100SCBPost: SRB pointer is empty\n");
+		orc_release_scb(pHCB, pSCB);	/* Release SCB for current channel */
+		return;
+	}
+	pEScb->SCB_Srb = NULL;
+
+	switch (pSCB->SCB_HaStat) {
+	case 0x0:
+	case 0xa:		/* Linked command complete without error and linked normally */
+	case 0xb:		/* Linked command complete without error interrupt generated */
+		pSCB->SCB_HaStat = 0;
+		break;
+
+	case 0x11:		/* Selection time out-The initiator selection or target
+				   reselection was not complete within the SCSI Time out period */
+		pSCB->SCB_HaStat = DID_TIME_OUT;
+		break;
+
+	case 0x14:		/* Target bus phase sequence failure-An invalid bus phase or bus
+				   phase sequence was requested by the target. The host adapter
+				   will generate a SCSI Reset Condition, notifying the host with
+				   a SCRD interrupt */
+		pSCB->SCB_HaStat = DID_RESET;
+		break;
+
+	case 0x1a:		/* SCB Aborted. 07/21/98 */
+		pSCB->SCB_HaStat = DID_ABORT;
+		break;
+
+	case 0x12:		/* Data overrun/underrun-The target attempted to transfer more data
+				   than was allocated by the Data Length field or the sum of the
+				   Scatter / Gather Data Length fields. */
+	case 0x13:		/* Unexpected bus free-The target dropped the SCSI BSY at an unexpected time. */
+	case 0x16:		/* Invalid CCB Operation Code-The first byte of the CCB was invalid. */
+
+	default:
+		printk("inia100: %x %x\n", pSCB->SCB_HaStat, pSCB->SCB_TaStat);
+		pSCB->SCB_HaStat = DID_ERROR;	/* Couldn't find any better */
+		break;
+	}
+
+	if (pSCB->SCB_TaStat == 2) {	/* Check condition              */
+		memcpy((unsigned char *) &pSRB->sense_buffer[0],
+		   (unsigned char *) &pEScb->ESCB_SGList[0], SENSE_SIZE);
+	}
+	pSRB->result = pSCB->SCB_TaStat | (pSCB->SCB_HaStat << 16);
+	pSRB->scsi_done(pSRB);	/* Notify system DONE           */
+
+	/* Find the next pending SRB    */
+	if ((pSRB = inia100PopSRBFromQueue(pHCB)) != NULL) {	/* Assume resend will success   */
+		/* Reuse old SCB                */
+		inia100BuildSCB(pHCB, pSCB, pSRB);	/* Create corresponding SCB     */
+		orc_exec_scb(pHCB, pSCB);	/* Start execute SCB            */
+	} else {		/* No Pending SRB               */
+		orc_release_scb(pHCB, pSCB);	/* Release SCB for current channel */
+	}
+	return;
+}
+
+/*****************************************************************************
+ Function name  : inia100_biosparam
+ Description    : Return the "logical geometry"
+ Input          : pHCB  -       Pointer to host adapter structure
+ Output         : None.
+ Return         : pSRB  -       Pointer to SCSI request block.
+*****************************************************************************/
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+int inia100_biosparam(Scsi_Disk * disk, kdev_t dev, int *info_array)
+#else
+int inia100_biosparam(Scsi_Disk * disk, int dev, int *info_array)
+#endif
+{
+	ORC_HCS *pHcb;		/* Point to Host adapter control block */
+	ORC_TCS *pTcb;
+
+	pHcb = (ORC_HCS *) disk->device->host->base;
+	pTcb = &pHcb->HCS_Tcs[disk->device->id];
+
+	if (pTcb->TCS_DrvHead) {
+		info_array[0] = pTcb->TCS_DrvHead;
+		info_array[1] = pTcb->TCS_DrvSector;
+		info_array[2] = disk->capacity / pTcb->TCS_DrvHead / pTcb->TCS_DrvSector;
+	} else {
+		if (pTcb->TCS_DrvFlags & TCF_DRV_255_63) {
+			info_array[0] = 255;
+			info_array[1] = 63;
+			info_array[2] = disk->capacity / 255 / 63;
+		} else {
+			info_array[0] = 64;
+			info_array[1] = 32;
+			info_array[2] = disk->capacity >> 11;
+		}
+	}
+	return 0;
+}
+
+
+static void subIntr(ORC_HCS * pHCB, int irqno)
+{
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+	unsigned long flags;
+
+	spin_lock_irqsave(&io_request_lock, flags);
+#endif
+
+	if (pHCB->HCS_Intr != irqno) {
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+		spin_unlock_irqrestore(&io_request_lock, flags);
+#endif
+		return;
+	}
+	orc_interrupt(pHCB);
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+	spin_unlock_irqrestore(&io_request_lock, flags);
+#endif
+}
+
+/*
+ * Interrupts handler (main routine of the driver)
+ */
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+static void inia100_intr0(int irqno, void *dev_id, struct pt_regs *regs)
+#else
+static void inia100_intr0(int irqno, struct pt_regs *regs)
+#endif
+{
+	subIntr(&orc_hcs[0], irqno);
+}
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+static void inia100_intr1(int irqno, void *dev_id, struct pt_regs *regs)
+#else
+static void inia100_intr1(int irqno, struct pt_regs *regs)
+#endif
+{
+	subIntr(&orc_hcs[1], irqno);
+}
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+static void inia100_intr2(int irqno, void *dev_id, struct pt_regs *regs)
+#else
+static void inia100_intr2(int irqno, struct pt_regs *regs)
+#endif
+{
+	subIntr(&orc_hcs[2], irqno);
+}
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+static void inia100_intr3(int irqno, void *dev_id, struct pt_regs *regs)
+#else
+static void inia100_intr3(int irqno, struct pt_regs *regs)
+#endif
+{
+	subIntr(&orc_hcs[3], irqno);
+}
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+static void inia100_intr4(int irqno, void *dev_id, struct pt_regs *regs)
+#else
+static void inia100_intr4(int irqno, struct pt_regs *regs)
+#endif
+{
+	subIntr(&orc_hcs[4], irqno);
+}
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+static void inia100_intr5(int irqno, void *dev_id, struct pt_regs *regs)
+#else
+static void inia100_intr5(int irqno, struct pt_regs *regs)
+#endif
+{
+	subIntr(&orc_hcs[5], irqno);
+}
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+static void inia100_intr6(int irqno, void *dev_id, struct pt_regs *regs)
+#else
+static void inia100_intr6(int irqno, struct pt_regs *regs)
+#endif
+{
+	subIntr(&orc_hcs[6], irqno);
+}
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1,3,0)
+static void inia100_intr7(int irqno, void *dev_id, struct pt_regs *regs)
+#else
+static void inia100_intr7(int irqno, struct pt_regs *regs)
+#endif
+{
+	subIntr(&orc_hcs[7], irqno);
+}
+
+/* 
+ * Dump the current driver status and panic...
+ */
+static void inia100_panic(char *msg)
+{
+	printk("\ninia100_panic: %s\n", msg);
+	panic("inia100 panic");
+}
+
+/*#include "inia100scsi.c" */
diff -urN linux-2.0.37-pre6/drivers/scsi/inia100.h linux-2.0.37-pre7/drivers/scsi/inia100.h
--- linux-2.0.37-pre6/drivers/scsi/inia100.h	1969-12-31 16:00:00.000000000 -0800
+++ linux-2.0.37-pre7/drivers/scsi/inia100.h	2003-08-15 15:04:36.000000000 -0700
@@ -0,0 +1,503 @@
+/**************************************************************************
+ * Initio A100 device driver for Linux.
+ *
+ * Copyright (c) 1994-1998 Initio Corporation
+ * All rights reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2, or (at your option)
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; see the file COPYING.  If not, write to
+ * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+ *
+ * --------------------------------------------------------------------------
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions, and the following disclaimer,
+ *    without modification, immediately at the beginning of the file.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ * 3. The name of the author may not be used to endorse or promote products
+ *    derived from this software without specific prior written permission.
+ *
+ * Where this Software is combined with software released under the terms of 
+ * the GNU Public License ("GPL") and the terms of the GPL would require the 
+ * combined work to also be released under the terms of the GPL, the terms
+ * and conditions of this License will apply in addition to those of the
+ * GPL with the exception of any terms or conditions of this License that
+ * conflict with, or are expressly prohibited by, the GPL.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR
+ * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ **************************************************************************
+ *
+ * Module: inia100.h
+ * Description: INI-A100U2W LINUX device driver header
+ * Revision History:
+ *	06/18/98 HL, Initial production Version 1.02
+ *	12/19/98 bv, Use spinlocks for 2.1.95 and up
+ ****************************************************************************/
+
+#ifndef	CVT_LINUX_VERSION
+#define	CVT_LINUX_VERSION(V,P,S)	(((V) * 65536) + ((P) * 256) + (S))
+#endif
+
+#ifndef	LINUX_VERSION_CODE
+#include <linux/version.h>
+#endif
+
+#include "sd.h"
+
+extern int inia100_detect(Scsi_Host_Template *);
+extern int inia100_command(Scsi_Cmnd *);
+extern int inia100_queue(Scsi_Cmnd *, void (*done) (Scsi_Cmnd *));
+extern int inia100_abort(Scsi_Cmnd *);
+extern int inia100_reset(Scsi_Cmnd *, unsigned int);
+
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(1, 3, 0)
+extern int inia100_biosparam(Scsi_Disk *, kdev_t, int *);	/*for linux v2.0 */
+extern struct proc_dir_entry proc_scsi_inia100;
+#else
+extern int inia100_biosparam(Disk *, int, int *);	/*for linux v1.13 */
+#endif
+
+#define inia100_REVID "Initio INI-A100U2W SCSI device driver; Revision: 1.02a"
+
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(1, 3, 0)
+#define INIA100	{ \
+		NULL, \
+		NULL, \
+		inia100_REVID, \
+		inia100_detect, \
+		NULL, \
+		NULL, \
+		inia100_command, \
+		inia100_queue, \
+		inia100_abort, \
+		inia100_reset, \
+		NULL, \
+		inia100_biosparam, \
+		1, \
+7, \
+SG_ALL, \
+1, \
+0, \
+0, \
+ENABLE_CLUSTERING \
+}
+
+#else
+
+#if LINUX_VERSION_CODE < CVT_LINUX_VERSION(2, 1, 75)
+#define INIA100	{ \
+		NULL, \
+		NULL, \
+		&proc_scsi_inia100, \
+		NULL, \
+		inia100_REVID, \
+		inia100_detect, \
+		NULL, \
+		NULL, \
+		inia100_command, \
+		inia100_queue, \
+		inia100_abort, \
+		inia100_reset, \
+		NULL, \
+		inia100_biosparam, \
+		1, \
+		7, \
+		0, \
+		1, \
+		0, \
+		0, \
+		ENABLE_CLUSTERING \
+}
+#else				/* Version >= 2.1.75 */
+#define INIA100	{ \
+	next:		NULL,						\
+	module:		NULL,						\
+	proc_dir:	&proc_scsi_inia100, \
+	proc_info:	NULL,				\
+	name:		inia100_REVID, \
+	detect:		inia100_detect, \
+	release:	NULL, \
+	info:		NULL,					\
+	command:	inia100_command, \
+	queuecommand:	inia100_queue, \
+ 	eh_strategy_handler: NULL, \
+ 	eh_abort_handler: NULL, \
+ 	eh_device_reset_handler: NULL, \
+ 	eh_bus_reset_handler: NULL, \
+ 	eh_host_reset_handler: NULL, \
+	abort:		inia100_abort, \
+	reset:		inia100_reset, \
+	slave_attach:	NULL, \
+	bios_param:	inia100_biosparam, \
+	can_queue:	1, \
+	this_id:	1, \
+	sg_tablesize:	SG_ALL, \
+	cmd_per_lun: 	1, \
+	present:	0, \
+	unchecked_isa_dma: 0, \
+	use_clustering:	ENABLE_CLUSTERING, \
+ use_new_eh_code: 0 \
+}
+#endif
+#endif
+
+#define VIRT_TO_BUS(i)  (unsigned int) virt_to_bus((void *)(i))
+#define ULONG   unsigned long
+#define PVOID   void *
+#define USHORT  unsigned short
+#define UCHAR   unsigned char
+#define BYTE    unsigned char
+#define WORD    unsigned short
+#define DWORD   unsigned long
+#define UBYTE   unsigned char
+#define UWORD   unsigned short
+#define UDWORD  unsigned long
+#ifdef ALPHA
+#define U32     unsigned int
+#else
+#define U32     unsigned long
+#endif
+
+#ifndef NULL
+#define NULL     0		/* zero          */
+#endif
+#ifndef TRUE
+#define TRUE     (1)		/* boolean true  */
+#endif
+#ifndef FALSE
+#define FALSE    (0)		/* boolean false */
+#endif
+#ifndef FAILURE
+#define FAILURE  (-1)
+#endif
+#if 1
+#define ORC_MAXQUEUE		245
+#else
+#define ORC_MAXQUEUE		25
+#endif
+
+#define TOTAL_SG_ENTRY		32
+#define MAX_TARGETS		16
+#define IMAX_CDB			15
+#define SENSE_SIZE		14
+#define MAX_SUPPORTED_ADAPTERS  4
+#define SUCCESSFUL              0x00
+
+#define I920_DEVICE_ID	0x0002	/* Initio's inic-950 product ID   */
+
+/************************************************************************/
+/*              Scatter-Gather Element Structure                        */
+/************************************************************************/
+typedef struct ORC_SG_Struc {
+	U32 SG_Ptr;		/* Data Pointer */
+	U32 SG_Len;		/* Data Length */
+} ORC_SG;
+
+
+/* SCSI related definition                                              */
+#define DISC_NOT_ALLOW          0x80	/* Disconnect is not allowed    */
+#define DISC_ALLOW              0xC0	/* Disconnect is allowed        */
+
+
+#define ORC_OFFSET_SCB			16
+#define ORC_MAX_SCBS		    250
+#define MAX_CHANNELS       2
+#define MAX_ESCB_ELE				64
+#define TCF_DRV_255_63     0x0400
+
+/********************************************************/
+/*      Orchid Configuration Register Set               */
+/********************************************************/
+#define ORC_PVID	0x00	/* Vendor ID                      */
+#define ORC_VENDOR_ID	0x1101	/* Orchid vendor ID               */
+#define ORC_PDID        0x02	/* Device ID                    */
+#define ORC_DEVICE_ID	0x1060	/* Orchid device ID               */
+#define ORC_COMMAND	0x04	/* Command                        */
+#define BUSMS		0x04	/* BUS MASTER Enable              */
+#define IOSPA		0x01	/* IO Space Enable                */
+#define ORC_STATUS	0x06	/* Status register                */
+#define ORC_REVISION	0x08	/* Revision number                */
+#define ORC_BASE	0x10	/* Base address                   */
+#define ORC_BIOS	0x50	/* Expansion ROM base address     */
+#define ORC_INT_NUM	0x3C	/* Interrupt line         */
+#define ORC_INT_PIN	0x3D	/* Interrupt pin          */
+
+/********************************************************/
+/*      Orchid Host Command Set                         */
+/********************************************************/
+#define ORC_CMD_NOP		0x00	/* Host command - NOP             */
+#define ORC_CMD_VERSION		0x01	/* Host command - Get F/W version */
+#define ORC_CMD_ECHO		0x02	/* Host command - ECHO            */
+#define ORC_CMD_SET_NVM		0x03	/* Host command - Set NVRAM       */
+#define ORC_CMD_GET_NVM		0x04	/* Host command - Get NVRAM       */
+#define ORC_CMD_GET_BUS_STATUS	0x05	/* Host command - Get SCSI bus status */
+#define ORC_CMD_ABORT_SCB	0x06	/* Host command - Abort SCB       */
+#define ORC_CMD_ISSUE_SCB	0x07	/* Host command - Issue SCB       */
+
+/********************************************************/
+/*              Orchid Register Set                     */
+/********************************************************/
+#define ORC_GINTS	0xA0	/* Global Interrupt Status        */
+#define QINT		0x04	/* Reply Queue Interrupt  */
+#define ORC_GIMSK	0xA1	/* Global Interrupt MASK  */
+#define MQINT		0x04	/* Mask Reply Queue Interrupt     */
+#define	ORC_GCFG	0xA2	/* Global Configure               */
+#define EEPRG		0x01	/* Enable EEPROM programming */
+#define	ORC_GSTAT	0xA3	/* Global status          */
+#define WIDEBUS		0x10	/* Wide SCSI Devices connected    */
+#define ORC_HDATA	0xA4	/* Host Data                      */
+#define ORC_HCTRL	0xA5	/* Host Control                   */
+#define SCSIRST		0x80	/* SCSI bus reset         */
+#define HDO			0x40	/* Host data out          */
+#define HOSTSTOP		0x02	/* Host stop RISC engine  */
+#define DEVRST		0x01	/* Device reset                   */
+#define ORC_HSTUS	0xA6	/* Host Status                    */
+#define HDI			0x02	/* Host data in                   */
+#define RREADY		0x01	/* RISC engine is ready to receive */
+#define	ORC_NVRAM	0xA7	/* Nvram port address             */
+#define SE2CS		0x008
+#define SE2CLK		0x004
+#define SE2DO		0x002
+#define SE2DI		0x001
+#define ORC_PQUEUE	0xA8	/* Posting queue FIFO             */
+#define ORC_PQCNT	0xA9	/* Posting queue FIFO Cnt */
+#define ORC_RQUEUE	0xAA	/* Reply queue FIFO               */
+#define ORC_RQUEUECNT	0xAB	/* Reply queue FIFO Cnt           */
+#define	ORC_FWBASEADR	0xAC	/* Firmware base address  */
+
+#define	ORC_EBIOSADR0 0xB0	/* External Bios address */
+#define	ORC_EBIOSADR1 0xB1	/* External Bios address */
+#define	ORC_EBIOSADR2 0xB2	/* External Bios address */
+#define	ORC_EBIOSDATA 0xB3	/* External Bios address */
+
+#define	ORC_SCBSIZE	0xB7	/* SCB size register              */
+#define	ORC_SCBBASE0	0xB8	/* SCB base address 0             */
+#define	ORC_SCBBASE1	0xBC	/* SCB base address 1             */
+
+#define	ORC_RISCCTL	0xE0	/* RISC Control                   */
+#define PRGMRST		0x002
+#define DOWNLOAD		0x001
+#define	ORC_PRGMCTR0	0xE2	/* RISC program counter           */
+#define	ORC_PRGMCTR1	0xE3	/* RISC program counter           */
+#define	ORC_RISCRAM	0xEC	/* RISC RAM data port 4 bytes     */
+
+typedef struct orc_extended_scb {	/* Extended SCB                 */
+	ORC_SG ESCB_SGList[TOTAL_SG_ENTRY];	/*0 Start of SG list              */
+	Scsi_Cmnd *SCB_Srb;	/*50 SRB Pointer */
+} ESCB;
+
+/***********************************************************************
+		SCSI Control Block
+************************************************************************/
+typedef struct orc_scb {	/* Scsi_Ctrl_Blk                */
+	UBYTE SCB_Opcode;	/*00 SCB command code&residual  */
+	UBYTE SCB_Flags;	/*01 SCB Flags                  */
+	UBYTE SCB_Target;	/*02 Target Id                  */
+	UBYTE SCB_Lun;		/*03 Lun                        */
+	U32 SCB_Reserved0;	/*04 Reserved for ORCHID must 0 */
+	U32 SCB_XferLen;	/*08 Data Transfer Length       */
+	U32 SCB_Reserved1;	/*0C Reserved for ORCHID must 0 */
+	U32 SCB_SGLen;		/*10 SG list # * 8              */
+	U32 SCB_SGPAddr;	/*14 SG List Buf physical Addr  */
+	U32 SCB_SGPAddrHigh;	/*18 SG Buffer high physical Addr */
+	UBYTE SCB_HaStat;	/*1C Host Status                */
+	UBYTE SCB_TaStat;	/*1D Target Status              */
+	UBYTE SCB_Status;	/*1E SCB status                 */
+	UBYTE SCB_Link;		/*1F Link pointer, default 0xFF */
+	UBYTE SCB_SenseLen;	/*20 Sense Allocation Length    */
+	UBYTE SCB_CDBLen;	/*21 CDB Length                 */
+	UBYTE SCB_Ident;	/*22 Identify                   */
+	UBYTE SCB_TagMsg;	/*23 Tag Message                */
+	UBYTE SCB_CDB[IMAX_CDB];	/*24 SCSI CDBs                  */
+	UBYTE SCB_ScbIdx;	/*3C Index for this ORCSCB      */
+	U32 SCB_SensePAddr;	/*34 Sense Buffer physical Addr */
+
+	ESCB *SCB_EScb;		/*38 Extended SCB Pointer       */
+#ifndef ALPHA
+	UBYTE SCB_Reserved2[4];	/*3E Reserved for Driver use    */
+#endif
+} ORC_SCB;
+
+/* Opcodes of ORCSCB_Opcode */
+#define ORC_EXECSCSI	0x00	/* SCSI initiator command with residual */
+#define ORC_BUSDEVRST	0x01	/* SCSI Bus Device Reset  */
+
+/* Status of ORCSCB_Status */
+#define SCB_COMPLETE	0x00	/* SCB request completed  */
+#define SCB_POST	0x01	/* SCB is posted by the HOST      */
+
+/* Bit Definition for ORCSCB_Flags */
+#define SCF_DISINT	0x01	/* Disable HOST interrupt */
+#define SCF_DIR		0x18	/* Direction bits         */
+#define SCF_NO_DCHK	0x00	/* Direction determined by SCSI   */
+#define SCF_DIN		0x08	/* From Target to Initiator       */
+#define SCF_DOUT	0x10	/* From Initiator to Target       */
+#define SCF_NO_XF	0x18	/* No data transfer               */
+#define SCF_POLL   0x40
+
+/* Error Codes for ORCSCB_HaStat */
+#define HOST_SEL_TOUT	0x11
+#define HOST_DO_DU	0x12
+#define HOST_BUS_FREE	0x13
+#define HOST_BAD_PHAS	0x14
+#define HOST_INV_CMD	0x16
+#define HOST_SCSI_RST	0x1B
+#define HOST_DEV_RST	0x1C
+
+
+/* Error Codes for ORCSCB_TaStat */
+#define TARGET_CHK_COND	0x02
+#define TARGET_BUSY	0x08
+#define TARGET_TAG_FULL	0x28
+
+
+/* Queue tag msg: Simple_quque_tag, Head_of_queue_tag, Ordered_queue_tag */
+#define MSG_STAG	0x20
+#define MSG_HTAG	0x21
+#define MSG_OTAG	0x22
+
+#define MSG_IGNOREWIDE	0x23
+
+#define MSG_IDENT	0x80
+#define MSG_DISC	0x40	/* Disconnect allowed             */
+
+
+/* SCSI MESSAGE */
+#define	MSG_EXTEND	0x01
+#define	MSG_SDP		0x02
+#define	MSG_ABORT	0x06
+#define	MSG_REJ		0x07
+#define	MSG_NOP		0x08
+#define	MSG_PARITY	0x09
+#define	MSG_DEVRST	0x0C
+#define	MSG_STAG	0x20
+
+/***********************************************************************
+		Target Device Control Structure
+**********************************************************************/
+
+typedef struct ORC_Tar_Ctrl_Struc {
+	UBYTE TCS_DrvDASD;	/* 6 */
+	UBYTE TCS_DrvSCSI;	/* 7 */
+	UBYTE TCS_DrvHead;	/* 8 */
+	UWORD TCS_DrvFlags;	/* 4 */
+	UBYTE TCS_DrvSector;	/* 7 */
+} ORC_TCS, *PORC_TCS;
+
+/* Bit Definition for TCF_DrvFlags */
+#define	TCS_DF_NODASD_SUPT	0x20	/* Suppress OS/2 DASD Mgr support */
+#define	TCS_DF_NOSCSI_SUPT	0x40	/* Suppress OS/2 SCSI Mgr support */
+
+
+/***********************************************************************
+              Host Adapter Control Structure
+************************************************************************/
+typedef struct ORC_Ha_Ctrl_Struc {
+	USHORT HCS_Base;	/* 00 */
+	UBYTE HCS_Index;	/* 02 */
+	UBYTE HCS_Intr;		/* 04 */
+	UBYTE HCS_SCSI_ID;	/* 06    H/A SCSI ID */
+	UBYTE HCS_BIOS;		/* 07    BIOS configuration */
+
+	UBYTE HCS_Flags;	/* 0B */
+	UBYTE HCS_HAConfig1;	/* 1B    SCSI0MAXTags */
+	UBYTE HCS_MaxTar;	/* 1B    SCSI0MAXTags */
+
+	USHORT HCS_Units;	/* Number of units this adapter  */
+	USHORT HCS_AFlags;	/* Adapter info. defined flags   */
+	ULONG HCS_Timeout;	/* Adapter timeout value   */
+	PVOID HCS_virScbArray;	/* 28 Virtual Pointer to SCB array     */
+	U32 HCS_physScbArray;	/* Scb Physical address */
+	PVOID HCS_virEscbArray;	/* Virtual pointer to ESCB Scatter list */
+	U32 HCS_physEscbArray;	/* scatter list Physical address */
+	UBYTE TargetFlag[16];	/* 30  target configuration, TCF_EN_TAG */
+	UBYTE MaximumTags[16];	/* 40  ORC_MAX_SCBS */
+	UBYTE ActiveTags[16][16];	/* 50 */
+	ORC_TCS HCS_Tcs[16];	/* 28 */
+	U32 BitAllocFlag[MAX_CHANNELS][8];	/* Max STB is 256, So 256/32 */
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+	spinlock_t BitAllocFlagLock;
+#endif
+	Scsi_Cmnd *pSRB_head;
+	Scsi_Cmnd *pSRB_tail;
+#if LINUX_VERSION_CODE >= CVT_LINUX_VERSION(2,1,95)
+	spinlock_t pSRB_lock;
+#endif
+} ORC_HCS;
+
+/* Bit Definition for HCS_Flags */
+
+#define HCF_SCSI_RESET	0x01	/* SCSI BUS RESET         */
+#define HCF_PARITY    	0x02	/* parity card                    */
+#define HCF_LVDS     	0x10	/* parity card                    */
+
+/* Bit Definition for TargetFlag */
+
+#define TCF_EN_255	    0x08
+#define TCF_EN_TAG	    0x10
+#define TCF_BUSY	      0x20
+#define TCF_DISCONNECT	0x40
+#define TCF_SPIN_UP	  0x80
+
+/* Bit Definition for HCS_AFlags */
+#define	HCS_AF_IGNORE		0x01	/* Adapter ignore         */
+#define	HCS_AF_DISABLE_RESET	0x10	/* Adapter disable reset  */
+#define	HCS_AF_DISABLE_ADPT	0x80	/* Adapter disable                */
+
+
+/*---------------------------------------*/
+/* TimeOut for RESET to complete (30s)   */
+/*                                       */
+/* After a RESET the drive is checked    */
+/* every 200ms.                          */
+/*---------------------------------------*/
+#define DELAYED_RESET_MAX       (30*1000L)
+#define DELAYED_RESET_INTERVAL  200L
+
+/*----------------------------------------------*/
+/* TimeOut for IRQ from last interrupt (5s)     */
+/*----------------------------------------------*/
+#define IRQ_TIMEOUT_INTERVAL    (5*1000L)
+
+/*----------------------------------------------*/
+/* Retry Delay interval (200ms)                 */
+/*----------------------------------------------*/
+#define DELAYED_RETRY_INTERVAL  200L
+
+#define	INQUIRY_SIZE		36
+#define	CAPACITY_SIZE		8
+#define	DEFAULT_SENSE_LEN	14
+
+#define	DEVICE_NOT_FOUND	0x86
+
+/*----------------------------------------------*/
+/* Definition for PCI device                    */
+/*----------------------------------------------*/
+#define	MAX_PCI_DEVICES	21
+#define	MAX_PCI_BUSES	8
diff -urN linux-2.0.37-pre6/drivers/scsi/Makefile linux-2.0.37-pre7/drivers/scsi/Makefile
--- linux-2.0.37-pre6/drivers/scsi/Makefile	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/drivers/scsi/Makefile	2003-08-15 15:04:36.000000000 -0700
@@ -388,6 +388,14 @@
   endif 
 endif 
 
+ifeq ($(CONFIG_SCSI_TC2550),y) 
+L_OBJS += tripace.o 
+else 
+  ifeq ($(CONFIG_SCSI_TC2550),m) 
+  M_OBJS += tripace.o 
+  endif 
+endif 
+
 ifeq ($(CONFIG_SCSI_MEGARAID),y)
 L_OBJS += megaraid.o
 else
@@ -396,6 +404,14 @@
   endif
 endif
 
+ifeq ($(CONFIG_SCSI_INIA100),y)
+L_OBJS += a100u2w.o
+else
+  ifeq ($(CONFIG_SCSI_INIA100),m)
+  M_OBJS += a100u2w.o
+  endif
+endif
+
 ifeq ($(CONFIG_BLK_DEV_IDESCSI),y)
 L_OBJS += ide-scsi.o
 endif
@@ -433,6 +449,9 @@
 megaraid.o: megaraid.c
 	$(CC) $(CFLAGS) -c megaraid.c
 
+a100u2w.o: inia100.o i60uscsi.o
+	$(LD) -r -o a100u2w.o inia100.o i60uscsi.o
+
 scsi_mod.o: $(MX_OBJS) hosts.o scsi.o scsi_ioctl.o constants.o \
 		scsicam.o scsi_proc.o
 	$(LD) $(LD_RFLAG) -r -o $@ $(MX_OBJS) hosts.o scsi.o scsi_ioctl.o constants.o scsicam.o scsi_proc.o
diff -urN linux-2.0.37-pre6/drivers/scsi/tripace.c linux-2.0.37-pre7/drivers/scsi/tripace.c
--- linux-2.0.37-pre6/drivers/scsi/tripace.c	1969-12-31 16:00:00.000000000 -0800
+++ linux-2.0.37-pre7/drivers/scsi/tripace.c	2003-08-15 15:04:36.000000000 -0700
@@ -0,0 +1,1562 @@
+/* tc2550.c -- Tripace TC-2550x based PCI SCSI Adapter  SCSI driver
+ * Created:D.Ravi jun 8 1998 at chennai lab of Tripace 
+ * Copyright 1998 Tripace Europe BV
+ *
+ * Driver version 1.00.000 (904)
+
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License as published by the
+ * Free Software Foundation; either version 2, or (at your option) any
+ * later version.
+
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * General Public License for more details.
+
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 675 Mass Ave, Cambridge, MA 02139, USA.
+
+ **************************************************************************
+
+ DESCRIPTION:
+
+
+
+
+ REFERENCES USED:
+
+ 1.0 Design Kit for the Tripace TC-2550x based PCI SCSI  Adapter
+
+ 2.0 Tripace IOLAYER document.
+
+ 3.0 LINUX driver sources in /usr/linux/drivers/scsi directory.
+
+
+ ALPHA TESTERS:
+
+ 1.0 so far no external testers,only developer testing has been done.
+
+ 2.0 Testing with IBMHDD,Quantum HDD,zip drive and sony CDROM has been 
+ done.
+
+
+ NOTES ON USER DEFINABLE OPTIONS:
+
+ 1.0 The following are the command line options that are possible for the
+ TRIPACE TC-2550 PCI SCSI controller without BIOS.
+
+ tripace=fast clock,discon,sync,tag
+
+
+ The values for these four options can be either 0 or 1.
+ If fast clock is set to 1 ,then the chip uses a 60mhz clock.If ultra
+ scsi devices are used this should be set and the controller should have a
+ 60mhz crystal.
+
+ if disconnect is 1 ,then disconnect/reconnect is allowed for all scsi
+ devices connected to the controller.if it is 0 ,it is off.
+
+ sync = 1 means that synchronous negotiation will be done with scsi
+ devices.currently,though the flag is set ,the function is not implemented.
+
+ Tag = 1 means that tagged queue commands can be sent to the scsi devices.
+ This is not implemnted as yet in the driver. 
+
+ The default values are 0,1,1,1
+
+ **************************************************************************/
+
+#ifdef MODULE
+#include <linux/module.h>
+#endif
+
+#include <linux/kernel.h>
+#include <linux/malloc.h>
+#include <linux/mm.h>
+#include <linux/head.h>
+#include <linux/sched.h>
+#include <linux/types.h>
+#include <asm/io.h>
+#include <linux/blk.h>
+#include "scsi.h"
+#include "hosts.h"
+#include "tripace.h"
+#include <asm/system.h>
+#include <asm/dma.h>
+#include <linux/errno.h>
+#include <linux/string.h>
+#include <linux/ioport.h>
+#include <linux/proc_fs.h>
+#include <linux/bios32.h>
+#include <linux/pci.h>
+#include <linux/delay.h>
+#include "tripace_mcode.h"
+
+#define VERSION          "$Revision: 1.00 $"
+
+/* #define DEBUG */
+
+
+#define   MAXTARGET               8
+#define   MAXSRBS		  16
+
+#define   RISC_ENTRY1             0
+
+#define   DEV_PARAM_REG_BASE      CFG_BASE+0x20
+
+#define   SCSI_DMA_POINTER        CFG_BASE+0x40
+#define   SCSI_DMA_COUNTER        CFG_BASE+0x44
+#define   HOST_DMA_POINTER        CFG_BASE+0x48
+#define   HOST_DMA_COUNTER        CFG_BASE+0x4c
+#define   MBX_IN_BASE             CFG_BASE+0x50
+#define   MBX_OUT_BASE            CFG_BASE+0x54
+#define   DEV_HDR_BASE            CFG_BASE+0x58
+#define   TASK_Q_BASE             CFG_BASE+0x5c
+#define   CURRENT_DEV_PTR         CFG_BASE+0x60
+#define   CURRENT_TASK_PTR        CFG_BASE+0x64
+#define   SG_LIST_PTR             CFG_BASE+0x68
+#define   ACC                     CFG_BASE+0x6c
+#define   SCRATCHB                CFG_BASE+0x70
+#define   CURRENT_INST            CFG_BASE+0x74
+#define   FLAG                    CFG_BASE+0x78
+#define   SCRATCHC                CFG_BASE+0x7a
+#define   MBX_IN_INDEX            CFG_BASE+0x7b
+#define   PC                      CFG_BASE+0x7c
+#define   MBX_OUT_INDEX           CFG_BASE+0x7f
+#define   PROGRAM_DATA_REG        CFG_BASE+0x80
+#define   CONTROL_REG             CFG_BASE+0x84
+#define   STATUS_INT_REG          CFG_BASE+0x86
+#define   SCSI_DATA               CFG_BASE+0x88
+#define   SCSI_CONTROL            CFG_BASE+0x8A
+#define   SCSI_ID_REG             CFG_BASE+0x8b
+
+#define   INFO_BASE               0x780
+#define   SIG_BASE                0x7D4
+
+#define   Q_FILE_SIZE             8192
+#define   DEVHDR_SIZE              512
+#define   MBOX_SIZE                 48
+#define   BIOS_SIGNATURE          0x55AAC731
+
+#define   PCI_1                   1
+#define   PCI_2                   2
+#define   MAX                     28
+
+#define   PCI_BUS                 1
+#define   PCI_INDEX_PORT          0xCF8
+#define   PCI_INDEX               0xF0
+#define   PCI_CONFIG              0xC000  /* this needs to include slot number */
+
+#define   FAIL                   -1
+/* #define   GOOD                 0 */
+#define   ERR                     1
+#define   DONE                    2
+#define   INT_HALT             0xfe000000	/* interrupt code */
+
+#define   SRB_DONE                0
+#define   SRB_ACTIVE              2
+#define   SRB_READY               1
+#define   SRB_CLEAN               4
+#define   SRB_ASSIGNED            8
+#define   SRB_STOP                2
+
+#define   STOP_RISC               2
+#define   FIRST_CMD               1
+#define   SPECIAL_CMD             1
+#define   MAX_OFFSET             30
+/* #define   MAX_PERIOD             12 */
+#define   MAX_PERIOD             12
+#define   W_MAX_OFFSET           14
+
+/* msg */
+#define   CMD_ABORT              0x6
+#define   DEVICE_RESET           0xC
+
+
+#define   CHECK_SYNC             0xA
+#define   CHECK_WIDE             0xD
+#define   SYNC_NORESPONSE        0x8
+#define   SYNC_REJECTED          0x9
+#define   SEL_TIME_OUT	         0x11
+#define   ERR_OVERRUN		 0x12
+#define   ERR_BUSFREE		 0x13
+#define   ERR_PHASE		 0x14
+#define   CHECK_COND		 0x04
+#define   ERR_PARITY  		 0x05
+#define   ERR_MESSAGE 		 0x07
+#define   WIDE_NORESPONSE        0x0b
+#define   WIDE_REJECTED          0x0c
+
+
+#define   DO_WIDE_NEGO           0x02
+#define   DO_SYNC_NEGO           0x04
+#define   FIRST_COMMAND          0x01
+
+#define   ENABLE_WIDE_BUS        0x100
+#define   ENABLE_TAG_MSG         0x200
+
+/*---------------------------------------------------------*
+**  parameter in register definitions                      *
+**                                                         *
+**---------------------------------------------------------*/
+/*
+   status register (read only)
+ */
+#define      INTR_PENDING         0x01
+#define      INTR_DIS             0x02
+#define      SCAM_INTR_DIS        0x04
+#define      POWER_SAVE_ON        0x08
+#define      SCSI_RESET_OUT       0x10
+#define      SCAM_INTR            0x20
+#define      RISC_HALT            0x40
+#define      SELECTION_TIMEOUT    0x80
+#define      SCSI_PARITY_ERR      0x100
+#define      SCSI_RESET_LAT       0x200
+#define      STS_SCSI_RESET       0x400
+#define      EEPROM_IN            0x800
+#define      SCAM_ARB_WIN         0x1000
+#define      EN_DMA               0x2000
+#define      EN_ARB_SEL           0x4000
+/*
+   **   interrupt control register (write only)
+ */
+#define      RESET_INTR_LATCH     0x01
+#define      DIS_INTR             0x02
+#define      DIS_SCAM_INTR        0x04
+#define      POWER_SAVE           0x08
+#define      RESET_SCSI_BUS       0x10
+/*ravi 10/3/98 changed for term power disable/enable in command line */
+/*#define      EN_TERM_PWR          0x20 */
+#define      TERM_PWR_EN            0x20
+/*
+   **   control register ( read/write )
+ */
+#define      RISC_CHIP_RESET      0x01
+#define      RISC_SINGLE_SETP     0x02
+#define      HALT_RISC            0x04
+#define      EN_SCSI_SCAM         0x08
+#define      DIS_SCSI_PARITY      0x10
+#define      EN_TARGET_MODE       0x20
+#define      FAST_CLOCK           0x40
+#define      EN_MEMORY_WRITE      0x80
+#define      DIS_PCI_BURST        0x100
+#define      DIS_PCI_CACHE_LINE   0x200
+#define      DIS_MUL_CACHE_LINE   0x400
+#define      EEPROM_CLOCK         0x800
+#define      EEPROM_DATA_OUT      0x1000
+#define      EEPROM_CHIP_SEL      0x2000
+#define      FAST_SELECTION       0x4000
+#define      EN_SCAM_ARB          0x8000
+
+#define      TASK_DONE            0x80
+
+
+/***************************************************************************
+**	 filename: newtypes.h
+**	 usage   : type definition 
+****************************************************************************/
+
+
+/***************************************************************************
+**	 filename: newtypes.h
+**	 usage   : type definition 
+****************************************************************************/
+
+#define   MAX_Adapter   4	/* maximu adapters allow                */
+
+/*
+   **   command related structure (7 bytes)
+ */
+typedef struct _task_cmd
+{
+	u8 CmdInProcess;
+	u8 * REQ_Header;
+	void (*complete) (void);
+}
+TaskCmd, *PTaskCmd;
+
+/*
+   ** total 128 bytes
+ */
+typedef struct _HIM
+{
+	u8 status;		/* device status, 0xFF not installed    */
+	u8 Target_ID;		/* target ID                            */
+	u8 type;		/* target type mapped to device name    */
+	u16 attrib;		/* lo 4bit: 1-Wide, 2-Sync, 4-Tag,      */
+	/*          8-removable,                */
+	/* hi 4bit: 10h do wide, 20h do sync,   */
+	/*          40h do tag, 0x80h - disc    */ 
+	/* bit 15: under BIOS, bit 8: > 1GB     */
+	 u8 op_param;		/* bit 7-5:period, bit4-0:offset        */
+	u8 drv_num;		/* current ID --> 8x for BIOS used only */
+	u8 sect_per_track;	/* sector per track                     */
+	u8 head_per_cyl;	/* sector per track                     */
+	u8 byte_per_sect;	/* byte per sector (BIOS is 512)        */
+	u8 link_count;	/* SRB link count:                      */
+	u8 * ASPICMDLink;	/* SRB link starting pointer            */
+	TaskCmd task[16];	/* array structure for each task        */
+	
+}
+DEVStruct;
+
+/*
+   ** total (4K+ 36) bytes for each adapter 
+ */
+typedef struct _Adapter
+{
+	u16 IoPort;		/* I/O Port address, 0 notsupport       */
+	u8 AdapterID;		/* Adapter scsi ID, default = 7         */
+	u8 first_disk_num;	/* first disk number under BIOS (82->2) */
+	u8 last_disk_num;	/* last disk number under BIOS          */
+	u8 time_factor;	/* used for device scam                 */
+
+	u8 IntrNum;		/* -1 NotSupport, otherwise IRQ         */
+	u16 hw_attr;		/* see eeprom def                       */
+	u16 sw_attr;		/* see eeprom def                       */
+	DEVStruct dev[16];	/* target device structure              */
+	u16 mbx_out_ptr;	/* mail box out pointer                 */
+	u8 HAParam[16];	/* host adapter parameters              */
+	u8 bios_install;	/* adapter has BIOS installed           */
+	u16 scam_type;		/* scam use              */
+	u8 scam_assigned;	/* scam use              */
+	u8 * Signature;	/* BIOS signature & new manager address */
+	u32 mbx_in_base;	/* mbx in base  logical address    */
+	u32 mbx_out_base;	/* mbx out base logical address    */
+	u32 devhdr_base;	/* devhdr base logical address     */
+	u32 taskq_base;	/* taskq base  logical address     */
+	u32 ptaskq_base;	/* taskq base physical address     */
+	u32 pdev_base;		/* taskq base physical address     */
+	u32 pmbi_base;		/* taskq base physical address     */
+	u32 pmbo_base;		/* taskq base physical address     */
+}
+Adapter, *PAdapter;
+
+/*
+   **  adapter information structure reserved for BIOS usage
+ */
+
+typedef struct _dev_parm
+{
+	u8 header;		/* header             */
+	u8 sect_per_track;	/* sector per tarck   */
+}
+target_parm, *ptarget_parm;
+/*
+   **  This structure is for BIOS used and read by driver
+ */
+typedef struct _Ada_data
+{
+	u8 drv_start;		/* first drive           */
+	u8 drv_end;		/* last drive            */
+	u16 timfact;		/* timing factor         */
+	u32 old_int13;		/* old int13 addr        */
+	u8 drive_id[8];	/* index= (8x-drv_start) */
+	u8 drive_num[16];	/* device number         */
+	target_parm dev[16];	/* device parameters     */
+	u8 allow_discon[16];	/* disconnect record     */
+	u16 scam_type;		/* scam use              */
+	u8 scam_assigned;	/* scam use              */
+	u8 adapter_id;	/* scam use              */
+	u32 signature;		/* BIOS signature        */
+}
+HA_data, *PHA_data;
+
+
+typedef struct _ScatGath
+{
+	u32 sg_address;	/* must be physical address */
+	u32 sg_length;		/* sg length     */
+}
+ScatGath, *PScatGath;
+
+/* length must be 32 bytes */
+typedef struct _risc_srb
+{
+	u8 Tag_info;		/* Tag information */
+	u8 SRB_flag;		/* SRB flag */
+	u8 DEV_Status;	/* SRB status */
+	u8 ScsiStatus;	/* scsi command status */
+	u32 CDB;		/* SCSI Command Block */
+	u32 CDBLength;		/* SCSI Command Length */
+	u32 SenseDataPtr;	/* auto sense pointer */
+	u32 Sense_Cmd_Ptr;	/* auto sense pointer */
+	u32 SG_ListPtr;	/* SG list  */
+	u8 SGNum;		/* S/G number */
+	u8 Identify;		/* Identify  message */
+	u8 Sense_LUN;		/* lun               */
+	u8 Sense_len;		/* sense len         */
+	u32 Cmd_sg_addr;	/* cmr sg ptr point to cmd */
+}
+RISC_SRB, *PRISC_SRB;
+
+
+typedef struct _SRB
+{				/* for SCSI */
+	RISC_SRB *risc_srb;	/* structure of SRB in RISC */
+	PAdapter AdapterPtr;	/* a pointer to adapter structure */
+	u8 LUN;		/* lun number */
+	u8 Tag_type;		/* tag type */
+	u8 Request_type;	/* request type */
+}
+SRB, *PSRB;
+
+typedef struct _sync_tbl
+{
+	int period;		/* parameter setting  */
+	int f_factor;		/* fast clock factor  */
+	int s_factor;		/* slow clock factor  */
+}
+sync_tbl;
+
+/*
+   **  total 12 bytes of sg header 
+ */
+typedef struct _dma_hrd
+{
+	u32 size;		/* region size        */
+	u32 offset;		/* offste             */
+	u16 segment;		/* segment            */
+	u16 revsed;		/* reserved           */
+	u16 num_avail;		/* number available   */
+	u16 num_used;		/* number used        */
+}
+DMA_HDR;
+
+/*
+   **  total 60 bytes (for each task in windows)
+ */
+typedef struct _dma_desc
+{
+	DMA_HDR dma_hdr;
+	ScatGath sg_list[6];
+}
+dma_desc, *Pdma_desc;
+
+/* Flags */
+#define SRB_TOHOST    8
+#define SRB_TOTARGET  0x10
+#define SRB_NEEDSDT   0x20
+#define SRB_SENSE     0x40	/* only for OSD      */
+#define SIZE_OF_SG    0x3C	/* size of sg table (60 bytes)  */
+
+/* 2. Target Error == SCSI Status */
+
+/* ============ function definiton ============ 
+   ** 1. INPUT:  PSRB
+   **    Start a scsi command. 
+   * */
+static void StartScsiCmd(PRISC_SRB);
+
+#define  CMD_INPROGRESS      0x01
+#define  CMD_DISCONCTED      0x02
+#define  CMD_DATAXFERED      0x04
+
+#define  TAR_TRUESG          0x01
+#define  NEEDSDTN            0x10
+
+#define  MSG_ABORT           0x06
+#define  MSG_RESET           0x0C
+#define  MSG_ALLOWDISC       0x40
+#define  MSG_IDENTIFY        0x80
+#define  MSG_EXTENDED        0x01
+#define  MSG_NOMSG           0x08
+#define  MSG_CMDCOMP         0x00
+#define  MSG_DISC            0x04
+#define  MSG_IGNWR           0x23
+#define  MSG_RESTPTR         0x03
+#define  MSG_SAVEPTR         0x02
+#define  MSG_REJECTED        0x07
+#define  MSG_INITRECVY       0x0f
+#define  MSG_LNKCMD          0x0a
+#define  MSG_LNKCMDTAG       0x0b
+#define  MSG_SIMPLEQUE       0x20
+#define  MSG_MDFDATPTR       0x00
+#define  MSG_SDTREQ          0x01
+#define  MSG_WDTREQ          0x03
+
+#define  SECOND              18	//ticks per second
+#define  DEV_EMPTY           0xFF
+
+typedef struct _DEVHDR
+{
+	u32 Updatedmap;	/* updated bitmap      */
+	u32 Startedmap;	/* start bitmap        */
+	u32 Currentmap;	/* current bitmap      */
+	u8 Task_Index;	/* current task index  */
+	u8 Request_type;	/* request type        */
+	u8 SpCmddone;		/* special commad done */
+	u8 Srb_loc;		/* location            */
+	u8 TagCmdCnt;		/* Pending task count  */
+	u8 ScsiID;		/* scsi ID             */
+	u8 DeviceNum;		/* device number       */
+	u8 WideMsg;		/* wide bus message    */
+	u8 SyncPeriod;	/* sync period         */
+	u8 SyncOffset;	/* sync offset         */
+	u8 RtnWideMsg;	/* return wide bus msg */
+	u8 RtnSyncPeriod;	/* Rtn sync period     */
+	u8 RtnSyncOffset;	/* rtn sync offset     */
+	u8 ChkSenseTask;	/* check sense task    */
+	u8 SenseCmd[6];	/* sense command       */
+}
+DevHdr, *PDevHdr;
+
+typedef struct _E2Prom
+{
+	u16 hw_parm;
+	u16 sw_parm;
+	u16 dev_parm[16];
+}
+E2prom, *PE2prom;
+
+/* parameter setting for parameter */
+#define		HW_ADAPTER_ID            0x0f
+#define		HW_PARITY_DISABLE        0x10
+#define		HW_TERMPWR_ENABLE        0x20
+#define		HW_FAST_CLOCK            0x40
+#define		HW_DIAG_ENABLE           0x80
+#define		HW_BURST_DISABLE         0x100
+#define		HW_CACHE_LINE_DISABLE    0x200
+#define		HW_MULTI_CACHE_DISABLE   0x400
+#define		HW_SCAM_ENABLE           0x800
+#define		HW_CACHE_LINE_SIZE_4	  0x1000
+#define		HW_CACHE_LINE_SIZE_8	  0x2000
+#define		HW_CACHE_LINE_SIZE_16	  0x3000
+#define		HW_FAST_SELECTION        0x4000
+#define		HW_BIOS_DISABLE          0x8000
+
+
+/* software setting      */
+#define		SW_REMOVABLE_SUPPORT     0x1
+#define		SW_OVER_1GB              0x2
+#define		SW_8_DRIVE_SUPPORT       0x4
+#define		SW_MAX_ID		 0x8
+#define		SW_DEVICE_CHANGED        0x10
+
+/* parameter setting     */
+#define		PM_UNDER_BIOS            0x8000
+#define		PM_BIOSSCAN_DISABLE      0x2000
+#define		PM_NEED_STARTCMD         0x1000
+#define		PM_DISCON_ENABLE         0x800
+#define		PM_SYNC_ENABLE           0x400
+#define		PM_TAG_ENABLE            0x200
+#define		PM_WIDEBUS_ENABLE        0x100
+#define		PM_TRANSFER_RATE         0xE0
+#define		PM_TRANSFER_OFFSET       0x1F
+
+/* ScsiFunc  */
+#define		SUPPORT_MORETHAN16M  0x40
+#define		SUPPORT_RESELECT     0x20
+#define		SUPPORT_SYNC         0x10
+#define		SUPPORT_LINKED       0x08
+#define		SUPPORT_CMDQUEUE     0x02
+#define		SUPPORT_SFTRE        0x01
+#define		SUPPORT_WIDEHOST     0x04
+#define		SUPPORT_PARCHK       0x80
+
+
+static unsigned int port_base = 0;
+static unsigned int CFG_BASE = 0;
+static unsigned int interrupt_level = 0;
+
+/* period table 
+
+   static sync_tbl  period_tbl[8]= {
+   { 0, 12, 12,},
+   { 1, 16, 18,},
+   { 2, 20, 25,},
+   { 3, 25, 31,},
+   { 4, 29, 37,},
+   { 5, 33, 43,},
+   { 6, 50, 50,},
+   { 7, 58, 75,},
+   };
+ */
+
+/* pointer to scsi host struc for each HA */
+/* needs change for multiple HA support */
+
+static struct Scsi_Host *tripace_host;
+
+/* Tc2550 mailbox data structures */
+static unsigned char tcmbdata[Q_FILE_SIZE + DEVHDR_SIZE + MBOX_SIZE + 64];
+/* static alloc of sg table for all tasks */
+/* dynamic memory is giving problems */
+static unsigned char table[8 * MAXSGENT * MAXSRBS * MAXTARGET + 4];
+
+
+/* global variables */
+/* logical addresses of mailbox in/out,dev header base,task que base */
+
+static unsigned char *startsgptr;
+static unsigned long pstartsgptr;
+
+
+static u32 mbx_in_base, mbx_out_base, devhdr_base, taskq_base;
+static u8 TargetID;
+
+
+/* hostadapter structure-as of now we have a single adapter */
+Adapter HostAdapter[1];
+unsigned char ReqType, targetID, HANumber, Index, HostID;
+
+/* variable for term power in case of /T option */
+static unsigned short int EN_TERM_PWR = TERM_PWR_EN;
+static unsigned short fast_clk = 0;
+static unsigned short par_off = 0;
+static unsigned short discon = 1;
+static unsigned short syncflag = 1;
+static unsigned short tagflag = 0;
+
+
+static int makecode(unsigned, unsigned);
+static void Init_struc(int);
+static int download_RISC_code(void);
+static void init_chip_reg(void);
+
+static PRISC_SRB search(PAdapter);
+u32 insert_bit(u32, short int);
+static void Get_Base(Adapter *);
+
+void tc2550_intr(int, struct pt_regs *);
+
+static void internal_done(Scsi_Cmnd *);
+
+int tc2550_command(Scsi_Cmnd *);
+
+static int tc2550_pci_bios_detect(int *irq, int *iobase)
+{
+	int error;
+	unsigned char pci_bus, pci_dev_fn;	/* PCI bus & device function */
+	unsigned char pci_irq;	/* PCI interrupt line */
+	unsigned int pci_base;	/* PCI I/O base address */
+	unsigned short pci_vendor, pci_device;	/* PCI vendor & device IDs */
+
+
+	/* We will have to change this if more than 1 PCI bus is present and the
+	   tripace scsi host is not on the first bus (i.e., a PCI to PCI bridge,
+	   which is not supported by bios32 right now anyway). */
+
+	pci_bus = 0;
+
+	for (pci_dev_fn = 0x0; pci_dev_fn < 0xff; pci_dev_fn++)
+	{
+		pcibios_read_config_word(pci_bus,
+					 pci_dev_fn,
+					 PCI_VENDOR_ID,
+					 &pci_vendor);
+
+		if (pci_vendor == 0x1190)
+		{
+			pcibios_read_config_word(pci_bus,
+						 pci_dev_fn,
+						 PCI_DEVICE_ID,
+						 &pci_device);
+
+			if (pci_device == 0xc731)
+			{
+				/* Break out once we have the correct device.  If othertrip 
+				   PCI devices are added to this driver we will need to add
+				   an or of the other PCI_DEVICE_ID here. */
+				printk(KERN_INFO "Tripace TC-2550x based PCI SCSI Adapter detected\n");
+				break;
+			} else
+			{
+				/* If we can't finl an tripace scsi card we give up. */
+				return 0;
+			}
+		}
+	}
+
+/* vendor id not found */
+
+	if (pci_device != 0xc731)
+	{
+		printk(KERN_INFO "Tripace TC-2550x - No Host Adapter Detected \n");
+		return (0);
+	}
+	/* We now have the appropriate device function for the tripace board so we
+	   just read the PCI config info from the registers.  */
+
+	if ((error = pcibios_read_config_dword(pci_bus,
+					       pci_dev_fn,
+					       PCI_BASE_ADDRESS_0,
+					       &pci_base))
+	    || (error = pcibios_read_config_byte(pci_bus,
+						 pci_dev_fn,
+						 PCI_INTERRUPT_LINE,
+						 &pci_irq)))
+	{
+		printk(KERN_ERR "Tripace TC-2550x not initializing"
+		       " due to error reading configuration space\n");
+		return 0;
+	} else
+	{
+		printk(KERN_INFO "TC-2550x PCI: IRQ = %u, I/O base = %X\n",
+		       pci_irq, pci_base);
+
+		/* Now we have the I/O base address and interrupt from the PCI
+		   configuration registers.  
+		 */
+
+		*irq = pci_irq;
+		*iobase = (pci_base & 0xfff8);
+		CFG_BASE = *iobase;
+
+		printk(KERN_INFO "TC-2550x Driver version 1.00.000 (904)\n");
+		printk(KERN_INFO "TC-2550x: IRQ = %d, I/O base = 0x%X\n", *irq, *iobase);
+		return 1;
+	}
+	return 0;
+}
+
+static void init_chip_reg(void)
+{
+	int i, val, base;
+	unsigned long tick;
+
+	outw(HALT_RISC, CONTROL_REG);
+	base = CFG_BASE + 0x20;
+	for (i = 0; i < 16; i++)
+		outw(0, base + i * 2);
+	outw(EN_TERM_PWR, STATUS_INT_REG);
+	outw(RESET_SCSI_BUS, STATUS_INT_REG);
+
+	udelay(50);		/*wait for 50 micro secs */
+
+	outw(EN_TERM_PWR, STATUS_INT_REG);
+	val = (HALT_RISC | RISC_CHIP_RESET);
+	outw(val, CONTROL_REG);
+	outw(HALT_RISC, CONTROL_REG);
+	val = inw(STATUS_INT_REG);
+	tick = 0;
+	while ((val & 0x40) == 0 && tick < 0x3fff)
+	{
+		val = inw(STATUS_INT_REG);
+		tick += 1;
+	};
+	if (tick == 0x3fff)
+		printk(KERN_DEBUG "val= %x  \n\r", val);
+	outw(EN_TERM_PWR, STATUS_INT_REG);
+	outw(0, SCSI_CONTROL);
+
+/* delay for 50 micro secs */
+	udelay(50);
+}
+
+static int download_RISC_code(void)
+{
+	unsigned short i, j, fast = 0;
+	unsigned short hi, low, base;
+	long tmp;
+	unsigned long start_time;
+
+	i = inw(CONTROL_REG);
+	if (i & 0x40)
+		fast = 1;
+	outw(HALT_RISC, CONTROL_REG);
+
+/* Ravi modified for sanity check dec 17 1998 */
+	start_time = jiffies;
+
+	do
+	{
+		if ((jiffies - start_time) > 5 * HZ)
+		{
+			printk(KERN_ERR "tc2550: Download failure.\n");
+			return 1;
+		}
+		i = inw(STATUS_INT_REG);
+	}
+	while ((i & 0x40) == 0);
+
+	outw(HALT_RISC + EN_MEMORY_WRITE, CONTROL_REG);
+	outw(EN_TERM_PWR + DIS_INTR, STATUS_INT_REG);
+
+	/*  download load RISC code
+	 */
+	outw(0, PC);
+	for (i = 0; i < ucode_size; i++)
+		outl(ucode_instruction[i], CURRENT_INST);
+	/*
+	   //  checksum checking (word)
+	 */
+	base = 0;
+	for (i = 0; i < ucode_size; i++)
+	{
+		outw(i * 4, PC);
+		tmp = inl(PROGRAM_DATA_REG);
+		hi = tmp >> 16;
+		low = (tmp & 0xffff);
+		base = base + (hi + low);
+	}
+	outw(HALT_RISC + RISC_CHIP_RESET, CONTROL_REG);
+	outw(HALT_RISC, CONTROL_REG);
+	if (fast_clk)
+		outw((HALT_RISC | FAST_CLOCK), CONTROL_REG);
+	if (par_off)
+	{
+		i = inw(CONTROL_REG);
+		outw((i | DIS_SCSI_PARITY), CONTROL_REG);
+	}
+	outw(EN_TERM_PWR, STATUS_INT_REG);
+	/*ravi
+	 */
+	if ((unsigned short) (ucode_checksum + base) != 0)
+	{
+		printk(KERN_ERR "tc2550: Checksum Error During Code Download\n");
+		return (1);
+	};
+	/*
+	   load vector table
+	 */
+	j = 0;
+	base = CFG_BASE;
+	for (i = 0, j = 0; i < 15; i++, j = j + 2)
+		outw(ucode_vector[i], (base + j));
+	outw(0, SCSI_CONTROL);
+	return (0);
+}
+
+int tc2550_detect(Scsi_Host_Template * tpnt)
+{
+	int flag = 0;
+	int retcode;
+	struct Scsi_Host *shpnt;
+	unsigned long flags;
+	unsigned int mod4;
+
+
+	flag = tc2550_pci_bios_detect(&interrupt_level, &port_base);
+	if (!flag)
+		return (0);
+
+	init_chip_reg();	/* chip Tc-2550 initialize */
+	flag = download_RISC_code();
+	if (flag == 0)
+	{
+		printk(KERN_INFO "tc2550: Successful F/W download on TC-2550x\n");
+	}
+/* now do a scsi register and get scsi host ptr */
+
+	shpnt = scsi_register(tpnt, 0);
+
+	save_flags(flags);
+	cli();
+	retcode = request_irq(interrupt_level,
+			      tc2550_intr, SA_INTERRUPT, "tripace", NULL);
+	if (retcode)
+	{
+		printk(KERN_ERR "tc2550: Unable to allocate IRQ for Tripace TC-2550x based SCSI Host Adapter.\n");
+		goto unregister;
+	}
+	/* For multiple HA we need to change all this */
+
+
+	tripace_host = shpnt;
+	shpnt->io_port = CFG_BASE;
+	shpnt->n_io_port = 0xfc;	/* Number of bytes of I/O space used */
+	shpnt->dma_channel = 0;
+	shpnt->irq = interrupt_level;
+
+	restore_flags(flags);
+
+
+	/* log i/o ports with the kernel */
+	request_region(port_base, 0xfc, "tripace");
+
+/* when we support multiple HA ,we need to modify */
+	Init_struc(0);		/* init mailboxes for one adapter */
+/* sg table init */
+
+	/*  get physical address */
+	startsgptr = (unsigned char *) table;
+	pstartsgptr = virt_to_phys((unsigned char *) table);
+	mod4 = pstartsgptr % 4;
+	if (mod4)
+	{
+		pstartsgptr += (4 - mod4);
+		startsgptr += (4 - mod4);
+	}
+	return (0);
+
+
+unregister:
+	scsi_unregister(shpnt);
+	return (0);
+}
+
+/****************************************************************************
+**   Init chip registers and allocate required memory space
+****************************************************************************/
+
+static void Init_struc(int id)
+{
+	u32 pmbx_in_base, pmbx_out_base, pdevhdr_base, ptaskq_base;
+	unsigned long paddr;
+	char *laddr;
+	unsigned short modulo;
+
+/* setup ioport address and irq */
+
+	HostAdapter[id].IoPort = (u16) CFG_BASE;
+	HostAdapter[id].IntrNum = (u8) interrupt_level;
+
+	laddr = tcmbdata;
+	paddr = virt_to_phys(tcmbdata);
+/* adjust phys address to 32 byte boundary */
+	modulo = paddr % 32;
+	if (modulo)
+	{
+		paddr = paddr + 32 - modulo;
+		laddr = laddr + 32 - modulo;
+	}
+	/*  logical address  */
+	mbx_in_base = (u32) laddr;
+	pmbx_in_base = paddr;
+	HostAdapter[id].mbx_in_base = mbx_in_base;
+
+	laddr += 32;
+	paddr += 32;
+	mbx_out_base = (u32) laddr;
+	pmbx_out_base = paddr;
+	HostAdapter[id].mbx_out_base = mbx_out_base;
+	memset((char *) mbx_in_base, 0, 48);
+
+	laddr += 32;
+	paddr += 32;
+	devhdr_base = (u32) laddr;
+	pdevhdr_base = paddr;
+	HostAdapter[id].devhdr_base = devhdr_base;
+	memset((char *) devhdr_base, 0, 512);
+
+
+	laddr += 512;
+	paddr += 512;
+
+	taskq_base = (u32) laddr;
+	ptaskq_base = paddr;
+	HostAdapter[id].taskq_base = taskq_base;
+	memset((char *) taskq_base, 0, Q_FILE_SIZE);
+
+	HostAdapter[id].ptaskq_base = (u32) ptaskq_base;
+	HostAdapter[id].pdev_base = (u32) pdevhdr_base;
+	HostAdapter[id].pmbi_base = (u32) pmbx_in_base;
+	HostAdapter[id].pmbo_base = (u32) pmbx_out_base;
+
+	outl(pmbx_in_base, MBX_IN_BASE);
+	outl(pmbx_out_base, MBX_OUT_BASE);
+	outl(pdevhdr_base, DEV_HDR_BASE);
+	outl(ptaskq_base, TASK_Q_BASE);
+	outb(0, MBX_IN_INDEX);
+	outb(0, MBX_OUT_INDEX);
+	/* clear mailbox out pointer */
+	HostAdapter[id].mbx_out_ptr = 0;
+}
+
+
+/***************************************************************************
+**   adjust bitmap position
+**   Input : old bitmap,  new bit location 
+**   Output: return with new  bitmap layout
+****************************************************************************/
+
+extern __inline__ u32 insert_bit(u32 bits, short int loc)
+{
+	u32 lo = 0;
+
+	lo = 1;
+	lo <<= loc;
+
+
+	return ((lo | bits));
+}
+
+
+/***************************************************************************
+**   Get the base address and structures of current host adapter
+**   Input  : adapter structure pointer
+**   Output : none
+****************************************************************************/
+
+static void Get_Base(Adapter * padapter)
+{
+
+	CFG_BASE = padapter->IoPort;
+	interrupt_level = (u16) padapter->IntrNum;
+	mbx_in_base = padapter->mbx_in_base;
+	mbx_out_base = padapter->mbx_out_base;
+	devhdr_base = padapter->devhdr_base;
+	taskq_base = padapter->taskq_base;
+
+}
+
+
+
+/***************************************************************************
+**  name   : search()
+**  Desc   : search an available SRB from taskQ
+**  Input  : adapter structure pointer
+**  Output : 1. a risc structure space pointer or 0 for non available
+**           2. index of task location
+****************************************************************************/
+static PRISC_SRB search(PAdapter pa)
+{
+	PRISC_SRB rsrb;
+	short int i;
+	unsigned long flags;
+
+	Get_Base(pa);
+	rsrb = (PRISC_SRB) (taskq_base + TargetID * 16 * sizeof(RISC_SRB));
+	/* check attrib in case drive doesn't support SYNC xfer */
+
+	if ((pa->dev[TargetID].attrib & DO_SYNC_NEGO) == 0)
+		ReqType = 0;
+	save_flags(flags);
+	cli();
+
+	Index = 0;
+	for (i = 0; i < 16; i++, rsrb++)
+		if (rsrb->SRB_flag == SRB_DONE)
+			break;
+	if (i == 16)
+	{
+		restore_flags(flags);
+		return (0);
+	}
+	Index = i;
+	restore_flags(flags);
+	memset((char *) rsrb, 0, 32);
+	rsrb->SRB_flag = SRB_ASSIGNED;	/* mark for use */
+	if ((pa->dev[TargetID].attrib & 0x44) == 0x44)
+		rsrb->Tag_info = 0x20;
+	return (rsrb);
+}
+
+/***************************************************************************
+**  Name   : StartSCSICmd()
+**  func   : 1. all commands passed through here are regular
+**           2. fill in device structure bitmap && start RISC
+**  Input  : risc srb structure, Index, ReqType
+**  Output : none
+****************************************************************************/
+static void StartScsiCmd(PRISC_SRB rsrb)
+{
+	DevHdr *dev;
+	u16 status;
+	PAdapter pa;
+	unsigned short val;
+	u8 t, find_id, find_last, ch = 0;
+	char *mptr;
+/* Request sense CDB */
+	char RequestSense[6] =
+	{0x03, 0x00, 0x00, 0x00, 0x0e, 0};
+
+	pa = (PAdapter) & HostAdapter[HANumber];
+	pa->dev[TargetID].task[Index].CmdInProcess = 1;		/* command in process */
+	dev = (DevHdr *) (devhdr_base + TargetID * sizeof(DevHdr));
+	dev->Srb_loc = Index;
+	dev->Request_type = ReqType;	/* set request type */
+	dev->Updatedmap = insert_bit(dev->Updatedmap, Index);
+	for (val = 0; val < 6; val++)
+		dev->SenseCmd[val] = RequestSense[val];
+	rsrb->Sense_Cmd_Ptr = virt_to_phys(&dev->SenseCmd[0]);
+
+	if (ReqType >= 2)
+	{
+		if (ReqType & 0x2)
+			dev->WideMsg = 0x1;
+		else
+		{
+/*        printf("firing sync nego");
+   //ravi 10/3/98 -ultra support in parse 
+
+   if(fast_clk)
+   dev->SyncPeriod =   period_tbl[(ultra[TargetID])].f_factor;
+   else
+   dev->SyncPeriod =   period_tbl[(ultra[TargetID])].s_factor;
+ */
+
+			if (pa->dev[TargetID].attrib & 0x1)
+				dev->SyncOffset = W_MAX_OFFSET;
+			else
+				dev->SyncOffset = MAX_OFFSET;
+		}
+	}
+	mptr = (char *) mbx_in_base;
+	find_id = 0xff;
+	find_last = 0xff;
+	for (t = 0; t < 15; t++)
+	{
+		ch = *mptr++;
+		if ((ch & 0xf) == TargetID)
+		{
+			find_id = t;
+			break;
+		}
+	}
+
+	mptr = (char *) mbx_in_base;
+	for (t = 0; t < 15; t++)
+	{
+		ch = *mptr++;
+		if (ch & 0x80)
+		{
+			find_last = t;
+			break;
+		}
+	}
+	val = inw(STATUS_INT_REG);
+	mptr = (char *) mbx_in_base;
+	if (find_id != 0xff && find_last != 0xff)
+	{
+		if (find_id < find_last)
+			*(char *) (mptr + find_id) |= 0x10;
+		else
+		{
+			*(char *) (mptr + find_last) &= 0x7f;
+			*(char *) (mptr + find_id) |= 0x90;
+		}
+	} else if (find_last != 0xff && find_id == 0xff)
+	{
+		*(char *) (mptr + find_last) &= 0x7f;
+		find_last = find_last + 1;
+		*(char *) (mptr + find_last) = (0x90 | TargetID);
+	} else if (find_last == 0xff)
+		*(char *) mptr = (0x90 | TargetID);
+
+
+	ReqType = 0;
+	/*
+	   //  restart the RISC if it is halted before
+	 */
+
+	rsrb->SRB_flag = SRB_READY;
+
+
+	if (val & RISC_HALT)
+	{
+		outw(ucode_start, PC);	/* set pc counter */
+		status = inw(CONTROL_REG);	/* clear halt status */
+		outw((status & ~HALT_RISC), CONTROL_REG);
+	}
+#ifdef DEBUG
+	printk(KERN_DEBUG " start scsi issued \n");
+#endif
+
+}
+
+static void internal_done(Scsi_Cmnd * SCpnt)
+{
+	SCpnt->SCp.Status++;
+}
+
+int tc2550_command(Scsi_Cmnd * SCpnt)
+{
+	tc2550_queue(SCpnt, internal_done);
+
+	SCpnt->SCp.Status = 0;
+	while (!SCpnt->SCp.Status)
+		barrier();
+	return SCpnt->result;
+}
+
+int tc2550_queue(Scsi_Cmnd * SCpnt, void (*done) (Scsi_Cmnd *))
+{
+
+	PAdapter pa;
+	PRISC_SRB rsrb;
+	int val;
+	struct scatterlist *sgpnt;
+
+
+	ScatGath *riscsgptr;
+
+
+	int i;
+	unsigned int nentries;
+
+	pa = (PAdapter) & HostAdapter[HANumber];
+	Get_Base(pa);
+	val = 0xaa;
+	TargetID = SCpnt->target;
+	HostID = 7;
+	/* the following code is for corel compatibility */
+	if (SCpnt->lun != 0 ||
+	    (TargetID == HostID))
+	{
+		SCpnt->result = DID_BAD_TARGET << 16;
+		done(SCpnt);
+		return (0);
+	};
+	/* Error if more than 16 tasks /target if no space is available  */
+
+	if ((rsrb = search(pa)) == 0)
+	{
+		SCpnt->result = DID_ERROR << 16;
+		done(SCpnt);
+		return (0);
+	};
+
+/*Ravi -modified for hostid 16/12/98 */
+	outb((u8) ((TargetID << 4) | HostID), SCSI_ID_REG);
+
+
+	rsrb->CDBLength = SCpnt->cmd_len;
+/* get the physical address of CDB */
+	rsrb->CDB = virt_to_phys((unsigned char *) SCpnt->cmnd);
+
+
+	if (discon)
+
+		rsrb->Identify = 0xC0;
+	else
+		rsrb->Identify = 0x80;
+
+/* scatter gather processing */
+
+	nentries = SCpnt->use_sg;
+	if (nentries == 0)
+		nentries = 1;
+	rsrb->SGNum = nentries;
+
+#ifdef DEBUG
+	printk(KERN_DEBUG "sgentries = %d\n", nentries);
+#endif
+
+/*allocate mem for scatter gather table at 32bit boundary */
+	SCpnt->host_scribble = startsgptr + 8 * MAXSGENT * MAXSRBS * TargetID;
+
+	/*(unsigned char *)scsi_malloc(4096); */
+
+	sgpnt = (struct scatterlist *) SCpnt->request_buffer;
+
+	riscsgptr = (PScatGath) (SCpnt->host_scribble);
+	if (riscsgptr == NULL)
+		panic("tripace: unable to allocate DMA memory\n");
+
+
+	/* fill physical address of scatter-gather list */
+	rsrb->SG_ListPtr = virt_to_phys(SCpnt->host_scribble);
+	rsrb->Cmd_sg_addr = virt_to_phys(rsrb + 4);
+
+	if (SCpnt->use_sg)
+	{
+		for (i = 0; i < SCpnt->use_sg; i++)
+		{
+			if (sgpnt[i].length == 0 || SCpnt->use_sg > 255)
+			{
+				unsigned char *ptr;
+				printk(KERN_ERR "tc2550: Bad segment list supplied to Tripace.c (%d, %d)\n", SCpnt->use_sg, i);
+				for (i = 0; i < SCpnt->use_sg; i++)
+				{
+					printk(KERN_ERR "%d: %x %x %d\n", i, (unsigned int) sgpnt[i].address, (unsigned int) sgpnt[i].alt_address,
+					       sgpnt[i].length);
+				};
+				printk(KERN_ERR "RISCGPTR %x: ", (unsigned int) riscsgptr);
+				ptr = (unsigned char *) &riscsgptr[i];
+				for (i = 0; i < 18; i++)
+					printk("%02x ", ptr[i]);
+				panic("Tripace tc-2550x driver!");
+			};
+
+			riscsgptr[i].sg_address = (u32) sgpnt[i].address;
+			riscsgptr[i].sg_length = sgpnt[i].length;
+		};
+	} else
+	{
+		riscsgptr[0].sg_address = (u32) SCpnt->request_buffer;
+		riscsgptr[0].sg_length = SCpnt->request_bufflen;
+	};
+
+
+/* fill sense data pointer and len */
+
+	rsrb->Sense_len = sizeof(SCpnt->sense_buffer);
+	rsrb->SenseDataPtr = virt_to_phys(SCpnt->sense_buffer);
+
+/* store scsi command pointer for use in intr routine */
+	pa->dev[TargetID].task[Index].REQ_Header = (u8 *) SCpnt;
+	SCpnt->scsi_done = done;
+
+	/* pa->dev[TargetID].task[Index].complete = CompleteIORequest; */
+	ReqType = 0;
+	StartScsiCmd(rsrb);
+	return 0;
+}
+
+int tc2550_reset(Scsi_Cmnd * SCpnt)
+{
+	return 0;
+
+}
+
+#include "sd.h"
+
+int tc2550_biosparam(Scsi_Disk * disk, int dev, int *info_array)
+{
+	return 0;
+
+}
+
+int tc2550_abort(Scsi_Cmnd * SCpnt)
+{
+
+	return 0;
+}
+
+
+const char *tc2550_info(struct Scsi_Host *ignore)
+{
+
+	return 0;
+}
+
+void tc2550_intr(int irq, struct pt_regs *regs)
+{
+	void (*my_done) (Scsi_Cmnd *) = NULL;
+
+	int val, id, map = 0, tmap, mbx_out_ptr;
+	u8 loc = 0;
+	PRISC_SRB rsrb;
+	DevHdr *dev;
+	char *ptr0;
+	PAdapter padapter;
+/* 
+   int i ;
+   unsigned long flags ;
+ */
+	unsigned int memsize;
+	Scsi_Cmnd *SCtmp;
+	unsigned devstat = 0;
+	unsigned scsistat = 0;
+	long start_time;
+
+#ifdef DEBUG
+	printk("interrupt registered \n");
+#endif
+
+/*
+   save_flags(flags);
+   cli();
+ */
+
+	/* multiple HA? not supported now! */
+	HANumber = 0;
+	padapter = (PAdapter) & HostAdapter[HANumber];
+	Get_Base(padapter);
+
+/* disable interrupts */
+	val = inw(STATUS_INT_REG);
+
+	udelay(10);
+
+	val |= 0x20;		/* clear interrupt pending */
+	outw(val, STATUS_INT_REG);
+
+	udelay(10);
+
+	val |= 0x22;		/* disable interrupt */
+
+	outw(val, STATUS_INT_REG);
+	/*               
+	   // if RISC is in halt state then find out why ?
+	 */
+	tmap = inw(STATUS_INT_REG);
+/* The following code needs to be added when we intro sync /wide nego */
+/*
+   if(tmap & RISC_HALT) {
+   tmap= risc_halt_check();
+   if(tmap) return(0xff);
+   };
+ */
+
+
+	mbx_out_ptr = padapter->mbx_out_ptr;
+
+	val = *(u16 *) (mbx_out_base + mbx_out_ptr);
+
+	while (val & 0x80)
+	{
+		loc = (char) (val & 0x7f);
+		id = val & 0xff00;
+		id >>= 8;
+		TargetID = id;
+		dev = (DevHdr *) (devhdr_base + TargetID * sizeof(DevHdr));
+		/*(u16  *)(mbx_out_base+ mbx_out_ptr)= (val& 0xff7f); */
+		rsrb = (PRISC_SRB) (taskq_base + (id * 16 + loc) * sizeof(RISC_SRB));
+		Index = loc;
+		devstat = rsrb->DEV_Status;
+		scsistat = rsrb->ScsiStatus;
+
+/*      (*padapter->dev[TargetID].task[loc].complete)(rsrb); */
+
+		*(u16 *) (mbx_out_base + mbx_out_ptr) = (val & 0xff7f);
+
+		padapter->dev[TargetID].task[loc].CmdInProcess = 0;
+		mbx_out_ptr += 2;
+		if (mbx_out_ptr == 32)
+			mbx_out_ptr = 0;
+		padapter->mbx_out_ptr = mbx_out_ptr;
+		/*
+		 *	Clear init bimap if no more tasks are waiting
+		 */
+		map = 1;
+		dev->Updatedmap = (dev->Updatedmap ^ (map << loc));
+		if ((dev->Updatedmap & 0x0000ffff) == 0)
+		{
+			ptr0 = (char *) mbx_in_base;
+			for (map = 0; map < 16; map++)
+				if ((*ptr0 & 0xf) == (char) id)
+				{
+					*ptr0 = (*ptr0 & 0xef);
+					break;
+				} else
+					ptr0++;
+		}
+		val = *(u16 *) (mbx_out_base + mbx_out_ptr);
+
+		rsrb->SRB_flag = SRB_DONE;	/* mark done */
+	}
+
+	/* stop RISC if mailbox is empty  */
+
+	ptr0 = (char *) mbx_in_base;
+	for (map = 0; map < 16; map++)
+		if (*ptr0 & 0x10)
+			break;
+	if (map == 16)
+	{
+		tmap = inw(CONTROL_REG);
+		outw((tmap | HALT_RISC), CONTROL_REG);
+
+/*Ravi modified to introduce sanity check&time out dec 16 1998 */
+
+		start_time = jiffies;
+		
+		do
+		{
+			if ((start_time - jiffies) > 5 * HZ)
+			{
+				printk(KERN_ERR "tc2550: TC-2550x Controller Failure\n");
+				return;
+			}
+			tmap = inw(STATUS_INT_REG);
+		}
+		while((tmap & RISC_HALT) == 0);
+	}
+	SCtmp = (Scsi_Cmnd *) padapter->dev[TargetID].task[loc].REQ_Header;
+
+	if (!SCtmp || !SCtmp->scsi_done)
+	{
+		printk(KERN_ERR "tc2550: Tripace_Intr_Handle: Unexpected Interrupt\n");
+		return;
+	}
+	memsize = 255 * sizeof(struct _ScatGath) + 4;
+	my_done = SCtmp->scsi_done;
+	/*if (SCtmp->host_scribble)
+	   scsi_free(SCtmp->host_scribble,4096); */
+
+
+	padapter->dev[TargetID].task[loc].REQ_Header = NULL;
+	SCtmp->result = makecode(devstat, scsistat);
+/*enable chip interrupt signal */
+	val = inw(STATUS_INT_REG);
+	udelay(25);		/* delay for 25 micros */
+
+	val &= 0xfd;		/* enable interrupt-bit1=0 in status-int reg */
+	outw(val, STATUS_INT_REG);
+
+	my_done(SCtmp);		/* inform mid layer that scsi command is over */
+/*
+   restore_flags(flags);
+ */
+
+}
+
+/* called from init/main.c */
+void tripace_setup(char *str, int *ints)
+{
+	switch (ints[0])
+	{
+
+	case 0:
+
+		printk(KERN_INFO "tc2550: No Arguments In Command Line:Assuming Defaults\n");
+		break;
+
+	case 1:
+		fast_clk = ints[1];
+		break;
+
+	case 2:
+		fast_clk = ints[1];
+		discon = ints[2];
+		break;
+
+	case 3:
+		fast_clk = ints[1];
+		discon = ints[2];
+		syncflag = ints[3];
+		break;
+
+	case 4:
+		fast_clk = ints[1];
+		discon = ints[2];
+		syncflag = ints[3];
+		tagflag = ints[4];
+	}
+
+#ifdef DEBUG
+	printk("fast_clk = %d,discon = %d,syncflag =%d,tagflag=%d\n",
+	       fast_clk, discon, syncflag, tagflag);
+	printk("fast_clk = %d,discon = %d,syncflag =%d,tagflag=%d\n",
+	       fast_clk, discon, syncflag, tagflag);
+	printk("fast_clk = %d,discon = %d,syncflag =%d,tagflag=%d\n",
+	       fast_clk, discon, syncflag, tagflag);
+	printk("fast_clk = %d,discon = %d,syncflag =%d,tagflag=%d\n",
+	       fast_clk, discon, syncflag, tagflag);
+#endif
+
+}
+
+static int makecode(unsigned hosterr, unsigned scsierr)
+{
+	switch (hosterr)
+	{
+	case 0x0:
+		hosterr = 0;
+		break;
+
+	case SEL_TIME_OUT:	/* Selection time out-The initiator selection or target
+				   reselection was not complete within the SCSI Time out period */
+		hosterr = DID_TIME_OUT;
+		break;
+
+	case ERR_PARITY:	/* parity error */
+
+		hosterr = DID_PARITY;
+		break;
+
+	case ERR_OVERRUN:	/* Data overrun/underrun-The target attempted to transfer more data
+				   than was allocated by the Data Length field or the sum of the
+				   Scatter / Gather Data Length fields. */
+
+	case ERR_BUSFREE:	/* Unexpected bus free-The target dropped the SCSI BSY at an unexpected time. */
+
+
+	case ERR_PHASE:	/* Target bus phase sequence failure-An invalid bus phase or bus
+				   phase sequence was requested by the target. */
+
+		hosterr = DID_ERROR;	/* Couldn't find any better */
+		break;
+
+	default:
+		hosterr = DID_ERROR;
+		printk(KERN_ERR "tc2550: Makecode: Unknown Hoststatus %x\n", hosterr);
+		break;
+	}
+	return scsierr | (hosterr << 16);
+}
diff -urN linux-2.0.37-pre6/drivers/scsi/tripace.h linux-2.0.37-pre7/drivers/scsi/tripace.h
--- linux-2.0.37-pre6/drivers/scsi/tripace.h	1969-12-31 16:00:00.000000000 -0800
+++ linux-2.0.37-pre7/drivers/scsi/tripace.h	2003-08-15 15:04:36.000000000 -0700
@@ -0,0 +1,57 @@
+/* tc2550.h -- Header for tripace TC-2550x PCI-SCSI HA
+ * Created:  Tue June 9 by chennai team of Tripace Ravi 
+ * Author: Ravi ravi01@md2.vsnl.net.in 
+ * Copyright 1998 Tripace B.V 
+ *
+
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License as published by the
+ * Free Software Foundation; either version 2, or (at your option) any
+ * later version.
+
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * General Public License for more details.
+
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 675 Mass Ave, Cambridge, MA 02139, USA.
+
+ */
+#define MAXSGENT  16
+
+#ifndef _TRIPACE_H
+#define _TRIPACE_H
+
+int        tc2550_detect( Scsi_Host_Template * );
+int        tc2550_command( Scsi_Cmnd * );
+int        tc2550_abort( Scsi_Cmnd * );
+const char *tc2550_info( struct Scsi_Host * );
+int        tc2550_reset( Scsi_Cmnd * ); 
+int        tc2550_queue( Scsi_Cmnd *, void (*done)(Scsi_Cmnd *) );
+int        tc2550_biosparam(Disk *,int,int *) ;
+
+#define TC2550       { NULL,                             \
+		       NULL,                             \
+		       NULL,		                 \
+		       "tripace",                        \
+		       PROC_SCSI_TRIPACE,          \
+		       NULL,				 \
+		       tc2550_detect,              \
+		       NULL,				 \
+		       tc2550_info,                \
+		       tc2550_command,             \
+		       tc2550_queue,               \
+		       tc2550_abort,               \
+		       tc2550_reset,               \
+		       NULL,                             \
+		       tc2550_biosparam,           \
+		       1, 				 \
+		       7, 				 \
+		       MAXSGENT, 				 \
+		       1, 				 \
+		       0, 				 \
+		       0, 				 \
+		       DISABLE_CLUSTERING }
+#endif
diff -urN linux-2.0.37-pre6/drivers/scsi/tripace_mcode.h linux-2.0.37-pre7/drivers/scsi/tripace_mcode.h
--- linux-2.0.37-pre6/drivers/scsi/tripace_mcode.h	1969-12-31 16:00:00.000000000 -0800
+++ linux-2.0.37-pre7/drivers/scsi/tripace_mcode.h	2003-08-15 15:04:36.000000000 -0700
@@ -0,0 +1,483 @@
+u16 ucode_vector[]      = { 
+			0x1e0,       /* vector  0 */
+                        0x0,       /* vector  1 */
+                        0x1d8,       /* vector  2 */
+                        0x500,       /* vector  3 */
+                        0x2f0,       /* vector  4 */
+                        0x2e4,       /* vector  5 */
+                        0x604,       /* vector  6 */
+                        0x258,       /* vector  7 */
+                        0x30c,       /* vector  8 */
+                        0x45c,       /* vector  9 */
+                        0x368,       /* vector 10 */
+                        0x4a4,       /* vector 11 */
+                        0x514,       /* vector 12 */
+                        0x520,       /* vector 13 */
+                        0x70c,       /* vector 14 */
+                        0x728        /* vector 15 */
+                      };
+unsigned short ucode_start         =   0x0;         /* starting point (9 bit only) */
+
+unsigned short ucode_size          =   0x1cb;       /* total number of instructions */
+unsigned short ucode_checksum      =   0x87d0;      /* checksum */         
+u32 ucode_instruction[] = { 
+			0x1c0e0078,  /* line   1 --- addr   0 */
+                        0x45800000,  /* line   2 --- addr   4 */
+                        0x08070004,  /* line   3 --- addr   8 */
+                        0x7d040000,  /* line   4 --- addr   c */
+                        0x08040000,  /* line   5 --- addr  10 */
+                        0x9c000f00,  /* line   6 --- addr  14 */
+                        0x59500000,  /* line   7 --- addr  18 */
+                        0x100e0010,  /* line   8 --- addr  1c */
+                        0xcc000000,  /* line   9 --- addr  20 */
+                        0x1c0e0078,  /* line  10 --- addr  24 */
+                        0x6500000d,  /* line  11 --- addr  28 */
+                        0x0c070041,  /* line  12 --- addr  2c */
+                        0x08030016,  /* line  13 --- addr  30 */
+                        0x9c007700,  /* line  14 --- addr  34 */
+                        0x6100000d,  /* line  15 --- addr  38 */
+                        0x78000004,  /* line  16 --- addr  3c */
+                        0x7c000000,  /* line  17 --- addr  40 */
+                        0xdc000100,  /* line  18 --- addr  44 */
+                        0x60000008,  /* line  19 --- addr  48 */
+                        0x6500000f,  /* line  20 --- addr  4c */
+                        0x59700000,  /* line  21 --- addr  50 */
+                        0x3000002a,  /* line  22 --- addr  54 */
+                        0x9c000700,  /* line  23 --- addr  58 */
+                        0x3c00001a,  /* line  24 --- addr  5c */
+                        0xa000000e,  /* line  25 --- addr  60 */
+                        0x38000148,  /* line  26 --- addr  64 */
+                        0x18070021,  /* line  27 --- addr  68 */
+                        0x65000019,  /* line  28 --- addr  6c */
+                        0x9c000f00,  /* line  29 --- addr  70 */
+                        0x59700000,  /* line  30 --- addr  74 */
+                        0x1c0e0078,  /* line  31 --- addr  78 */
+                        0xc8000000,  /* line  32 --- addr  7c */
+                        0x30000145,  /* line  33 --- addr  80 */
+                        0x6500000c,  /* line  34 --- addr  84 */
+                        0x59700000,  /* line  35 --- addr  88 */
+                        0x38000030,  /* line  36 --- addr  8c */
+                        0x64000004,  /* line  37 --- addr  90 */
+                        0x94000000,  /* line  38 --- addr  94 */
+                        0xa0000000,  /* line  39 --- addr  98 */
+                        0x3c008043,  /* line  40 --- addr  9c */
+                        0x60000008,  /* line  41 --- addr  a0 */
+                        0x78000004,  /* line  42 --- addr  a4 */
+                        0x64000008,  /* line  43 --- addr  a8 */
+                        0x3c008041,  /* line  44 --- addr  ac */
+                        0x0800003d,  /* line  45 --- addr  b0 */
+                        0xf8000000,  /* line  46 --- addr  b4 */
+                        0x60000008,  /* line  47 --- addr  b8 */
+                        0x6170000c,  /* line  48 --- addr  bc */
+                        0x6500000d,  /* line  49 --- addr  c0 */
+                        0x0c070041,  /* line  50 --- addr  c4 */
+                        0x9c000700,  /* line  51 --- addr  c8 */
+                        0x38000148,  /* line  52 --- addr  cc */
+                        0x59070000,  /* line  53 --- addr  d0 */
+                        0x1c0e0078,  /* line  54 --- addr  d4 */
+                        0xc8000000,  /* line  55 --- addr  d8 */
+                        0x1c0e0078,  /* line  56 --- addr  dc */
+                        0x6d000001,  /* line  57 --- addr  e0 */
+                        0x0800003f,  /* line  58 --- addr  e4 */
+                        0x6c200004,  /* line  59 --- addr  e8 */
+                        0x6c300008,  /* line  60 --- addr  ec */
+                        0x30000067,  /* line  61 --- addr  f0 */
+                        0xf8000000,  /* line  62 --- addr  f4 */
+                        0x60000008,  /* line  63 --- addr  f8 */
+                        0xdc700100,  /* line  64 --- addr  fc */
+                        0x3000002a,  /* line  65 --- addr 100 */
+                        0x7c000000,  /* line  66 --- addr 104 */
+                        0x6100000c,  /* line  67 --- addr 108 */
+                        0x78000004,  /* line  68 --- addr 10c */
+                        0x30000000,  /* line  69 --- addr 110 */
+                        0xc0000000,  /* line  70 --- addr 114 */
+                        0xc0000000,  /* line  71 --- addr 118 */
+                        0xc0000000,  /* line  72 --- addr 11c */
+                        0xc0000000,  /* line  73 --- addr 120 */
+                        0xc0000000,  /* line  74 --- addr 124 */
+                        0xc0000000,  /* line  75 --- addr 128 */
+                        0xc0000000,  /* line  76 --- addr 12c */
+                        0x1c060183,  /* line  77 --- addr 130 */
+                        0x4d000000,  /* line  78 --- addr 134 */
+                        0x0c07004d,  /* line  79 --- addr 138 */
+                        0x59070000,  /* line  80 --- addr 13c */
+                        0x8c008000,  /* line  81 --- addr 140 */
+                        0x49800000,  /* line  82 --- addr 144 */
+                        0x6d000001,  /* line  83 --- addr 148 */
+                        0x59700000,  /* line  84 --- addr 14c */
+                        0x71000401,  /* line  85 --- addr 150 */
+                        0x59050000,  /* line  86 --- addr 154 */
+                        0x49800000,  /* line  87 --- addr 158 */
+                        0xb0000000,  /* line  88 --- addr 15c */
+                        0xb0050000,  /* line  89 --- addr 160 */
+                        0x1801005d,  /* line  90 --- addr 164 */
+                        0x65000010,  /* line  91 --- addr 168 */
+                        0xc0000000,  /* line  92 --- addr 16c */
+                        0x61000010,  /* line  93 --- addr 170 */
+                        0x59070000,  /* line  94 --- addr 174 */
+                        0x61000012,  /* line  95 --- addr 178 */
+                        0x0c010064,  /* line  96 --- addr 17c */
+                        0xfb000000,  /* line  97 --- addr 180 */
+                        0xfa000000,  /* line  98 --- addr 184 */
+                        0x6570000c,  /* line  99 --- addr 188 */
+                        0x30000030,  /* line 100 --- addr 18c */
+                        0xfb000000,  /* line 101 --- addr 190 */
+                        0xfe000000,  /* line 102 --- addr 194 */
+                        0x30000000,  /* line 103 --- addr 198 */
+                        0xb0000000,  /* line 104 --- addr 19c */
+                        0xfb000000,  /* line 105 --- addr 1a0 */
+                        0xf9000002,  /* line 106 --- addr 1a4 */
+                        0xd1001018,  /* line 107 --- addr 1a8 */
+                        0x65000012,  /* line 108 --- addr 1ac */
+                        0xdc000100,  /* line 109 --- addr 1b0 */
+                        0x9c000f00,  /* line 110 --- addr 1b4 */
+                        0x80000018,  /* line 111 --- addr 1b8 */
+                        0x61000012,  /* line 112 --- addr 1bc */
+                        0xd1001018,  /* line 113 --- addr 1c0 */
+                        0x18010140,  /* line 114 --- addr 1c4 */
+                        0xd1000110,  /* line 115 --- addr 1c8 */
+                        0x380f0140,  /* line 116 --- addr 1cc */
+                        0xb4000000,  /* line 117 --- addr 1d0 */
+                        0x30000140,  /* line 118 --- addr 1d4 */
+                        0x71001102,  /* line 119 --- addr 1d8 */
+                        0x3000004c,  /* line 120 --- addr 1dc */
+                        0xb0020000,  /* line 121 --- addr 1e0 */
+                        0x2c00707a,  /* line 122 --- addr 1e4 */
+                        0x59040080,  /* line 123 --- addr 1e8 */
+                        0xcc000000,  /* line 124 --- addr 1ec */
+                        0x2c00707f,  /* line 125 --- addr 1f0 */
+                        0x6500000c,  /* line 126 --- addr 1f4 */
+                        0x3000008b,  /* line 127 --- addr 1f8 */
+                        0x59040080,  /* line 128 --- addr 1fc */
+                        0x3c200089,  /* line 129 --- addr 200 */
+                        0x3c200089,  /* line 130 --- addr 204 */
+                        0x3c200089,  /* line 131 --- addr 208 */
+                        0x3c200089,  /* line 132 --- addr 20c */
+                        0x3c200089,  /* line 133 --- addr 210 */
+                        0x3c200089,  /* line 134 --- addr 214 */
+                        0x3c210089,  /* line 135 --- addr 218 */
+                        0x3c220089,  /* line 136 --- addr 21c */
+                        0x3000007c,  /* line 137 --- addr 220 */
+                        0x2c00708a,  /* line 138 --- addr 224 */
+                        0x59040080,  /* line 139 --- addr 228 */
+                        0x59700000,  /* line 140 --- addr 22c */
+                        0xc8000000,  /* line 141 --- addr 230 */
+                        0x6c100014,  /* line 142 --- addr 234 */
+                        0x2c002091,  /* line 143 --- addr 238 */
+                        0xb0080000,  /* line 144 --- addr 23c */
+                        0xb0080000,  /* line 145 --- addr 240 */
+                        0x54000000,  /* line 146 --- addr 244 */
+                        0x30000140,  /* line 147 --- addr 248 */
+                        0x54000000,  /* line 148 --- addr 24c */
+                        0x6c100014,  /* line 149 --- addr 250 */
+                        0x30000140,  /* line 150 --- addr 254 */
+                        0x65000015,  /* line 151 --- addr 258 */
+                        0xdc000100,  /* line 152 --- addr 25c */
+                        0x9c000f00,  /* line 153 --- addr 260 */
+                        0x80000018,  /* line 154 --- addr 264 */
+                        0x61000015,  /* line 155 --- addr 268 */
+                        0xd1001018,  /* line 156 --- addr 26c */
+                        0xf0000345,  /* line 157 --- addr 270 */
+                        0x6d000018,  /* line 158 --- addr 274 */
+                        0xc0000000,  /* line 159 --- addr 278 */
+                        0x3c0000a4,  /* line 160 --- addr 27c */
+                        0x69000018,  /* line 161 --- addr 280 */
+                        0x6810001c,  /* line 162 --- addr 284 */
+                        0x54000000,  /* line 163 --- addr 288 */
+                        0x30000096,  /* line 164 --- addr 28c */
+                        0x180500a4,  /* line 165 --- addr 290 */
+                        0x2c006129,  /* line 166 --- addr 294 */
+                        0x2c0070da,  /* line 167 --- addr 298 */
+                        0x180b00ac,  /* line 168 --- addr 29c */
+                        0x280000ac,  /* line 169 --- addr 2a0 */
+                        0x1c0900ac,  /* line 170 --- addr 2a4 */
+                        0xf1000645,  /* line 171 --- addr 2a8 */
+                        0x28000140,  /* line 172 --- addr 2ac */
+                        0x280020b2,  /* line 173 --- addr 2b0 */
+                        0x7c000000,  /* line 174 --- addr 2b4 */
+                        0x59040080,  /* line 175 --- addr 2b8 */
+                        0x2c0020ae,  /* line 176 --- addr 2bc */
+                        0x2c0020ae,  /* line 177 --- addr 2c0 */
+                        0x300000a4,  /* line 178 --- addr 2c4 */
+                        0x280000b8,  /* line 179 --- addr 2c8 */
+                        0x7c000000,  /* line 180 --- addr 2cc */
+                        0x59400080,  /* line 181 --- addr 2d0 */
+                        0x2c0000b4,  /* line 182 --- addr 2d4 */
+                        0x2c0000b4,  /* line 183 --- addr 2d8 */
+                        0x300000a4,  /* line 184 --- addr 2dc */
+                        0x30000140,  /* line 185 --- addr 2e0 */
+                        0x1c0200c1,  /* line 186 --- addr 2e4 */
+                        0x1c0c00bc,  /* line 187 --- addr 2e8 */
+                        0x30000181,  /* line 188 --- addr 2ec */
+                        0xb4030000,  /* line 189 --- addr 2f0 */
+                        0x71000502,  /* line 190 --- addr 2f4 */
+                        0x280050be,  /* line 191 --- addr 2f8 */
+                        0x74400680,  /* line 192 --- addr 2fc */
+                        0x3000004c,  /* line 193 --- addr 300 */
+                        0x71001302,  /* line 194 --- addr 304 */
+                        0x3000004c,  /* line 195 --- addr 308 */
+                        0x65000014,  /* line 196 --- addr 30c */
+                        0xdc000100,  /* line 197 --- addr 310 */
+                        0x9c000f00,  /* line 198 --- addr 314 */
+                        0x80000018,  /* line 199 --- addr 318 */
+                        0x61000014,  /* line 200 --- addr 31c */
+                        0xd1001018,  /* line 201 --- addr 320 */
+                        0xf0000545,  /* line 202 --- addr 324 */
+                        0x2c0040ca,  /* line 203 --- addr 328 */
+                        0x180700cf,  /* line 204 --- addr 32c */
+                        0x6c20000c,  /* line 205 --- addr 330 */
+                        0x6c30001b,  /* line 206 --- addr 334 */
+                        0x30000140,  /* line 207 --- addr 338 */
+                        0x6d000001,  /* line 208 --- addr 33c */
+                        0x9c00fe00,  /* line 209 --- addr 340 */
+                        0x69000001,  /* line 210 --- addr 344 */
+                        0x7c000000,  /* line 211 --- addr 348 */
+                        0xb8000000,  /* line 212 --- addr 34c */
+                        0x80000004,  /* line 213 --- addr 350 */
+                        0x60000004,  /* line 214 --- addr 354 */
+                        0x6c100014,  /* line 215 --- addr 358 */
+                        0x6810001c,  /* line 216 --- addr 35c */
+                        0x54000000,  /* line 217 --- addr 360 */
+                        0x28007140,  /* line 218 --- addr 364 */
+                        0x65000017,  /* line 219 --- addr 368 */
+                        0xdc000100,  /* line 220 --- addr 36c */
+                        0x9c000f00,  /* line 221 --- addr 370 */
+                        0x80000018,  /* line 222 --- addr 374 */
+                        0x61000017,  /* line 223 --- addr 378 */
+                        0xd1001018,  /* line 224 --- addr 37c */
+                        0x59040000,  /* line 225 --- addr 380 */
+                        0x3c000114,  /* line 226 --- addr 384 */
+                        0x3c040104,  /* line 227 --- addr 388 */
+                        0x3c0200ed,  /* line 228 --- addr 38c */
+                        0x3c0700e8,  /* line 229 --- addr 390 */
+                        0x3c0100f6,  /* line 230 --- addr 394 */
+                        0x3c2300ef,  /* line 231 --- addr 398 */
+                        0x3c0800ed,  /* line 232 --- addr 39c */
+                        0xb4030000,  /* line 233 --- addr 3a0 */
+                        0xb0050000,  /* line 234 --- addr 3a4 */
+                        0x2c0070ea,  /* line 235 --- addr 3a8 */
+                        0x28005181,  /* line 236 --- addr 3ac */
+                        0x30000140,  /* line 237 --- addr 3b0 */
+                        0xb0050000,  /* line 238 --- addr 3b4 */
+                        0x30000140,  /* line 239 --- addr 3b8 */
+                        0xb0050000,  /* line 240 --- addr 3bc */
+                        0x28007181,  /* line 241 --- addr 3c0 */
+                        0x59040080,  /* line 242 --- addr 3c4 */
+                        0xb4060000,  /* line 243 --- addr 3c8 */
+                        0x28006140,  /* line 244 --- addr 3cc */
+                        0xb0060000,  /* line 245 --- addr 3d0 */
+                        0x30000140,  /* line 246 --- addr 3d4 */
+                        0xb0050000,  /* line 247 --- addr 3d8 */
+                        0x2c0070f8,  /* line 248 --- addr 3dc */
+                        0x59040080,  /* line 249 --- addr 3e0 */
+                        0x3c0200ff,  /* line 250 --- addr 3e4 */
+                        0x3c0300fd,  /* line 251 --- addr 3e8 */
+                        0x2c0070fc,  /* line 252 --- addr 3ec */
+                        0x59040080,  /* line 253 --- addr 3f0 */
+                        0x2c0070fe,  /* line 254 --- addr 3f4 */
+                        0x59040080,  /* line 255 --- addr 3f8 */
+                        0x2c007100,  /* line 256 --- addr 3fc */
+                        0x59040080,  /* line 257 --- addr 400 */
+                        0x2c007102,  /* line 258 --- addr 404 */
+                        0x59040040,  /* line 259 --- addr 408 */
+                        0x300000e8,  /* line 260 --- addr 40c */
+                        0x180a010a,  /* line 261 --- addr 410 */
+                        0x18060108,  /* line 262 --- addr 414 */
+                        0xb0060000,  /* line 263 --- addr 418 */
+                        0x3000010a,  /* line 264 --- addr 41c */
+                        0x1c0b010a,  /* line 265 --- addr 420 */
+                        0xb0080000,  /* line 266 --- addr 424 */
+                        0x1c01010c,  /* line 267 --- addr 428 */
+                        0xb4000000,  /* line 268 --- addr 42c */
+                        0xb0050000,  /* line 269 --- addr 430 */
+                        0x6c10001c,  /* line 270 --- addr 434 */
+                        0x68100014,  /* line 271 --- addr 438 */
+                        0x50000000,  /* line 272 --- addr 43c */
+                        0x6570000c,  /* line 273 --- addr 440 */
+                        0xfb000000,  /* line 274 --- addr 444 */
+                        0x1c010030,  /* line 275 --- addr 448 */
+                        0x30000000,  /* line 276 --- addr 44c */
+                        0x1807004c,  /* line 277 --- addr 450 */
+                        0xb0050000,  /* line 278 --- addr 454 */
+                        0x30000145,  /* line 279 --- addr 458 */
+                        0x65000013,  /* line 280 --- addr 45c */
+                        0xdc000100,  /* line 281 --- addr 460 */
+                        0x9c000f00,  /* line 282 --- addr 464 */
+                        0x80000018,  /* line 283 --- addr 468 */
+                        0x61000013,  /* line 284 --- addr 46c */
+                        0xd1001018,  /* line 285 --- addr 470 */
+                        0x6d000099,  /* line 286 --- addr 474 */
+                        0x18070120,  /* line 287 --- addr 478 */
+                        0x9c00bf00,  /* line 288 --- addr 47c */
+                        0x1c010123,  /* line 289 --- addr 480 */
+                        0x59400080,  /* line 290 --- addr 484 */
+                        0x30000140,  /* line 291 --- addr 488 */
+                        0x594000c0,  /* line 292 --- addr 48c */
+                        0x2c005125,  /* line 293 --- addr 490 */
+                        0x6d4000c0,  /* line 294 --- addr 494 */
+                        0x2c005127,  /* line 295 --- addr 498 */
+                        0x59470080,  /* line 296 --- addr 49c */
+                        0x30000140,  /* line 297 --- addr 4a0 */
+                        0x65000016,  /* line 298 --- addr 4a4 */
+                        0xdc000100,  /* line 299 --- addr 4a8 */
+                        0x9c000f00,  /* line 300 --- addr 4ac */
+                        0x80000018,  /* line 301 --- addr 4b0 */
+                        0x61000016,  /* line 302 --- addr 4b4 */
+                        0xd1001018,  /* line 303 --- addr 4b8 */
+                        0x59040080,  /* line 304 --- addr 4bc */
+                        0x1c07013e,  /* line 305 --- addr 4c0 */
+                        0x69000003,  /* line 306 --- addr 4c4 */
+                        0x3802013e,  /* line 307 --- addr 4c8 */
+                        0xb4070000,  /* line 308 --- addr 4cc */
+                        0x71000402,  /* line 309 --- addr 4d0 */
+                        0x61700019,  /* line 310 --- addr 4d4 */
+                        0x6d00001a,  /* line 311 --- addr 4d8 */
+                        0x6100001b,  /* line 312 --- addr 4dc */
+                        0x6d00001b,  /* line 313 --- addr 4e0 */
+                        0x6100001e,  /* line 314 --- addr 4e4 */
+                        0x38000140,  /* line 315 --- addr 4e8 */
+                        0x6500000d,  /* line 316 --- addr 4ec */
+                        0x8c008000,  /* line 317 --- addr 4f0 */
+                        0x6100000d,  /* line 318 --- addr 4f4 */
+                        0xb0070000,  /* line 319 --- addr 4f8 */
+                        0x2c00613f,  /* line 320 --- addr 4fc */
+                        0x20204778,  /* line 321 --- addr 500 */
+                        0x18050141,  /* line 322 --- addr 504 */
+                        0x205769ab,  /* line 323 --- addr 508 */
+                        0x107e00c0,  /* line 324 --- addr 50c */
+                        0x30000140,  /* line 325 --- addr 510 */
+                        0x6c200010,  /* line 326 --- addr 514 */
+                        0x74300600,  /* line 327 --- addr 518 */
+                        0x30000067,  /* line 328 --- addr 51c */
+                        0x6500000f,  /* line 329 --- addr 520 */
+                        0x59700000,  /* line 330 --- addr 524 */
+                        0xc8000000,  /* line 331 --- addr 528 */
+                        0x1c0e0078,  /* line 332 --- addr 52c */
+                        0x6500000d,  /* line 333 --- addr 530 */
+                        0x0c0001b6,  /* line 334 --- addr 534 */
+                        0x6c200004,  /* line 335 --- addr 538 */
+                        0x6c300008,  /* line 336 --- addr 53c */
+                        0x0c010153,  /* line 337 --- addr 540 */
+                        0x0c020185,  /* line 338 --- addr 544 */
+                        0x30000000,  /* line 339 --- addr 548 */
+                        0xb4060000,  /* line 340 --- addr 54c */
+                        0xf9000002,  /* line 341 --- addr 550 */
+                        0x28005181,  /* line 342 --- addr 554 */
+                        0x65000013,  /* line 343 --- addr 558 */
+                        0x2c005158,  /* line 344 --- addr 55c */
+                        0x6d4000d9,  /* line 345 --- addr 560 */
+                        0x2c00515a,  /* line 346 --- addr 564 */
+                        0x744001c0,  /* line 347 --- addr 568 */
+                        0x2c00515c,  /* line 348 --- addr 56c */
+                        0x744002c0,  /* line 349 --- addr 570 */
+                        0x2c00515e,  /* line 350 --- addr 574 */
+                        0x744003c0,  /* line 351 --- addr 578 */
+                        0x2c005160,  /* line 352 --- addr 57c */
+                        0x59400080,  /* line 353 --- addr 580 */
+                        0x2800717f,  /* line 354 --- addr 584 */
+                        0x59040080,  /* line 355 --- addr 588 */
+                        0x3c07017d,  /* line 356 --- addr 58c */
+                        0x380100e1,  /* line 357 --- addr 590 */
+                        0x28007181,  /* line 358 --- addr 594 */
+                        0x59040080,  /* line 359 --- addr 598 */
+                        0x38020179,  /* line 360 --- addr 59c */
+                        0x28007181,  /* line 361 --- addr 5a0 */
+                        0x59040080,  /* line 362 --- addr 5a4 */
+                        0x38030179,  /* line 363 --- addr 5a8 */
+                        0x28007181,  /* line 364 --- addr 5ac */
+                        0x59040000,  /* line 365 --- addr 5b0 */
+                        0x61000016,  /* line 366 --- addr 5b4 */
+                        0x71000d02,  /* line 367 --- addr 5b8 */
+                        0x6500000d,  /* line 368 --- addr 5bc */
+                        0x08020175,  /* line 369 --- addr 5c0 */
+                        0xb4030000,  /* line 370 --- addr 5c4 */
+                        0xb0050000,  /* line 371 --- addr 5c8 */
+                        0xfe000000,  /* line 372 --- addr 5cc */
+                        0x30000189,  /* line 373 --- addr 5d0 */
+                        0xb0050000,  /* line 374 --- addr 5d4 */
+                        0xb0060000,  /* line 375 --- addr 5d8 */
+                        0xfe000000,  /* line 376 --- addr 5dc */
+                        0x30000140,  /* line 377 --- addr 5e0 */
+                        0x71000702,  /* line 378 --- addr 5e4 */
+                        0x28007176,  /* line 379 --- addr 5e8 */
+                        0x59040080,  /* line 380 --- addr 5ec */
+                        0x3000017a,  /* line 381 --- addr 5f0 */
+                        0x71000c02,  /* line 382 --- addr 5f4 */
+                        0x30000176,  /* line 383 --- addr 5f8 */
+                        0x71000b02,  /* line 384 --- addr 5fc */
+                        0x30000176,  /* line 385 --- addr 600 */
+                        0x71001402,  /* line 386 --- addr 604 */
+                        0x30000140,  /* line 387 --- addr 608 */
+                        0x6c200004,  /* line 388 --- addr 60c */
+                        0x6c300008,  /* line 389 --- addr 610 */
+                        0x74400000,  /* line 390 --- addr 614 */
+                        0xf9000002,  /* line 391 --- addr 618 */
+                        0x28005181,  /* line 392 --- addr 61c */
+                        0x6d4000d9,  /* line 393 --- addr 620 */
+                        0x2c00518d,  /* line 394 --- addr 624 */
+                        0x2c00518d,  /* line 395 --- addr 628 */
+                        0x300001b2,  /* line 396 --- addr 62c */
+                        0x28005140,  /* line 397 --- addr 630 */
+                        0xb0060000,  /* line 398 --- addr 634 */
+                        0x744001c0,  /* line 399 --- addr 638 */
+                        0x2c005190,  /* line 400 --- addr 63c */
+                        0x744003c0,  /* line 401 --- addr 640 */
+                        0x2c005192,  /* line 402 --- addr 644 */
+                        0x744001c0,  /* line 403 --- addr 648 */
+                        0x65000014,  /* line 404 --- addr 64c */
+                        0x2c005195,  /* line 405 --- addr 650 */
+                        0x594000c0,  /* line 406 --- addr 654 */
+                        0x65000015,  /* line 407 --- addr 658 */
+                        0x2c005198,  /* line 408 --- addr 65c */
+                        0x59400080,  /* line 409 --- addr 660 */
+                        0x280071b4,  /* line 410 --- addr 664 */
+                        0x59040080,  /* line 411 --- addr 668 */
+                        0x3c0701b2,  /* line 412 --- addr 66c */
+                        0x380100e1,  /* line 413 --- addr 670 */
+                        0x28007181,  /* line 414 --- addr 674 */
+                        0x59040080,  /* line 415 --- addr 678 */
+                        0x38030179,  /* line 416 --- addr 67c */
+                        0x28007181,  /* line 417 --- addr 680 */
+                        0x59040080,  /* line 418 --- addr 684 */
+                        0x38010179,  /* line 419 --- addr 688 */
+                        0x28007181,  /* line 420 --- addr 68c */
+                        0x59040080,  /* line 421 --- addr 690 */
+                        0x61000017,  /* line 422 --- addr 694 */
+                        0x28007181,  /* line 423 --- addr 698 */
+                        0x59040080,  /* line 424 --- addr 69c */
+                        0x61000018,  /* line 425 --- addr 6a0 */
+                        0x71000a02,  /* line 426 --- addr 6a4 */
+                        0x30000176,  /* line 427 --- addr 6a8 */
+                        0xc0000000,  /* line 428 --- addr 6ac */
+                        0xc0000000,  /* line 429 --- addr 6b0 */
+                        0xc0000000,  /* line 430 --- addr 6b4 */
+                        0xc0000000,  /* line 431 --- addr 6b8 */
+                        0xc0000000,  /* line 432 --- addr 6bc */
+                        0xc0000000,  /* line 433 --- addr 6c0 */
+                        0xc0000000,  /* line 434 --- addr 6c4 */
+                        0x71000902,  /* line 435 --- addr 6c8 */
+                        0x30000176,  /* line 436 --- addr 6cc */
+                        0x71000802,  /* line 437 --- addr 6d0 */
+                        0x30000176,  /* line 438 --- addr 6d4 */
+                        0xa000000e,  /* line 439 --- addr 6d8 */
+                        0x08000000,  /* line 440 --- addr 6dc */
+                        0x74400000,  /* line 441 --- addr 6e0 */
+                        0xf90000d2,  /* line 442 --- addr 6e4 */
+                        0x28005181,  /* line 443 --- addr 6e8 */
+                        0x6d400084,  /* line 444 --- addr 6ec */
+                        0x7900000c,  /* line 445 --- addr 6f0 */
+                        0x7d000000,  /* line 446 --- addr 6f4 */
+                        0xdc000100,  /* line 447 --- addr 6f8 */
+                        0x6100000e,  /* line 448 --- addr 6fc */
+                        0x1801004c,  /* line 449 --- addr 700 */
+                        0xd1000110,  /* line 450 --- addr 704 */
+                        0x3000004c,  /* line 451 --- addr 708 */
+                        0xf90000ef,  /* line 452 --- addr 70c */
+                        0xfe000000,  /* line 453 --- addr 710 */
+                        0x280051c5,  /* line 454 --- addr 714 */
+                        0x180501c5,  /* line 455 --- addr 718 */
+                        0x74400680,  /* line 456 --- addr 71c */
+                        0xfb000000,  /* line 457 --- addr 720 */
+                        0xfe000000,  /* line 458 --- addr 724 */
+                        0xfe000000   /* line 459 --- addr 728 */
+                      };
diff -urN linux-2.0.37-pre6/drivers/scsi/TRIPACE.REL linux-2.0.37-pre7/drivers/scsi/TRIPACE.REL
--- linux-2.0.37-pre6/drivers/scsi/TRIPACE.REL	1969-12-31 16:00:00.000000000 -0800
+++ linux-2.0.37-pre7/drivers/scsi/TRIPACE.REL	2003-08-15 15:04:36.000000000 -0700
@@ -0,0 +1,21 @@
+Dated December 21 Chennai,India:-
+----- -------- -----------------
+
+
+Release Notes of 1.00.000 (904) version:-
+
+1.0 All machine dependent timing loops have been removed and
+    replaced with the udelay function.
+
+2.0 Search function has been made static
+
+3.0 Search function ,in case of failure was not reenabling interrupts
+    This has been corrected.
+
+4.0 The save_flags,cli & restore_flags in ISR has been removed.
+
+5.0 Wait_risc_halt has a sanity check and times out incase hw failure.
+
+6.0 Source code indentation with "indent -kr -i8 -bl -bli0 tripace.c"
+
+
diff -urN linux-2.0.37-pre6/drivers/sound/Config.in linux-2.0.37-pre7/drivers/sound/Config.in
--- linux-2.0.37-pre6/drivers/sound/Config.in	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/drivers/sound/Config.in	1997-09-05 20:43:58.000000000 -0700
@@ -1,251 +1,15 @@
-bool 'ProAudioSpectrum 16 support' CONFIG_PAS
-bool 'Sound Blaster (SB, SBPro, SB16, clones) support' CONFIG_SB
-bool 'Generic OPL2/OPL3 FM synthesizer support' CONFIG_ADLIB
-bool 'Gravis Ultrasound support' CONFIG_GUS
-bool 'MPU-401 support (NOT for SB16)' CONFIG_MPU401
-bool '6850 UART Midi support' CONFIG_UART6850
-bool 'PSS (ECHO-ADI2111) support' CONFIG_PSS
-bool '16 bit sampling option of GUS (_NOT_ GUS MAX)' CONFIG_GUS16
-bool 'GUS MAX support' CONFIG_GUSMAX
-bool 'Microsoft Sound System support' CONFIG_MSS
-bool 'Ensoniq SoundScape support' CONFIG_SSCAPE
-bool 'MediaTrix AudioTrix Pro support' CONFIG_TRIX
-bool 'Support for MAD16 and/or Mozart based cards' CONFIG_MAD16
-bool 'Support for Crystal CS4232 based (PnP) cards' CONFIG_CS4232
-bool 'Support for Turtle Beach Wave Front (Maui, Tropez) synthesizers' CONFIG_MAUI
-bool '/dev/dsp and /dev/audio support' CONFIG_AUDIO
-bool 'MIDI interface support' CONFIG_MIDI
-bool 'FM synthesizer (YM3812/OPL-3) support' CONFIG_YM3812
-
-if [ "$CONFIG_SB" = "y" ]; then
-hex 'I/O base for SB Check from manual of the card' SBC_BASE 220
-fi
-
-if [ "$CONFIG_SB" = "y" ]; then
-int 'Sound Blaster IRQ Check from manual of the card' SBC_IRQ 7
-fi
-
-if [ "$CONFIG_SB" = "y" ]; then
-int 'Sound Blaster DMA 0, 1 or 3' SBC_DMA 1
-fi
-
-if [ "$CONFIG_SB" = "y" ]; then
-int 'Sound Blaster 16 bit DMA (_REQUIRED_for SB16, Jazz16, SMW) 5, 6 or 7 (use 1 for 8 bit cards)' SB_DMA2 5
-fi
-
-if [ "$CONFIG_SB" = "y" ]; then
-hex 'MPU401 I/O base of SB16, Jazz16 and ES1688 Check from manual of the card' SB_MPU_BASE 0
-fi
-
-if [ "$CONFIG_SB" = "y" ]; then
-int 'SB MPU401 IRQ (Jazz16, SM Wave and ES1688) Use -1 with SB16' SB_MPU_IRQ -1
-fi
-
-if [ "$CONFIG_PAS" = "y" ]; then
-int 'PAS16 IRQ 3, 4, 5, 7, 9, 10, 11, 12, 14 or 15' PAS_IRQ 10
-fi
-
-if [ "$CONFIG_PAS" = "y" ]; then
-int 'PAS16 DMA 0, 1, 3, 5, 6 or 7' PAS_DMA 3
-fi
-
-if [ "$CONFIG_GUS" = "y" ]; then
-hex 'I/O base for GUS 210, 220, 230, 240, 250 or 260' GUS_BASE 220
-fi
-
-if [ "$CONFIG_GUS" = "y" ]; then
-int 'GUS IRQ 3, 5, 7, 9, 11, 12 or 15' GUS_IRQ 15
-fi
-
-if [ "$CONFIG_GUS" = "y" ]; then
-int 'GUS DMA 1, 3, 5, 6 or 7' GUS_DMA 6
-fi
-
-if [ "$CONFIG_GUS" = "y" ]; then
-int 'Second DMA channel for GUS 1, 3, 5, 6 or 7' GUS_DMA2 -1
-fi
-
-if [ "$CONFIG_GUS16" = "y" ]; then
-hex 'I/O base for the 16 bit daughtercard of GUS 530, 604, E80 or F40' GUS16_BASE 530
-fi
-
-if [ "$CONFIG_GUS16" = "y" ]; then
-int 'GUS 16 bit daughtercard IRQ 3, 4, 5, 7, or 9' GUS16_IRQ 7
-fi
-
-if [ "$CONFIG_GUS16" = "y" ]; then
-int 'GUS DMA 0, 1 or 3' GUS16_DMA 3
-fi
-
-if [ "$CONFIG_MPU401" = "y" ]; then
-hex 'I/O base for MPU401 Check from manual of the card' MPU_BASE 330
-fi
-
-if [ "$CONFIG_MPU401" = "y" ]; then
-int 'MPU401 IRQ Check from manual of the card' MPU_IRQ 9
-fi
-
-if [ "$CONFIG_MAUI" = "y" ]; then
-hex 'I/O base for Maui 210, 230, 260, 290, 300, 320, 338 or 330' MAUI_BASE 330
-fi
-
-if [ "$CONFIG_MAUI" = "y" ]; then
-int 'Maui IRQ 5, 9, 12 or 15' MAUI_IRQ 9
-fi
-
-if [ "$CONFIG_UART6850" = "y" ]; then
-hex 'I/O base for UART 6850 MIDI port (Unknown)' U6850_BASE 0
-fi
-
-if [ "$CONFIG_UART6850" = "y" ]; then
-int 'UART6850 IRQ (Unknown)' U6850_IRQ -1
-fi
-
-if [ "$CONFIG_PSS" = "y" ]; then
-hex 'PSS I/O base 220 or 240' PSS_BASE 220
-fi
-
-if [ "$CONFIG_PSS" = "y" ]; then
-hex 'PSS audio I/O base 530, 604, E80 or F40' PSS_MSS_BASE 530
-fi
-
-if [ "$CONFIG_PSS" = "y" ]; then
-int 'PSS audio IRQ 7, 9, 10 or 11' PSS_MSS_IRQ 11
-fi
-
-if [ "$CONFIG_PSS" = "y" ]; then
-int 'PSS audio DMA 0, 1 or 3' PSS_MSS_DMA 3
-fi
-
-if [ "$CONFIG_PSS" = "y" ]; then
-hex 'PSS MIDI I/O base ' PSS_MPU_BASE 330
-fi
-
-if [ "$CONFIG_PSS" = "y" ]; then
-int 'PSS MIDI IRQ 3, 4, 5, 7 or 9' PSS_MPU_IRQ 9
-fi
-
-if [ "$CONFIG_MSS" = "y" ]; then
-hex 'MSS/WSS I/O base 530, 604, E80 or F40' MSS_BASE 530
-fi
-
-if [ "$CONFIG_MSS" = "y" ]; then
-int 'MSS/WSS IRQ 7, 9, 10 or 11' MSS_IRQ 11
-fi
-
-if [ "$CONFIG_MSS" = "y" ]; then
-int 'MSS/WSS DMA 0, 1 or 3' MSS_DMA 3
-fi
-
-if [ "$CONFIG_SSCAPE" = "y" ]; then
-hex 'SoundScape MIDI I/O base 320, 330, 340 or 350' SSCAPE_BASE 330
-fi
-
-if [ "$CONFIG_SSCAPE" = "y" ]; then
-int 'SoundScape MIDI IRQ ' SSCAPE_IRQ 9
-fi
-
-if [ "$CONFIG_SSCAPE" = "y" ]; then
-int 'SoundScape initialization DMA 0, 1 or 3' SSCAPE_DMA 3
-fi
-
-if [ "$CONFIG_SSCAPE" = "y" ]; then
-hex 'SoundScape audio I/O base 534, 608, E84 or F44' SSCAPE_MSS_BASE 534
-fi
-
-if [ "$CONFIG_SSCAPE" = "y" ]; then
-int 'SoundScape audio IRQ 7, 9, 10 or 11' SSCAPE_MSS_IRQ 11
-fi
-
-if [ "$CONFIG_TRIX" = "y" ]; then
-hex 'AudioTrix audio I/O base 530, 604, E80 or F40' TRIX_BASE 530
-fi
-
-if [ "$CONFIG_TRIX" = "y" ]; then
-int 'AudioTrix audio IRQ 7, 9, 10 or 11' TRIX_IRQ 11
-fi
-
-if [ "$CONFIG_TRIX" = "y" ]; then
-int 'AudioTrix audio DMA 0, 1 or 3' TRIX_DMA 0
-fi
-
-if [ "$CONFIG_TRIX" = "y" ]; then
-int 'AudioTrix second (duplex) DMA 0, 1 or 3' TRIX_DMA2 3
-fi
-
-if [ "$CONFIG_TRIX" = "y" ]; then
-hex 'AudioTrix MIDI I/O base 330, 370, 3B0 or 3F0' TRIX_MPU_BASE 330
-fi
-
-if [ "$CONFIG_TRIX" = "y" ]; then
-int 'AudioTrix MIDI IRQ 3, 4, 5, 7 or 9' TRIX_MPU_IRQ 9
-fi
-
-if [ "$CONFIG_TRIX" = "y" ]; then
-hex 'AudioTrix SB I/O base 220, 210, 230, 240, 250, 260 or 270' TRIX_SB_BASE 220
-fi
-
-if [ "$CONFIG_TRIX" = "y" ]; then
-int 'AudioTrix SB IRQ 3, 4, 5 or 7' TRIX_SB_IRQ 7
-fi
-
-if [ "$CONFIG_TRIX" = "y" ]; then
-int 'AudioTrix SB DMA 1 or 3' TRIX_SB_DMA 1
-fi
-
-if [ "$CONFIG_CS4232" = "y" ]; then
-hex 'CS4232 audio I/O base 530, 604, E80 or F40' CS4232_BASE 530
-fi
-
-if [ "$CONFIG_CS4232" = "y" ]; then
-int 'CS4232 audio IRQ 5, 7, 9, 11, 12 or 15' CS4232_IRQ 11
-fi
-
-if [ "$CONFIG_CS4232" = "y" ]; then
-int 'CS4232 audio DMA 0, 1 or 3' CS4232_DMA 0
-fi
-
-if [ "$CONFIG_CS4232" = "y" ]; then
-int 'CS4232 second (duplex) DMA 0, 1 or 3' CS4232_DMA2 3
-fi
-
-if [ "$CONFIG_CS4232" = "y" ]; then
-hex 'CS4232 MIDI I/O base 330, 370, 3B0 or 3F0' CS4232_MPU_BASE 330
-fi
-
-if [ "$CONFIG_CS4232" = "y" ]; then
-int 'CS4232 MIDI IRQ 5, 7, 9, 11, 12 or 15' CS4232_MPU_IRQ 9
-fi
-
-if [ "$CONFIG_MAD16" = "y" ]; then
-hex 'MAD16 audio I/O base 530, 604, E80 or F40' MAD16_BASE 530
-fi
-
-if [ "$CONFIG_MAD16" = "y" ]; then
-int 'MAD16 audio IRQ 7, 9, 10 or 11' MAD16_IRQ 11
-fi
-
-if [ "$CONFIG_MAD16" = "y" ]; then
-int 'MAD16 audio DMA 0, 1 or 3' MAD16_DMA 3
-fi
-
-if [ "$CONFIG_MAD16" = "y" ]; then
-int 'MAD16 second (duplex) DMA 0, 1 or 3' MAD16_DMA2 0
-fi
-
-if [ "$CONFIG_MAD16" = "y" ]; then
-hex 'MAD16 MIDI I/O base 300, 310, 320 or 330 (0 disables)' MAD16_MPU_BASE 330
-fi
-
-if [ "$CONFIG_MAD16" = "y" ]; then
-int 'MAD16 MIDI IRQ 5, 7, 9 or 10' MAD16_MPU_IRQ 9
-fi
-
-if [ "$CONFIG_AUDIO" = "y" ]; then
-int 'Audio DMA buffer size 4096, 16384, 32768 or 65536' DSP_BUFFSIZE 65536
-fi
 #
-$MAKE -C drivers/sound kernelconfig || exit 1
+# Sound driver configuration
+#
+#--------
+# There is another config script which is compatible with rest of
+# the kernel. It can be activated by running 'make mkscript' in this
+# directory. Please note that this is an _experimental_ feature which
+# doesn't work with all cards (PSS, SM Wave, AudioTrix Pro, Maui).
+#--------
+#
+$MAKE -C drivers/sound config || exit 1
+
 bool 'Additional low level drivers' CONFIG_LOWLEVEL_SOUND
 
 if [ "$CONFIG_LOWLEVEL_SOUND" = "y" ]; then
diff -urN linux-2.0.37-pre6/fs/autofs/root.c linux-2.0.37-pre7/fs/autofs/root.c
--- linux-2.0.37-pre6/fs/autofs/root.c	1997-09-05 20:43:59.000000000 -0700
+++ linux-2.0.37-pre7/fs/autofs/root.c	2003-08-15 15:04:36.000000000 -0700
@@ -108,6 +108,10 @@
 	*result = NULL;
 	if (!dir)
 		return -ENOENT;
+		
+	if (len > NAME_MAX)
+		return -ENOENT;
+		
 	if (!S_ISDIR(dir->i_mode)) {
 		iput(dir);
 		return -ENOTDIR;
@@ -194,6 +198,9 @@
 		iput(dir);
 		return -EPERM;
 	}
+	if ( len > NAME_MAX)
+		return -ENAMETOOLONG;
+		
 	if ( autofs_hash_lookup(dh,hash,name,len) ) {
 		iput(dir);
 		return -EEXIST;
@@ -252,6 +259,9 @@
 
 	if ( !autofs_oz_mode(sbi) )
 		return -EPERM;
+		
+	if(len > NAME_MAX)
+		return -ENAMETOOLONG;
 
 	ent = autofs_hash_lookup(dh,hash,name,len);
 	if ( !ent )
diff -urN linux-2.0.37-pre6/include/linux/fd.h linux-2.0.37-pre7/include/linux/fd.h
--- linux-2.0.37-pre6/include/linux/fd.h	1996-04-28 08:47:40.000000000 -0700
+++ linux-2.0.37-pre7/include/linux/fd.h	2003-08-15 15:04:36.000000000 -0700
@@ -215,7 +215,7 @@
 	/* Prevent "aliased" accesses. */
 	int fd_ref;
 	int fd_device;
-	int last_checked; /* when was the drive last checked for a disk 
+	unsigned long last_checked; /* when was the drive last checked for a disk 
 			   * change? */
 	
 	char *dmabuf;
diff -urN linux-2.0.37-pre6/include/linux/proc_fs.h linux-2.0.37-pre7/include/linux/proc_fs.h
--- linux-2.0.37-pre6/include/linux/proc_fs.h	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/include/linux/proc_fs.h	2003-08-15 15:04:36.000000000 -0700
@@ -143,6 +143,7 @@
 	PROC_SCSI_NCR53C406A,
 	PROC_SCSI_SYM53C416,
 	PROC_SCSI_MEGARAID,
+	PROC_SCSI_INIA100,
 	PROC_SCSI_PPA,
 	PROC_SCSI_ATP870U,
 	PROC_SCSI_ESP,
diff -urN linux-2.0.37-pre6/include/linux/wireless.h linux-2.0.37-pre7/include/linux/wireless.h
--- linux-2.0.37-pre6/include/linux/wireless.h	1998-11-15 10:33:19.000000000 -0800
+++ linux-2.0.37-pre7/include/linux/wireless.h	2003-08-15 15:04:37.000000000 -0700
@@ -1,7 +1,7 @@
 /*
  * This file define a set of standard wireless extensions
  *
- * Version :	4	12.2.97
+ * Version :	6	18.2.99
  *
  * Authors :	Jean Tourrilhes - HPLB - <jt@hplb.hpl.hp.com>
  */
@@ -63,7 +63,7 @@
  * (there is some stuff that will be added in the future...)
  * I just plan to increment with each new version.
  */
-#define WIRELESS_EXT	5
+#define WIRELESS_EXT	6
 
 /*
  * Changes :
@@ -82,6 +82,10 @@
  * --------
  *	- Missing encoding definitions in range
  *	- Access points stuff
+ *
+ * V5 to V6
+ * --------
+ *	- 802.11 support
  */
 
 /* -------------------------- IOCTL LIST -------------------------- */
@@ -113,11 +117,19 @@
 #define SIOCGIWAP	0x8B15		/* get access point hardware addresses */
 #define SIOCGIWAPLIST	0x8B17		/* get list of access point in range */
 
+/* 802.11 specific support */
+#define SIOCSIWESSID	0x8B1A		/* set ESSID (network name) */
+#define SIOCGIWESSID	0x8B1B		/* get ESSID */
+/* As the ESSID is a string up to 32 bytes long, it doesn't fit within the
+ * 'iwreq' structure, so we need to use the 'data' member to point to a
+ * string in user space, like it is done for RANGE...
+ */
+
 /* ------------------------- IOCTL STUFF ------------------------- */
 
 /* The first and the last (range) */
 #define SIOCIWFIRST	0x8B00
-#define SIOCIWLAST	0x8B17
+#define SIOCIWLAST	0x8B1B
 
 /* Even : get (world access), odd : set (root access) */
 #define IW_IS_SET(cmd)	(!((cmd) & 0x1))
diff -urN linux-2.0.37-pre6/include/net/ip_masq.h linux-2.0.37-pre7/include/net/ip_masq.h
--- linux-2.0.37-pre6/include/net/ip_masq.h	1997-12-02 14:20:39.000000000 -0800
+++ linux-2.0.37-pre7/include/net/ip_masq.h	2003-08-15 15:04:37.000000000 -0700
@@ -84,6 +84,14 @@
 	void		*app_data;	/* Application private data */
 	unsigned  flags;        	/* status flags */
 	struct ip_masq	*control;	/* Corresponding control connection */
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+        struct ip_masq  *d_link;	/* hashed link ptr */
+	__u32		ospi, ispi;	/* outbound and inbound SPI keys for IPSEC */
+                                        /* also the cookie for ISAKMP masq (maybe) */
+	short		ocnt;		/* counter of inits sent - limit blocking  */
+        short           blocking;       /* if we're blocking another host */
+
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
 };
 
 /*
diff -urN linux-2.0.37-pre6/MAINTAINERS linux-2.0.37-pre7/MAINTAINERS
--- linux-2.0.37-pre6/MAINTAINERS	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/MAINTAINERS	2003-08-15 15:04:36.000000000 -0700
@@ -182,12 +182,6 @@
 L:	linux-raid@vger.rutgers.edu
 S:	Maintained
 
-COMPAQ SMART2 RAID DRIVER
-P:	Chris Frantz
-M:	Chris Frantz <arrays@compaq.com>
-L:	linux-raid@vger.rutgers.edu
-S:	Maintained
-
 EATA ISA/EISA/PCI SCSI DRIVER
 P:	Dario Ballabio
 M:	dario@milano.europe.dg.com
diff -urN linux-2.0.37-pre6/net/bridge/br.c linux-2.0.37-pre7/net/bridge/br.c
--- linux-2.0.37-pre6/net/bridge/br.c	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/net/bridge/br.c	2003-08-15 15:04:37.000000000 -0700
@@ -91,6 +91,8 @@
 
 void transmit_config(int port_no)			  /* (4.6.1)	 */
 {
+	if(!(br_stats.flags & BR_UP))
+		return; /* this should not happen but happens */
 	if (hold_timer[port_no].active) {	  /* (4.6.1.3.1)	 */
 		port_info[port_no].config_pending = TRUE;	/* (4.6.1.3.1)	 */
 	} else {				  /* (4.6.1.3.2)	 */
@@ -875,6 +877,8 @@
 	struct device *dev = port_info[port_no].dev;
 	int size;
 	
+	if(!(br_stats.flags & BR_UP))
+		return(-1); /* this should not happen but happens */
 	if (port_info[port_no].state == Disabled) {
 		printk(KERN_DEBUG "send_config_bpdu: port %i not valid\n",port_no);
 		return(-1);
@@ -930,6 +934,8 @@
 	struct device *dev = port_info[port_no].dev;
 	int size;
 	
+	if(!(br_stats.flags & BR_UP))
+		return(-1); /* this should not happen but happens */
 	if (port_info[port_no].state == Disabled) {
 		printk(KERN_DEBUG "send_tcn_bpdu: port %i not valid\n",port_no);
 		return(-1);
diff -urN linux-2.0.37-pre6/net/ipv4/arp.c linux-2.0.37-pre7/net/ipv4/arp.c
--- linux-2.0.37-pre6/net/ipv4/arp.c	1998-11-15 10:33:21.000000000 -0800
+++ linux-2.0.37-pre7/net/ipv4/arp.c	2003-08-15 15:04:37.000000000 -0700
@@ -1784,13 +1784,15 @@
  *	is not from an IP number.  We can't currently handle this, so toss
  *	it. 
  */  
-#ifdef CONFIG_FDDI
-	if (dev->type == ARPHRD_FDDI)
+#if defined(CONFIG_NET_ETHERNET) || defined(CONFIG_FDDI)
+	if (dev->type == ARPHRD_ETHER || dev->type == ARPHRD_FDDI)
 	{
 		/*
 		 * According to RFC 1390, FDDI devices should accept ARP hardware types
 		 * of 1 (Ethernet).  However, to be more robust, we'll accept hardware
 		 * types of either 1 (Ethernet) or 6 (IEEE 802.2).
+		 *
+		 * ETHERNET devices will accept both hardware types, too. (RFC 1042)
 		 */
 		if (arp->ar_hln != dev->addr_len    || 
 			((ntohs(arp->ar_hrd) != ARPHRD_ETHER) && (ntohs(arp->ar_hrd) != ARPHRD_IEEE802)) ||
diff -urN linux-2.0.37-pre6/net/ipv4/Config.in linux-2.0.37-pre7/net/ipv4/Config.in
--- linux-2.0.37-pre6/net/ipv4/Config.in	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/net/ipv4/Config.in	2003-08-15 15:04:37.000000000 -0700
@@ -19,7 +19,18 @@
           bool 'IP: MS PPTP client masq support (EXPERIMENTAL)' CONFIG_IP_MASQUERADE_PPTP
           if [ "$CONFIG_IP_MASQUERADE_PPTP" = "y" ]; then	
             bool 'IP: MS PPTP masq debugging' DEBUG_IP_MASQUERADE_PPTP
-          fi
+            if [ "$DEBUG_IP_MASQUERADE_PPTP" = "y" ]; then	
+              bool 'IP: MS PPTP masq verbose debugging' DEBUG_IP_MASQUERADE_PPTP_VERBOSE
+            fi
+         fi
+         bool 'IP: IPSEC ESP & ISAKMP masq support (EXPERIMENTAL)' CONFIG_IP_MASQUERADE_IPSEC
+         if [ "$CONFIG_IP_MASQUERADE_IPSEC" = "y" ]; then	
+           int 'IP: IPSEC masq table lifetime (minutes)' CONFIG_IP_MASQUERADE_IPSEC_EXPIRE 30
+           bool 'IP: IPSEC masq debugging' DEBUG_IP_MASQUERADE_IPSEC
+           if [ "$DEBUG_IP_MASQUERADE_IPSEC" = "y" ]; then	
+             bool 'IP: IPSEC masq verbose debugging' DEBUG_IP_MASQUERADE_IPSEC_VERBOSE
+           fi
+         fi
         fi
         bool 'IP: ICMP masquerading' CONFIG_IP_MASQUERADE_ICMP
       fi
diff -urN linux-2.0.37-pre6/net/ipv4/ip_masq.c linux-2.0.37-pre7/net/ipv4/ip_masq.c
--- linux-2.0.37-pre6/net/ipv4/ip_masq.c	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/net/ipv4/ip_masq.c	2003-08-15 15:04:37.000000000 -0700
@@ -20,6 +20,7 @@
  *	Delian Delchev		:	Added support for ICMP requests and replys
  *	Nigel Metheringham	:	ICMP in ICMP handling, tidy ups, bug fixes, made ICMP optional
  *	Juan Jose Ciarlante	:	re-assign maddr if no packet received from outside
+ * 	John D. Hardin		:	Added PPTP and IPSEC protocols
  *	
  */
 
@@ -45,29 +46,65 @@
 
 #define IP_MASQ_TAB_SIZE 256    /* must be power of 2 */
 
+#define IPPROTO_GRE	47	/* GRE Encapsulation used by PPTP */
 
+#ifdef CONFIG_IP_MASQUERADE_PPTP
 /*
- * to turn it on, of course
-*/
-#define CONFIG_IP_MASQUERADE_PPTP 1
+ * This is clumsier than it otherwise might be (i.e. the
+ * PPTP control channel sniffer should be a module, and there
+ * should be a separate table for GRE masq entries so that
+ * we're not making all of the hacks to the TCP table code)
+ # but I wanted to keep the code changes localized to one file
+ # if possible.
+ * This should all be modular, and the table routines need to
+ * be somewhat more generic.
+ *
+ * Maybe for 2.0.38 - we'll see.
+ */
+
+static const char *strGREProt = "GRE";
+
+#ifdef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
 /*
-*/
+ * MULTICLIENT watches the control channel and preloads the
+ * call ID into the masq table entry, so we want the
+ * masq table entry to persist until a Call Disconnect
+ * occurs, otherwise the call IDs will be lost and the link broken.
+ */
+#define MASQUERADE_EXPIRE_PPTP 15*60*HZ
+
+/*
+ * To support multiple clients communicating with the same server,
+ * we have to sniff the control channel and trap the client's
+ * call ID, then substitute a unique-to-the-firewall call ID.
+ * Then on inbound GRE packets we use the bogus call ID to figure
+ * out which client to route the traffic to, then replace the
+ * bogus call ID with the client's real call ID, which we've saved.
+ * For simplicity we'll use masq port as the bogus call ID.
+ * The actual call ID will be stored in the masq table as
+ * the source port, and the destination port will always be zero.
+ *
+ * NB: PPTP servers can tell whether the client is masqueraded by
+ * looking for call IDs above 61000.
+ */
+#define PPTP_CONTROL_PORT 1723
 
+#else /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
 
-#ifdef CONFIG_IP_MASQUERADE_PPTP
+/* non-MULTICLIENT ignores call IDs, so masq table
+ * entries may expire quickly without causing problems.
+ */
+#define MASQUERADE_EXPIRE_PPTP 5*60*HZ
 
-/*
- * try these if you're having problems...
-#define DEBUG_IP_MASQUERADE_PPTP 1
-#define DEBUG_IP_MASQUERADE_VERBOSE 1
-*/
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
 
 /*
  * Define this here rather than in /usr/src/linux/include/wherever/whatever.h
  * in order to localize my mistakes to one file...
+ *
+ * This struct may be architecture-specific because of the bitmaps.
  */
-
-struct grehdr {
+struct pptp_gre_header {
         __u8
                 recur:3,
                 is_strict:1,
@@ -79,14 +116,81 @@
                 version:3,
                 flags:5;
         __u16   
-                protocol;
+                protocol,
+                payload_len,
+                call_id;        /* peer's call_id for this session */
+
 };
 
+#endif /* CONFIG_IP_MASQUERADE_PPTP */
+
 
-#define IPPROTO_GRE	47	/* GRE Encapsulation used by Microsoft PPTP */
-static const char *strGREProt = "GRE";
+#define IPPROTO_ESP	50	/* ESP protocol for IPSEC */
+#define IPPROTO_AH 	51	/* AH protocol for IPSEC */
 
-#endif /* CONFIG_IP_MASQUERADE_PPTP */
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+/*
+ * The above comments about PPTP apply here, too. This should all be a module.
+ *
+ * The "port numbers" for masq table purposes will be part of the
+ * SPI, just to gain a little benefit from the hashing.
+ */
+
+static const char *strESPProt = "ESP";
+static const char *strAHProt = "AH";
+
+/*
+ * ISAKMP uses 500/udp, and the traffic must come from
+ * 500/udp (i.e. 500/udp <-> 500/udp), so we need to
+ * check for ISAKMP UDP traffic and avoid changing the
+ * source port number. In order to associate the data streams
+ * we may need to sniff the ISAKMP cookies as well.
+ */
+#define UDP_PORT_ISAKMP	500	/* ISAKMP default UDP port */
+
+#if CONFIG_IP_MASQUERADE_IPSEC_EXPIRE > 15
+#define MASQUERADE_EXPIRE_IPSEC CONFIG_IP_MASQUERADE_IPSEC_EXPIRE*60*HZ
+#else
+#define MASQUERADE_EXPIRE_IPSEC 15*60*HZ
+#endif
+
+/*
+ * We can't know the inbound SPI until it comes in (the ISAKMP exchange
+ * is encryptd so we can't sniff it out of that), so we associate inbound
+ * and outbound traffic by inspection. If somebody sends a new packet to a
+ * remote server, then block all other new traffic to that server until we
+ * get a response from that server with a SPI we haven't seen yet. It is
+ * assumed that this is the correct response - we have no way to verify it,
+ * as everything else is encrypted.
+ *
+ * If there is a collision, the block will last for up to two minutes (or
+ * whatever MASQUERADE_EXPIRE_IPSEC_INIT is set to), and if the client
+ * retries during that time the timer will be reset. This could easily lead
+ * to a Denial of Service, so we limit the number of retries that will
+ * reset the timer. This means the maximum time the server could be blocked
+ * is ((IPSEC_INIT_RETRIES + 1) * MASQUERADE_EXPIRE_IPSEC_INIT).
+ *
+ * Note: blocking will not affect already-established traffic (i.e. where
+ * the inbound SPI has been associated with an outbound SPI).
+ */
+#define MASQUERADE_EXPIRE_IPSEC_INIT 2*60*HZ
+#define IPSEC_INIT_RETRIES 5
+
+/*
+ * ...connections that don't get an answer are squelched
+ * (recognized but ignored) for a short time to prevent DoS.
+ * SPI values 1-255 are reserved by the IANA and are currently (2/99)
+ * not assigned. If that should change, this number must also be changed
+ * to an unused NONZERO value:
+ */
+#define IPSEC_INIT_SQUELCHED 1
+
+struct ip_masq * ip_masq_out_get_ipsec(int protocol, __u32 s_addr, __u16 s_port, __u32 d_addr, __u16 d_port, __u32 o_spi);
+struct ip_masq * ip_masq_in_get_ipsec(int protocol, __u32 s_addr, __u16 s_port, __u32 d_addr, __u16 d_port, __u32 i_spi);
+struct ip_masq * ip_masq_out_get_isakmp(int protocol, __u32 s_addr, __u16 s_port, __u32 d_addr, __u16 d_port, __u32 cookie);
+struct ip_masq * ip_masq_in_get_isakmp(int protocol, __u32 s_addr, __u16 s_port, __u32 d_addr, __u16 d_port, __u32 cookie);
+
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
 
 /*
  *	Implement IP packet masquerading
@@ -97,7 +201,7 @@
 /*
  * masq_proto_num returns 0 for UDP, 1 for TCP, 2 for ICMP
  *
- * No, I am NOT going to add GRE support to everything that relies on this...
+ * No, I am NOT going to add GRE/ESP/AH support to everything that relies on this...
  *
  */
 
@@ -106,10 +210,13 @@
    switch (proto)
    {
       case IPPROTO_UDP:  return (0); break;
-      case IPPROTO_TCP:  return (1); break;
 #ifdef CONFIG_IP_MASQUERADE_PPTP
-      case IPPROTO_GRE:  return (1); break;	/* steal a few TCP ports */
+      case IPPROTO_GRE:
 #endif /* CONFIG_IP_MASQUERADE_PPTP */
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+      case IPPROTO_ESP:
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
+      case IPPROTO_TCP:  return (1); break;
       case IPPROTO_ICMP: return (2); break;
       default:           return (-1); break;
    }
@@ -145,19 +252,24 @@
 
 static __inline__ const char *masq_proto_name(unsigned proto)
 {
-#ifdef CONFIG_IP_MASQUERADE_PPTP
+
 	/*
-	 * Yes, I know this sucks for efficiency and is ugly.
 	 * I don't want to track down everything that
-	 * relies on masq_proto_num() and make it GRE-tolerant.
-	 * The number of sites running this patch will probably be small,
-	 * and hopefully the 2.1/2.2 kernel will support masquerading of
-	 * arbitrary IP protocols (or at least GRE).
+	 * relies on masq_proto_num() and make it GRE/ESP/AH-tolerant.
 	 */
+#ifdef CONFIG_IP_MASQUERADE_PPTP
 	if (proto == IPPROTO_GRE) {
           return strGREProt;
 	}
 #endif /* CONFIG_IP_MASQUERADE_PPTP */
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+	if (proto == IPPROTO_ESP) {
+          return strESPProt;
+	} else if (proto == IPPROTO_AH) {
+          return strAHProt;
+	}
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
+
         return strProt[masq_proto_num(proto)];
 }
 
@@ -202,6 +314,14 @@
 struct ip_masq *ip_masq_m_tab[IP_MASQ_TAB_SIZE];
 struct ip_masq *ip_masq_s_tab[IP_MASQ_TAB_SIZE];
 
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+	/*
+	 * Add a third hash table for input lookup by remote side
+	 */
+struct ip_masq *ip_masq_d_tab[IP_MASQ_TAB_SIZE];
+
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
+
 /*
  * timeouts
  */
@@ -343,30 +463,29 @@
         ms->m_link = ip_masq_m_tab[hash];
         ip_masq_m_tab[hash] = ms;
 
-#ifdef DEBUG_IP_MASQUERADE_PPTP
-	printk("MASQ: hashed %d %08X:%04hX->%08X:%04hX into in\n",
-	       ms->protocol,
-	       ms->saddr,
-	       ms->sport,
-	       ms->maddr,
-	       ms->mport);
-#endif /* DEBUG_IP_MASQUERADE_PPTP */
-
         /*
          *	Hash by proto,s{addr,port}
          */
+#ifdef CONFIG_IP_MASQUERADE_PPTP
+	if (ms->protocol == IPPROTO_GRE) {
+                /* Ignore the source port (Call ID) when hashing, as
+                 * outbound packets will not be able to supply it...
+                 */
+                hash = ip_masq_hash_key(ms->protocol, ms->saddr, 0);
+        } else
+#endif /* CONFIG_IP_MASQUERADE_PPTP */
         hash = ip_masq_hash_key(ms->protocol, ms->saddr, ms->sport);
         ms->s_link = ip_masq_s_tab[hash];
         ip_masq_s_tab[hash] = ms;
 
-#ifdef DEBUG_IP_MASQUERADE_PPTP
-	printk("MASQ: hashed %d %08X:%04hX->%08X:%04hX into out\n",
-	       ms->protocol,
-	       ms->saddr,
-	       ms->sport,
-	       ms->daddr,
-	       ms->dport);
-#endif /* DEBUG_IP_MASQUERADE_PPTP */
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+        /* 
+          * Hash by proto,d{addr,port}
+          */
+        hash = ip_masq_hash_key(ms->protocol, ms->daddr, ms->dport);
+	ms->d_link = ip_masq_d_tab[hash];
+	ip_masq_d_tab[hash] = ms;
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
 
         ms->flags |= IP_MASQ_F_HASHED;
         return 1;
@@ -398,6 +517,11 @@
         /*
          *	UNhash by s{addr,port}
          */
+#ifdef CONFIG_IP_MASQUERADE_PPTP
+	if (ms->protocol == IPPROTO_GRE) {
+                hash = ip_masq_hash_key(ms->protocol, ms->saddr, 0);
+        } else
+#endif /* CONFIG_IP_MASQUERADE_PPTP */
         hash = ip_masq_hash_key(ms->protocol, ms->saddr, ms->sport);
         for (ms_p = &ip_masq_s_tab[hash]; *ms_p ; ms_p = &(*ms_p)->s_link)
                 if (ms == (*ms_p))  {
@@ -405,6 +529,18 @@
                         break;
                 }
 
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+	/* 
+	 * UNhash by d{addr,port}
+	 */
+	hash = ip_masq_hash_key(ms->protocol, ms->daddr, ms->dport);
+	for (ms_p = &ip_masq_d_tab[hash]; *ms_p ; ms_p = &(*ms_p)->d_link)
+		if (ms == (*ms_p))  {
+			*ms_p = ms->d_link;
+			break;
+		}
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
+
         ms->flags &= ~IP_MASQ_F_HASHED;
         return 1;
 }
@@ -427,6 +563,9 @@
         int protocol;
         __u32 s_addr, d_addr;
         __u16 s_port, d_port;
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+        __u32 cookie;
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
 
  	portptr = (__u16 *)&(((char *)iph)[iph->ihl*4]);
         protocol = iph->protocol;
@@ -435,14 +574,12 @@
         d_addr = iph->daddr;
         d_port = portptr[1];
 
-#ifdef CONFIG_IP_MASQUERADE_PPTP
-/*
- *	Allow for GRE portlessness...
- */
-	if (protocol == IPPROTO_GRE) {
-	  s_port = d_port = 0;
-	}
-#endif /* CONFIG_IP_MASQUERADE_PPTP */
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+        if (protocol == IPPROTO_UDP && ntohs(s_port) == UDP_PORT_ISAKMP && ntohs(d_port) == UDP_PORT_ISAKMP) {
+                cookie = *((__u32 *)&portptr[4]);
+                return ip_masq_in_get_isakmp(protocol, s_addr, s_port, d_addr, d_port, cookie);
+        } else
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
 
         return ip_masq_in_get_2(protocol, s_addr, s_port, d_addr, d_port);
 }
@@ -490,34 +627,156 @@
         }
 
 #ifdef CONFIG_IP_MASQUERADE_PPTP
+	if (protocol == IPPROTO_GRE) {
+                for(ms = ip_masq_m_tab[hash]; ms ; ms = ms->m_link) {
+                        if (protocol==ms->protocol &&
+#ifdef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+                            ms->mport == d_port && /* ignore source port */
+#else /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
+                            ms->mport == 0 && ms->sport == 0 &&
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
+                            s_addr==ms->daddr && d_addr==ms->maddr) {
+#ifdef DEBUG_IP_MASQUERADE_PPTP_VERBOSE
+                                printk(KERN_DEBUG "MASQ: look/in %d %08X:%04hX->%08X:%04hX OK\n",
+                                       protocol,
+                                       s_addr,
+                                       s_port,
+                                       d_addr,
+                                       d_port);
+#endif /* DEBUG_IP_MASQUERADE_PPTP_VERBOSE */
+                                return ms;
+                        }
+		}
+        }
+#endif /* CONFIG_IP_MASQUERADE_PPTP */
+
+
+#ifdef DEBUG_IP_MASQUERADE_VERBOSE
+	printk("MASQ: look/in %d %08X:%04hX->%08X:%04hX fail\n",
+	       protocol,
+	       s_addr,
+	       s_port,
+	       d_addr,
+	       d_port);
+#endif
+        return NULL;
+}
+
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+struct ip_masq *
+ip_masq_in_get_ipsec(int protocol, __u32 s_addr, __u16 s_port, __u32 d_addr, __u16 d_port, __u32 i_spi)
+{
+        unsigned hash;
+        struct ip_masq *ms;
+
+        if (protocol != IPPROTO_ESP) {
+                return ip_masq_in_get_2(protocol,s_addr,s_port,d_addr,d_port);
+        }
+
+        /* find an entry for a packet coming in from outside,
+         * or find whether there's a setup pending
+         */
+
+        if (i_spi != 0) {
+                /* there's a SPI - look for a completed entry */
+                hash = ip_masq_hash_key(protocol, s_addr, s_port);
+                for(ms = ip_masq_d_tab[hash]; ms ; ms = ms->d_link) {
+                        if (protocol==ms->protocol &&
+                            s_addr==ms->daddr &&
+                            d_addr==ms->maddr &&
+                            ms->ispi != 0 && i_spi==ms->ispi) {
+#ifdef DEBUG_IP_MASQUERADE_IPSEC_VERBOSE
+                                printk(KERN_DEBUG "MASQ: IPSEC look/in %08X->%08X:%08X OK\n",
+                                       s_addr,
+                                       d_addr,
+                                       i_spi);
+#endif
+                                return ms;
+                        }
+                }
+        }
+        
+        /* no joy. look for a pending connection - maybe somebody else's
+         * if we're checking for a pending setup, the d_addr will be zero
+         * to avoid having to know the masq IP.
+         */
+        hash = ip_masq_hash_key(protocol, s_addr, 0);
+        for(ms = ip_masq_d_tab[hash]; ms ; ms = ms->d_link) {
+                if (protocol==ms->protocol &&
+                    s_addr==ms->daddr &&
+                    (d_addr==0 || d_addr==ms->maddr) &&
+                    ms->ispi==0) {
+#ifdef DEBUG_IP_MASQUERADE_IPSEC_VERBOSE
+                        printk(KERN_DEBUG "MASQ: IPSEC look/in %08X->%08X:0 OK\n",
+                               s_addr,
+                               d_addr
+                               );
+#endif
+                        return ms;
+                }
+        }
+
+#ifdef DEBUG_IP_MASQUERADE_IPSEC_VERBOSE
+	printk(KERN_DEBUG "MASQ: IPSEC look/in %08X->%08X:%08X fail\n",
+	       s_addr,
+	       d_addr,
+	       i_spi);
+#endif
+        return NULL;
+}
+
+struct ip_masq *
+ip_masq_in_get_isakmp(int protocol, __u32 s_addr, __u16 s_port, __u32 d_addr, __u16 d_port, __u32 cookie)
+{
+        unsigned hash;
+        struct ip_masq *ms;
+
+#ifdef DEBUG_IP_MASQUERADE_IPSEC
+	printk(KERN_DEBUG "ip_masq_in_get_isakmp(): ");
+	printk("%s -> ", in_ntoa(s_addr));
+	printk("%s cookie %lX\n", in_ntoa(d_addr), ntohl(cookie));
+#endif /* DEBUG_IP_MASQUERADE_IPSEC */
+
+        if (cookie == 0) {
+                printk(KERN_INFO "ip_masq_in_get_isakmp(): ");
+                printk("zero cookie from %s\n", in_ntoa(s_addr));
+        }
+
+        hash = ip_masq_hash_key(protocol, d_addr, d_port);
         for(ms = ip_masq_m_tab[hash]; ms ; ms = ms->m_link) {
- 		if (protocol==ms->protocol && ms->sport == 0 &&
-		    s_addr==ms->daddr && d_addr==ms->maddr) {
-#ifdef DEBUG_IP_MASQUERADE_PPTP
-			printk("MASQ: look/in %d %08X:%04hX->%08X:%04hX OK\n",
+ 		if (protocol==ms->protocol &&
+		    cookie==ms->ospi &&
+		    ((s_addr==ms->daddr || ms->flags & IP_MASQ_F_NO_DADDR)
+		     ) &&
+		    (s_port==ms->dport || ms->flags & IP_MASQ_F_NO_DPORT) &&
+		    (d_addr==ms->maddr && d_port==ms->mport)) {
+#ifdef DEBUG_IP_MASQUERADE_IPSEC_VERBOSE
+			printk(KERN_DEBUG "MASQ: look/in %d %08X:%04hX->%08X:%04hX %08X OK\n",
 			       protocol,
 			       s_addr,
 			       s_port,
 			       d_addr,
-			       d_port);
-#endif /* DEBUG_IP_MASQUERADE_PPTP */
+			       d_port,
+                               cookie);
+#endif
                         return ms;
 		}
         }
-#endif /* CONFIG_IP_MASQUERADE_PPTP */
-
 
-#ifdef DEBUG_IP_MASQUERADE_VERBOSE
-	printk("MASQ: look/in %d %08X:%04hX->%08X:%04hX fail\n",
+#ifdef DEBUG_IP_MASQUERADE_IPSEC_VERBOSE
+	printk(KERN_DEBUG "MASQ: look/in %d %08X:%04hX->%08X:%04hX %08X fail\n",
 	       protocol,
 	       s_addr,
 	       s_port,
 	       d_addr,
-	       d_port);
+	       d_port,
+               cookie);
 #endif
         return NULL;
 }
 
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
+
 /*
  *	Returns ip_masq associated with addresses found in iph.
  *	called for pkts coming from inside-to-OUTside the firewall.
@@ -530,6 +789,10 @@
         int protocol;
         __u32 s_addr, d_addr;
         __u16 s_port, d_port;
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+        __u32 cookie;
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
+
 
  	portptr = (__u16 *)&(((char *)iph)[iph->ihl*4]);
         protocol = iph->protocol;
@@ -538,14 +801,12 @@
         d_addr = iph->daddr;
         d_port = portptr[1];
 
-#ifdef CONFIG_IP_MASQUERADE_PPTP
-/*
- *	Allow for GRE portlessness...
- */
-	if (protocol == IPPROTO_GRE) {
-	  s_port = d_port = 0;
-	}
-#endif /* CONFIG_IP_MASQUERADE_PPTP */
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+        if (protocol == IPPROTO_UDP && ntohs(s_port) == UDP_PORT_ISAKMP && ntohs(d_port) == UDP_PORT_ISAKMP) {
+                cookie = *((__u32 *)&portptr[4]);
+                return ip_masq_out_get_isakmp(protocol, s_addr, s_port, d_addr, d_port, cookie);
+        } else
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
 
         return ip_masq_out_get_2(protocol, s_addr, s_port, d_addr, d_port);
 }
@@ -571,6 +832,35 @@
         struct ip_masq *ms;
 
 
+#ifdef CONFIG_IP_MASQUERADE_PPTP
+#ifdef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+	if (protocol == IPPROTO_GRE) {
+                /*
+                 * Call ID is saved in source port number,
+                 * but we have no way of knowing it on the outbound packet...
+                 * we only know the *other side's* Call ID
+                 */
+
+                hash = ip_masq_hash_key(protocol, s_addr, 0);
+                for(ms = ip_masq_s_tab[hash]; ms ; ms = ms->s_link) {
+                        if (protocol == ms->protocol &&
+                            s_addr == ms->saddr && (s_port == 0 || s_port == ms->sport) &&
+                            d_addr == ms->daddr && d_port == ms->dport ) {
+#ifdef DEBUG_IP_MASQUERADE_VERBOSE
+                                printk(KERN_DEBUG "MASQ: lk/out2 %d %08X:%04hX->%08X:%04hX OK\n",
+                                       protocol,
+                                       s_addr,
+                                       s_port,
+                                       d_addr,
+                                       d_port);
+#endif /* DEBUG_IP_MASQUERADE_VERBOSE */
+                                return ms;
+                        }
+                }
+        }
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
+#endif /* CONFIG_IP_MASQUERADE_PPTP */
+
         hash = ip_masq_hash_key(protocol, s_addr, s_port);
         for(ms = ip_masq_s_tab[hash]; ms ; ms = ms->s_link) {
 		if (protocol == ms->protocol &&
@@ -615,6 +905,92 @@
         return NULL;
 }
 
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+struct ip_masq *
+ip_masq_out_get_ipsec(int protocol, __u32 s_addr, __u16 s_port, __u32 d_addr, __u16 d_port, __u32 o_spi)
+{
+        unsigned hash;
+        struct ip_masq *ms;
+
+	if (protocol != IPPROTO_ESP) {
+                return ip_masq_out_get_2(protocol,s_addr,s_port,d_addr,d_port);
+        }
+
+        hash = ip_masq_hash_key(protocol, s_addr, s_port);
+        for(ms = ip_masq_s_tab[hash]; ms ; ms = ms->s_link) {
+ 		if (protocol==ms->protocol &&
+		    s_addr==ms->saddr &&
+		    d_addr==ms->daddr &&
+                    o_spi==ms->ospi) {
+#ifdef DEBUG_IP_MASQUERADE_IPSEC_VERBOSE
+			printk(KERN_DEBUG "MASQ: IPSEC look/out %08X:%08X->%08X OK\n",
+			       s_addr,
+			       o_spi,
+			       d_addr);
+#endif
+                        return ms;
+		}
+        }
+        
+#ifdef DEBUG_IP_MASQUERADE_IPSEC_VERBOSE
+	printk(KERN_DEBUG "MASQ: IPSEC look/out %08X:%08X->%08X fail\n",
+	       s_addr,
+	       o_spi,
+	       d_addr);
+#endif
+        return NULL;
+}
+
+struct ip_masq *
+ip_masq_out_get_isakmp(int protocol, __u32 s_addr, __u16 s_port, __u32 d_addr, __u16 d_port, __u32 cookie)
+{
+        unsigned hash;
+        struct ip_masq *ms;
+
+#ifdef DEBUG_IP_MASQUERADE_IPSEC
+	printk(KERN_DEBUG "ip_masq_out_get_isakmp(): ");
+	printk("%s -> ", in_ntoa(s_addr));
+	printk("%s cookie %lX\n", in_ntoa(d_addr), ntohl(cookie));
+#endif /* DEBUG_IP_MASQUERADE_IPSEC */
+
+        if (cookie == 0) {
+                printk(KERN_INFO "ip_masq_out_get_isakmp(): ");
+                printk("zero cookie from %s\n", in_ntoa(s_addr));
+        }
+
+        hash = ip_masq_hash_key(protocol, s_addr, s_port);
+        for(ms = ip_masq_s_tab[hash]; ms ; ms = ms->s_link) {
+		if (protocol == ms->protocol &&
+		    cookie == ms->ospi &&
+		    s_addr == ms->saddr && s_port == ms->sport &&
+                    d_addr == ms->daddr && d_port == ms->dport ) {
+#ifdef DEBUG_IP_MASQUERADE_IPSEC_VERBOSE
+			printk(KERN_DEBUG "MASQ: lk/out1 %d %08X:%04hX->%08X:%04hX %08X OK\n",
+			       protocol,
+			       s_addr,
+			       s_port,
+			       d_addr,
+			       d_port,
+                               cookie);
+#endif
+                        return ms;
+		}
+        }
+
+#ifdef DEBUG_IP_MASQUERADE_IPSEC_VERBOSE
+	printk(KERN_DEBUG "MASQ: lk/out1 %d %08X:%04hX->%08X:%04hX %08X fail\n",
+	       protocol,
+	       s_addr,
+	       s_port,
+	       d_addr,
+	       d_port,
+               cookie);
+#endif
+        return NULL;
+}
+
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
+
 /*
  *	Returns ip_masq for given proto,m_addr,m_port.
  *      called by allocation routine to find an unused m_port.
@@ -763,6 +1139,34 @@
         for (ports_tried = 0; 
 	     (*free_ports_p && (ports_tried <= (PORT_MASQ_END - PORT_MASQ_BEGIN)));
 	     ports_tried++){
+
+#ifdef CONFIG_IP_MASQUERADE_PPTP
+#ifndef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+                /* Ignoring PPTP call IDs.
+                 * Don't needlessly increase the TCP port pointer.
+                 */
+                if (proto == IPPROTO_GRE) {
+                        ms->mport = 0;
+                        mst = NULL;
+                } else {
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
+#endif /* CONFIG_IP_MASQUERADE_PPTP */
+
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+                /* ESP masq keys off the SPI, not the port number.
+                 * Don't needlessly increase the TCP port pointer.
+                 */
+                if (proto == IPPROTO_ESP) {
+                        ms->mport = 0;
+                        mst = NULL;
+                } else {
+                if (proto == IPPROTO_UDP && ntohs(sport) == UDP_PORT_ISAKMP && ntohs(dport) == UDP_PORT_ISAKMP) {
+                        /* the port number cannot be changed */
+                        ms->mport = htons(UDP_PORT_ISAKMP);
+                        mst = NULL;
+                } else {
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
+
                 save_flags(flags);
                 cli();
                 
@@ -778,17 +1182,23 @@
                 
                 restore_flags(flags);
                 
-#ifdef CONFIG_IP_MASQUERADE_PPTP
-		if (proto == IPPROTO_GRE) {
-			ms->mport = 0;
-		}
-#endif /* CONFIG_IP_MASQUERADE_PPTP */
-
                 /*
                  *	lookup to find out if this port is used.
                  */
                 
                 mst = ip_masq_getbym(proto, ms->maddr, ms->mport);
+
+#ifdef CONFIG_IP_MASQUERADE_PPTP
+#ifndef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+                }
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
+#endif /* CONFIG_IP_MASQUERADE_PPTP */
+
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+                }
+                }
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
+
                 if (mst == NULL || matchport) {
                         save_flags(flags);
                         cli();
@@ -829,11 +1239,11 @@
 
 void ip_masq_set_expire(struct ip_masq *ms, unsigned long tout)
 {
+	/* There Can Be Only One (timer on a masq table entry, that is) */
+        del_timer(&ms->timer);
         if (tout) {
                 ms->timer.expires = jiffies+tout;
                 add_timer(&ms->timer);
-        } else {
-                del_timer(&ms->timer);
         }
 }
 
@@ -850,40 +1260,43 @@
 
 #ifdef CONFIG_IP_MASQUERADE_PPTP
 /*
- *      Quick-and-dirty handling of GRE connections
- *      to support masquerading a Microsoft PPTP client.
+ *      Masquerade of GRE connections
+ *      to support a PPTP VPN client or server.
  *      John Hardin <jhardin@wolfenet.com> gets all blame...
+ *      See also http://www.wolfenet.com/~jhardin/ip_masq_pptp.html
  */
 
 /*
  *	Handle outbound GRE packets.
  *
- *	This is largely a copy of ip_fw_masquerade(), unless I decide
- *	to fold it in *there* rather than duplicating code *here*...
- *
- *	GRE doesn't have ports, so we use dummy ports 0/0 and only support
- *	one GRE session per remote server.
+ *	This is largely a copy of ip_fw_masquerade()
  */
 
 int ip_fw_masq_gre(struct sk_buff **skb_p, struct device *dev)
 {
         struct sk_buff 	*skb   = *skb_p;
- 	struct iphdr	*iph   = skb->h.iph;
- 	struct grehdr	*greh;
+        struct iphdr	*iph   = skb->h.iph;
+        struct pptp_gre_header	*greh;
 #ifdef DEBUG_IP_MASQUERADE_PPTP
-	__u8		*greraw;
+#ifdef DEBUG_IP_MASQUERADE_PPTP_VERBOSE
+        __u8		*greraw;
+#endif /* DEBUG_IP_MASQUERADE_PPTP_VERBOSE */
 #endif /* DEBUG_IP_MASQUERADE_PPTP */
         struct ip_masq	*ms;
-	unsigned long    flags;
+        unsigned long    flags;
 
 
-	greh = (struct grehdr *)&(((char *)iph)[iph->ihl*4]);
+        greh = (struct pptp_gre_header *)&(((char *)iph)[iph->ihl*4]);
 
 #ifdef DEBUG_IP_MASQUERADE_PPTP
 
-	printk("Outbound GRE packet from %lX to %lX\n", ntohl(iph->saddr), ntohl(iph->daddr));
+        printk(KERN_DEBUG "ip_fw_masq_gre(): ");
+        printk("Outbound GRE packet from %s", in_ntoa(iph->saddr));
+        printk(" to %s\n", in_ntoa(iph->daddr));
 
+#ifdef DEBUG_IP_MASQUERADE_PPTP_VERBOSE
 	greraw = (__u8 *) greh;
+	printk(KERN_DEBUG "ip_fw_masq_gre(): ");
 	printk("GRE raw: %X %X %X %X %X %X %X %X %X %X %X %X.\n",
 		greraw[0],
 		greraw[1],
@@ -897,6 +1310,7 @@
 		greraw[9],
 		greraw[10],
 		greraw[11]);
+	printk(KERN_DEBUG "ip_fw_masq_gre(): ");
 	printk("GRE C: %d R: %d K: %d S: %d s: %d recur: %X.\n",
                 greh->has_cksum,
                 greh->has_routing,
@@ -904,41 +1318,41 @@
                 greh->has_seq,
                 greh->is_strict,
                 greh->recur);
+	printk(KERN_DEBUG "ip_fw_masq_gre(): ");
 	printk("GRE flags: %X ver: %X.\n", greh->flags, greh->version);
+	printk(KERN_DEBUG "ip_fw_masq_gre(): ");
 	printk("GRE proto: %X.\n", ntohs(greh->protocol));
+#endif /* DEBUG_IP_MASQUERADE_PPTP_VERBOSE */
 #endif /* DEBUG_IP_MASQUERADE_PPTP */
 
-	if (ntohs(greh->protocol) != 0x880b) {
+	if (ntohs(greh->protocol) != 0x880B) {
 #ifdef DEBUG_IP_MASQUERADE_PPTP
+	  printk(KERN_INFO "ip_fw_masq_gre(): ");
 	  printk("GRE protocol %X not 0x880B (non-PPTP encap?) - discarding.\n", ntohs(greh->protocol));
 #endif /* DEBUG_IP_MASQUERADE_PPTP */
 	  return -1;
 	}
 
 	/*
-	 *	Now hunt the list to see if we have an old entry
+	 *	Look for masq table entry
 	 */
 
-        ms = ip_masq_out_get(iph);
+        ms = ip_masq_out_get_2(IPPROTO_GRE,
+                iph->saddr, 0,
+                iph->daddr, 0);
+
 	if (ms!=NULL) {
+                /* delete the expiration timer */
         	ip_masq_set_expire(ms,0);
 
 		/*
-		 *	Until we tie into the PPTP control channel,
-                 *      there's no way to detect the data channel going
-                 *      down. Therefore, we may have an invalid GRE masq
-                 *      from a previous session if, for example, the PPP
-                 *      link goes down and is brought right back up and the
-                 *      PPTP link tries to be established before the masq
-                 *      entry expires (see the timer below).
                  *      Make sure that the masq IP address is correct
-                 *      for the current session...
+                 *      for dynamic IP...
 		 */
-		if (ms->maddr != dev->pa_addr) {
-#ifdef DEBUG_IP_MASQUERADE_PPTP
-			printk("GRE masq IP changed from %lX to %lX\n",
-				ntohl(ms->maddr),ntohl(dev->pa_addr));
-#endif /* DEBUG_IP_MASQUERADE_PPTP */
+		if ( (ms->maddr != dev->pa_addr) && (sysctl_ip_dynaddr & 3) ) {
+                        printk(KERN_INFO "ip_fw_masq_gre(): ");
+                        printk("change maddr from %s", in_ntoa(ms->maddr));
+                        printk(" to %s\n", in_ntoa(dev->pa_addr));
 		        save_flags(flags);
 		        cli();
 		        ip_masq_unhash(ms);
@@ -946,42 +1360,49 @@
 		        ip_masq_hash(ms);
 		        restore_flags(flags);
                 }
-	}
-
-	/*
-	 *	Nope, not found, create a new entry for it
-	 */
+	} else {
+                /*
+                 *	Nope, not found, create a new entry for it, maybe
+                 */
 	
-	if (ms==NULL)
-	{
-		ms = ip_masq_new_enh(dev, iph->protocol,
+#ifdef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+                /* masq table entry has to come from control channel sniffing.
+                 * If we can't find one, it may have expired.
+                 * How can this happen with the control channel active?
+                 */
+	        printk(KERN_INFO "ip_fw_masq_gre(): ");
+                printk("Outbound GRE to %s has no masq table entry.\n",
+                        in_ntoa(iph->daddr));
+                return -1;
+#else /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
+                /* call IDs ignored, can create masq table entries on the fly. */
+		ms = ip_masq_new(dev, iph->protocol,
 				 iph->saddr, 0,
 				 iph->daddr, 0,
-				 0,
 				 0);
-                if (ms == NULL)
+
+                if (ms == NULL) {
+                        printk(KERN_NOTICE "ip_fw_masq_gre(): Couldn't create masq table entry.\n");
 			return -1;
+                }
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
  	}
 
- 	/*
- 	 *	Change the fragments origin
- 	 */
- 	
         /*
-         *	Set iph addr from ip_masq obj.
+         *	Set iph source addr from ip_masq obj.
          */
  	iph->saddr = ms->maddr;
 
-
  	/*
  	 *	set timeout and check IP header
  	 */
  	
-        ip_masq_set_expire(ms, 6000);		/* 60 second timeout */
+        ip_masq_set_expire(ms, MASQUERADE_EXPIRE_PPTP);
  	ip_send_check(iph);
 
 #ifdef DEBUG_IP_MASQUERADE_PPTP
- 	printk("GRE O-routed from %lX over %s\n",ntohl(ms->maddr),dev->name);
+ 	printk(KERN_DEBUG "MASQ: GRE O-routed from %s over %s\n",
+                in_ntoa(ms->maddr), dev->name);
 #endif /* DEBUG_IP_MASQUERADE_PPTP */
 
 	return 0;
@@ -990,34 +1411,32 @@
 /*
  *	Handle inbound GRE packets.
  *
- *	NT PPTP uses a plain TCP connection to port 1723 to set up the
- *	GRE encapsulated channel. To figure out where to send the
- *	inbound GRE packet, we'll look for the masq record for that.
- *	This means that if you're not masquerading the outbound control
- *	session, the inbound data session will fail.
- *
- *	To keep this simple, we'll only support one inbound GRE connection
- *	per PPTP server.
  */
 
 int ip_fw_demasq_gre(struct sk_buff **skb_p, struct device *dev)
 {
         struct sk_buff 	*skb   = *skb_p;
  	struct iphdr	*iph   = skb->h.iph;
- 	struct grehdr	*greh;
+ 	struct pptp_gre_header	*greh;
 #ifdef DEBUG_IP_MASQUERADE_PPTP
+#ifdef DEBUG_IP_MASQUERADE_PPTP_VERBOSE
 	__u8		*greraw;
+#endif /* DEBUG_IP_MASQUERADE_PPTP_VERBOSE */
 #endif /* DEBUG_IP_MASQUERADE_PPTP */
         struct ip_masq	*ms;
 
 
-	greh = (struct grehdr *)&(((char *)iph)[iph->ihl*4]);
+	greh = (struct pptp_gre_header *)&(((char *)iph)[iph->ihl*4]);
 
 #ifdef DEBUG_IP_MASQUERADE_PPTP
 
-	printk("Inbound GRE packet from %lX to %lX\n", ntohl(iph->saddr), ntohl(iph->daddr));
+	printk(KERN_DEBUG "ip_fw_demasq_gre(): ");
+	printk("Inbound GRE packet from %s", in_ntoa(iph->saddr));
+	printk(" to %s\n", in_ntoa(iph->daddr));
 
+#ifdef DEBUG_IP_MASQUERADE_PPTP_VERBOSE
 	greraw = (__u8 *) greh;
+	printk(KERN_DEBUG "ip_fw_demasq_gre(): ");
 	printk("GRE raw: %X %X %X %X %X %X %X %X %X %X %X %X.\n",
 		greraw[0],
 		greraw[1],
@@ -1031,6 +1450,7 @@
 		greraw[9],
 		greraw[10],
 		greraw[11]);
+	printk(KERN_DEBUG "ip_fw_demasq_gre(): ");
 	printk("GRE C: %d R: %d K: %d S: %d s: %d recur: %X.\n",
                 greh->has_cksum,
                 greh->has_routing,
@@ -1038,51 +1458,771 @@
                 greh->has_seq,
                 greh->is_strict,
                 greh->recur);
+	printk(KERN_DEBUG "ip_fw_demasq_gre(): ");
 	printk("GRE flags: %X ver: %X.\n", greh->flags, greh->version);
+	printk(KERN_DEBUG "ip_fw_demasq_gre(): ");
 	printk("GRE proto: %X.\n", ntohs(greh->protocol));
+#endif /* DEBUG_IP_MASQUERADE_PPTP_VERBOSE */
+
+#ifdef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+	printk(KERN_DEBUG "ip_fw_demasq_gre(): ");
+	printk("PPTP call ID: %X.\n", ntohs(greh->call_id));
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
+
 #endif /* DEBUG_IP_MASQUERADE_PPTP */
 
-	if (ntohs(greh->protocol) != 0x880b) {
+	if (ntohs(greh->protocol) != 0x880B) {
 #ifdef DEBUG_IP_MASQUERADE_PPTP
+	  printk(KERN_INFO "ip_fw_demasq_gre(): ");
 	  printk("GRE protocol %X not 0x880B (non-PPTP encap?) - discarding.\n", ntohs(greh->protocol));
 #endif /* DEBUG_IP_MASQUERADE_PPTP */
 	  return -1;
 	}
 
  	/*
- 	 * reroute to original host if found...
+ 	 *      Look for a masq table entry and reroute if found
          */
 
-        ms = ip_masq_in_get(iph);
+#ifdef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+        ms = ip_masq_getbym(IPPROTO_GRE,
+                iph->daddr, greh->call_id);
+#else /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
+        ms = ip_masq_in_get_2(IPPROTO_GRE,
+                iph->saddr, 0,
+                iph->daddr, 0);
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
 
         if (ms != NULL)
         {
-		/* Stop the timer ticking.... */
+                /* delete the expiration timer */
 		ip_masq_set_expire(ms,0);
 
                 iph->daddr = ms->saddr;
 
+#ifdef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+                /*
+                 * change peer call ID to original value
+                 * (saved in masq table source port)
+                 */
+
+                greh->call_id = ms->sport;
+
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+	        printk(KERN_DEBUG "ip_fw_demasq_gre(): ");
+                printk("inbound PPTP from %s call ID now %X\n",
+                       in_ntoa(iph->saddr), ntohs(greh->call_id));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
 
                 /*
-                 * Yug! adjust IP checksums, also update
-		 * timeouts.
+                 * resum checksums and set timeout
                  */
-		ip_masq_set_expire(ms, 6000);		/* 60 second timeout */
+		ip_masq_set_expire(ms, MASQUERADE_EXPIRE_PPTP);
                 ip_send_check(iph);
 
 #ifdef DEBUG_IP_MASQUERADE_PPTP
-                printk("GRE I-routed to %lX\n",ntohl(iph->daddr));
-#endif
+                printk(KERN_DEBUG "MASQ: GRE I-routed to %s\n", in_ntoa(iph->daddr));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
                 return 1;
  	}
 
  	/* sorry, all this trouble for a no-hit :) */
+	printk(KERN_INFO "ip_fw_demasq_gre(): ");
+	printk("Inbound from %s has no masq table entry.\n", in_ntoa(iph->saddr));
  	return 0;
 }
 
+#ifdef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+/*
+ *      Define all of the PPTP control channel message structures.
+ *      Sniff the control channel looking for start- and end-call
+ *      messages, and masquerade the Call ID as if it was a TCP
+ *      port.
+ */
+
+#define PPTP_CONTROL_PACKET            1
+#define PPTP_MGMT_PACKET               2
+#define PPTP_MAGIC_COOKIE              0x1A2B3C4D
+
+struct PptpPacketHeader {
+       __u16 packetLength;
+       __u16 packetType;
+       __u32 magicCookie;
+};
+
+/* PptpControlMessageType values */
+#define PPTP_START_SESSION_REQUEST     1
+#define PPTP_START_SESSION_REPLY       2
+#define PPTP_STOP_SESSION_REQUEST      3
+#define PPTP_STOP_SESSION_REPLY        4
+#define PPTP_ECHO_REQUEST              5
+#define PPTP_ECHO_REPLY                6
+#define PPTP_OUT_CALL_REQUEST          7
+#define PPTP_OUT_CALL_REPLY            8
+#define PPTP_IN_CALL_REQUEST           9
+#define PPTP_IN_CALL_REPLY             10
+#define PPTP_CALL_CLEAR_REQUEST        11
+#define PPTP_CALL_DISCONNECT_NOTIFY    12
+#define PPTP_CALL_ERROR_NOTIFY         13
+#define PPTP_WAN_ERROR_NOTIFY          14
+#define PPTP_SET_LINK_INFO             15
+
+struct PptpControlHeader {
+    __u16 messageType;
+    __u16 reserved;
+};
+
+struct PptpOutCallRequest {
+    __u16 callID;
+    __u16 callSerialNumber;
+    __u32 minBPS;
+    __u32 maxBPS;
+    __u32 bearerType;
+    __u32 framingType;
+    __u16 packetWindow;
+    __u16 packetProcDelay;
+    __u16 reserved1;
+    __u16 phoneNumberLength;
+    __u16 reserved2;
+    __u8  phoneNumber[64];
+    __u8  subAddress[64];
+};
+
+struct PptpOutCallReply {
+    __u16 callID;
+    __u16 peersCallID;
+    __u8  resultCode;
+    __u8  generalErrorCode;
+    __u16 causeCode;
+    __u32 connectSpeed;
+    __u16 packetWindow;
+    __u16 packetProcDelay;
+    __u32 physChannelID;
+};
+
+struct PptpInCallRequest {
+    __u16 callID;
+    __u16 callSerialNumber;
+    __u32 callBearerType;
+    __u32 physChannelID;
+    __u16 dialedNumberLength;
+    __u16 dialingNumberLength;
+    __u8  dialedNumber[64];
+    __u8  dialingNumber[64];
+    __u8  subAddress[64];
+};
+
+struct PptpInCallReply {
+    __u16 callID;
+    __u16 peersCallID;
+    __u8  resultCode;
+    __u8  generalErrorCode;
+    __u16 packetWindow;
+    __u16 packetProcDelay;
+    __u16 reserved;
+};
+
+struct PptpCallDisconnectNotify {
+    __u16 callID;
+    __u8  resultCode;
+    __u8  generalErrorCode;
+    __u16 causeCode;
+    __u16 reserved;
+    __u8  callStatistics[128];
+};
+
+struct PptpWanErrorNotify {
+    __u16 peersCallID;
+    __u16 reserved;
+    __u32 crcErrors;
+    __u32 framingErrors;
+    __u32 hardwareOverRuns;
+    __u32 bufferOverRuns;
+    __u32 timeoutErrors;
+    __u32 alignmentErrors;
+};
+
+struct PptpSetLinkInfo {
+    __u16 peersCallID;
+    __u16 reserved;
+    __u32 sendAccm;
+    __u32 recvAccm;
+};
+
+
+/* Packet sent to or from PPTP control port. Process it. */
+/* Yes, all of this should be in a kernel module. Real Soon Now... */
+void ip_masq_pptp(struct sk_buff *skb, struct ip_masq *ms, struct device *dev)
+{
+        struct iphdr    *iph   = skb->h.iph;
+        struct PptpPacketHeader  *pptph = NULL;
+        struct PptpControlHeader *ctlh = NULL;
+        union {
+                char *req;
+                struct PptpOutCallRequest       *ocreq;
+                struct PptpOutCallReply         *ocack;
+                struct PptpInCallRequest        *icreq;
+                struct PptpInCallReply          *icack;
+                struct PptpCallDisconnectNotify *disc;
+                struct PptpWanErrorNotify       *wanerr;
+                struct PptpSetLinkInfo          *setlink;
+        } pptpReq;
+        struct ip_masq  *ms_gre = NULL;
+
+        /*
+         * The GRE data channel will be treated as the "control channel"
+         * for the purposes of masq because there are keepalives happening
+         * on the control channel, whereas the data channel may be subject
+         * to relatively long periods of inactivity.
+         */
+         
+        pptph = (struct PptpPacketHeader *)&(((char *)iph)[sizeof(struct iphdr) + sizeof(struct tcphdr)]);
+#ifdef DEBUG_IP_MASQUERADE_PPTP_VERBOSE
+        printk(KERN_DEBUG "ip_masq_pptp(): ");
+        printk("LEN=%d TY=%d MC=%lX\n", ntohs(pptph->packetLength),
+                ntohs(pptph->packetType), ntohl(pptph->magicCookie));
+#endif /* DEBUG_IP_MASQUERADE_PPTP_VERBOSE */
+
+        if (ntohs(pptph->packetType) == PPTP_CONTROL_PACKET &&
+            ntohl(pptph->magicCookie) == PPTP_MAGIC_COOKIE) {
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                printk(KERN_DEBUG "ip_masq_pptp(): ");
+                printk("PPTP control packet from %s", in_ntoa(iph->saddr));
+                printk(" to %s\n", in_ntoa(iph->daddr));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                ctlh = (struct PptpControlHeader *)&(((char*)pptph)[sizeof(struct PptpPacketHeader)]);
+                pptpReq.req = &(((char*)ctlh)[sizeof(struct PptpControlHeader)]);
+#ifdef DEBUG_IP_MASQUERADE_PPTP_VERBOSE
+                printk(KERN_DEBUG "ip_masq_pptp(): ");
+                printk("MTY=%X R0=%X\n",
+                        ntohs(ctlh->messageType), ctlh->reserved);
+#endif /* DEBUG_IP_MASQUERADE_PPTP_VERBOSE */
+
+                switch (ntohs(ctlh->messageType))
+                {
+                        case PPTP_OUT_CALL_REQUEST:
+                                if (iph->daddr == ms->daddr)    /* outbound only */
+                                {
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                        printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                        printk("Call request, call ID %X\n",
+                                                ntohs(pptpReq.ocreq->callID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        ms_gre = ip_masq_new(dev, IPPROTO_GRE,
+                                                ms->saddr, pptpReq.ocreq->callID,
+                                                ms->daddr, 0,
+                                                0);
+                                        if (ms_gre != NULL)
+                                        {
+                                                ms->control = ms_gre;
+                                                ms_gre->flags |= IP_MASQ_F_CONTROL;
+                                                ip_masq_set_expire(ms_gre, 0);
+                                                ip_masq_set_expire(ms_gre, 2*60*HZ);
+                                                pptpReq.ocreq->callID = ms_gre->mport;
+                                                printk(KERN_INFO "ip_masq_pptp(): ");
+                                                printk("Req outcall PPTP sess %s", in_ntoa(ms->saddr));
+                                                printk(" -> %s", in_ntoa(ms->daddr));
+                                                printk(" Call ID %X -> %X.\n", ntohs(ms_gre->sport), ntohs(ms_gre->mport));
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                                printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                                printk("masqed call ID %X\n",
+                                                        ntohs(pptpReq.ocreq->callID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        } else {
+                                                printk(KERN_NOTICE "ip_masq_pptp(): ");
+                                                printk("Couldn't create GRE masq table entry (%s)\n", "OUT_CALL_REQ");
+                                        }
+                                }
+                        break;
+                        case PPTP_OUT_CALL_REPLY:
+                                if (iph->saddr == ms->daddr)    /* inbound only */
+                                {
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                        printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                        printk("Call reply, peer call ID %X\n",
+                                                ntohs(pptpReq.ocack->peersCallID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        ms_gre = ip_masq_getbym(IPPROTO_GRE,
+                                                ms->maddr, pptpReq.ocack->peersCallID);
+                                        if (ms_gre != NULL)
+                                        {
+                                                ip_masq_set_expire(ms_gre, 0);
+                                                ip_masq_set_expire(ms_gre, 2*60*HZ);
+                                                pptpReq.ocack->peersCallID = ms_gre->sport;
+                                                printk(KERN_INFO "ip_masq_pptp(): ");
+                                                printk("Estab outcall PPTP sess %s", in_ntoa(ms->saddr));
+                                                printk(" -> %s", in_ntoa(ms->daddr));
+                                                printk(" Call ID %X -> %X.\n", ntohs(ms_gre->sport), ntohs(ms_gre->mport));
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                                printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                                printk("unmasqed call ID %X\n",
+                                                        ntohs(pptpReq.ocack->callID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        } else {
+                                                printk(KERN_INFO "ip_masq_pptp(): ");
+                                                printk("Lost GRE masq table entry (%s)\n", "OUT_CALL_REPLY");
+                                        }
+                                }
+                        break;
+                        case PPTP_IN_CALL_REQUEST:
+                                if (iph->daddr == ms->daddr)    /* outbound only */
+                                {
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                        printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                        printk("Call request, call ID %X\n",
+                                                ntohs(pptpReq.icreq->callID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        ms_gre = ip_masq_new(dev, IPPROTO_GRE,
+                                                 ms->saddr, pptpReq.icreq->callID,
+                                                 ms->daddr, 0,
+                                                 0);
+                                        if (ms_gre != NULL)
+                                        {
+                                                ms->control = ms_gre;
+                                                ms_gre->flags |= IP_MASQ_F_CONTROL;
+                                                ip_masq_set_expire(ms_gre, 0);
+                                                ip_masq_set_expire(ms_gre, 2*60*HZ);
+                                                pptpReq.icreq->callID = ms_gre->mport;
+                                                printk(KERN_INFO "ip_masq_pptp(): ");
+                                                printk("Req incall PPTP sess %s", in_ntoa(ms->saddr));
+                                                printk(" -> %s", in_ntoa(ms->daddr));
+                                                printk(" Call ID %X -> %X.\n", ntohs(ms_gre->sport), ntohs(ms_gre->mport));
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                                printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                                printk("masqed call ID %X\n",
+                                                        ntohs(pptpReq.icreq->callID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        } else {
+                                                printk(KERN_NOTICE "ip_masq_pptp(): ");
+                                                printk("Couldn't create GRE masq table entry (%s)\n", "IN_CALL_REQ");
+                                        }
+                                }
+                        break;
+                        case PPTP_IN_CALL_REPLY:
+                                if (iph->saddr == ms->daddr)    /* inbound only */
+                                {
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                        printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                        printk("Call reply, peer call ID %X\n",
+                                                ntohs(pptpReq.icack->peersCallID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        ms_gre = ip_masq_getbym(IPPROTO_GRE,
+                                                ms->maddr, pptpReq.icack->peersCallID);
+                                        if (ms_gre != NULL)
+                                        {
+                                                ip_masq_set_expire(ms_gre, 0);
+                                                ip_masq_set_expire(ms_gre, 2*60*HZ);
+                                                pptpReq.icack->peersCallID = ms_gre->sport;
+                                                printk(KERN_INFO "ip_masq_pptp(): ");
+                                                printk("Estab incall PPTP sess %s", in_ntoa(ms->saddr));
+                                                printk(" -> %s", in_ntoa(ms->daddr));
+                                                printk(" Call ID %X -> %X.\n", ntohs(ms_gre->sport), ntohs(ms_gre->mport));
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                                printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                                printk("unmasqed call ID %X\n",
+                                                        ntohs(pptpReq.icack->callID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        } else {
+                                                printk(KERN_INFO "ip_masq_pptp(): ");
+                                                printk("Lost GRE masq table entry (%s)\n", "IN_CALL_REPLY");
+                                        }
+                                }
+                        break;
+                        case PPTP_CALL_DISCONNECT_NOTIFY:
+                                if (iph->daddr == ms->daddr)    /* outbound only */
+                                {
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                        printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                        printk("Disconnect notify, call ID %X\n",
+                                                ntohs(pptpReq.disc->callID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        ms_gre = ip_masq_out_get_2(IPPROTO_GRE,
+                                                iph->saddr, pptpReq.disc->callID,
+                                                iph->daddr, 0);
+                                        if (ms_gre != NULL)
+                                        {
+                                                /*
+                                                 * expire the data channel
+                                                 * table entry quickly now.
+                                                 */
+                                                ip_masq_set_expire(ms_gre, 0);
+                                                ip_masq_set_expire(ms_gre, 30*HZ);
+                                                ms->control = NULL;
+                                                ms_gre->flags &= ~IP_MASQ_F_CONTROL;
+                                                pptpReq.disc->callID = ms_gre->mport;
+                                                printk(KERN_INFO "ip_masq_pptp(): ");
+                                                printk("Disconnect PPTP sess %s", in_ntoa(ms->saddr));
+                                                printk(" -> %s", in_ntoa(ms->daddr));
+                                                printk(" Call ID %X -> %X.\n", ntohs(ms_gre->sport), ntohs(ms_gre->mport));
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                                printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                                printk("masqed call ID %X\n",
+                                                        ntohs(pptpReq.disc->callID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        }
+                                }
+                        break;
+                        case PPTP_WAN_ERROR_NOTIFY:
+                                if (iph->saddr == ms->daddr)    /* inbound only */
+                                {
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                        printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                        printk("Error notify, peer call ID %X\n",
+                                                ntohs(pptpReq.wanerr->peersCallID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        ms_gre = ip_masq_getbym(IPPROTO_GRE,
+                                                ms->maddr, pptpReq.wanerr->peersCallID);
+                                        if (ms_gre != NULL)
+                                        {
+                                                pptpReq.wanerr->peersCallID = ms_gre->sport;
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                                printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                                printk("unmasqed call ID %X\n",
+                                                        ntohs(pptpReq.wanerr->peersCallID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        } else {
+                                                printk(KERN_INFO "ip_masq_pptp(): ");
+                                                printk("Lost GRE masq table entry (%s)\n", "WAN_ERROR_NOTIFY");
+                                        }
+                                }
+                        break;
+                        case PPTP_SET_LINK_INFO:
+                                if (iph->saddr == ms->daddr)    /* inbound only */
+                                {
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                        printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                        printk("Set link info, peer call ID %X\n",
+                                                ntohs(pptpReq.setlink->peersCallID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        ms_gre = ip_masq_getbym(IPPROTO_GRE,
+                                                ms->maddr, pptpReq.setlink->peersCallID);
+                                        if (ms_gre != NULL)
+                                        {
+                                                pptpReq.setlink->peersCallID = ms_gre->sport;
+#ifdef DEBUG_IP_MASQUERADE_PPTP
+                                                printk(KERN_DEBUG "ip_masq_pptp(): ");
+                                                printk("unmasqed call ID %X\n",
+                                                        ntohs(pptpReq.setlink->peersCallID));
+#endif /* DEBUG_IP_MASQUERADE_PPTP */
+                                        } else {
+                                                printk(KERN_INFO "ip_masq_pptp(): ");
+                                                printk("Lost GRE masq table entry (%s)\n", "SET_LINK_INFO");
+                                        }
+                                }
+                        break;
+                }
+        }
+}
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
+
+static struct symbol_table pptp_masq_syms = {
+#include <linux/symtab_begin.h>
+	X(ip_fw_masq_gre),
+	X(ip_fw_demasq_gre),
+#ifdef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+	X(ip_masq_pptp),
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
+#include <linux/symtab_end.h>
+};
+
 #endif /* CONFIG_IP_MASQUERADE_PPTP */
 
 
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+/*
+ *      Quick-and-dirty handling of ESP connections
+ *      John Hardin <jhardin@wolfenet.com> gets all blame...
+ */
+
+/*
+ *	Handle outbound ESP packets.
+ *
+ *	This is largely a copy of ip_fw_masquerade()
+ *
+ * To associate inbound traffic with outbound traffic, we only
+ * allow one session per remote host to be negotiated at a time.
+ * If a packet comes in and there's no masq table entry for it,
+ * then check for other masq table entries for the same server
+ * with the inbound SPI set to zero (i.e. no response yet). If
+ * found, discard the packet.
+ * This will DoS the server for the duration of the connection
+ * attempt, so keep the masq entry's lifetime short until a
+ * response comes in.
+ */
+
+int ip_fw_masq_esp(struct sk_buff **skb_p, struct device *dev)
+{
+        struct sk_buff 	*skb   = *skb_p;
+        struct iphdr	*iph   = skb->h.iph;
+        struct ip_masq	*ms;
+        unsigned long    flags;
+        __u32 o_spi;
+        __u16 fake_sport;
+        unsigned long    timeout = MASQUERADE_EXPIRE_IPSEC;
+
+        o_spi = *((__u32 *)&(((char *)iph)[iph->ihl*4]));
+        fake_sport = (__u16) ntohl(o_spi) & 0xffff;
+
+#ifdef DEBUG_IP_MASQUERADE_IPSEC
+        printk(KERN_DEBUG "ip_fw_masq_esp(): ");
+        printk("pkt %s", in_ntoa(iph->saddr));
+        printk(" -> %s SPI %lX (fakeport %X)\n", in_ntoa(iph->daddr), ntohl(o_spi), fake_sport);
+#endif /* DEBUG_IP_MASQUERADE_IPSEC */
+
+        if (o_spi == 0) {
+                /* illegal SPI - discard */
+                printk(KERN_INFO "ip_fw_masq_esp(): ");
+                printk("zero SPI from %s discarded\n", in_ntoa(iph->saddr));
+                return -1;
+        }
+
+	/*
+	 *	Look for masq table entry
+	 */
+
+        ms = ip_masq_out_get_ipsec(IPPROTO_ESP,
+                iph->saddr, fake_sport,
+                iph->daddr, 0,
+                o_spi);
+
+	if (ms!=NULL) {
+                if (ms->ispi == IPSEC_INIT_SQUELCHED) {
+                        /* squelched: toss the packet without changing the timer */
+#ifdef DEBUG_IP_MASQUERADE_IPSEC
+                        printk(KERN_INFO "ip_fw_masq_esp(): ");
+			printk("init %s ", in_ntoa(iph->saddr));
+			printk("-> %s SPI %lX ", in_ntoa(iph->daddr), ntohl(o_spi));
+			printk("squelched\n");
+#endif /* DEBUG_IP_MASQUERADE_IPSEC */
+                        return -1;
+                }
+
+                /* delete the expiration timer */
+        	ip_masq_set_expire(ms,0);
+
+		/*
+                 *      Make sure that the masq IP address is correct
+                 *      for dynamic IP...
+		 */
+		if ( (ms->maddr != dev->pa_addr) && (sysctl_ip_dynaddr & 3) ) {
+                        printk(KERN_INFO "ip_fw_masq_esp(): ");
+                        printk("change maddr from %s", in_ntoa(ms->maddr));
+                        printk(" to %s\n", in_ntoa(dev->pa_addr));
+		        save_flags(flags);
+		        cli();
+		        ip_masq_unhash(ms);
+		        ms->maddr = dev->pa_addr;
+		        ip_masq_hash(ms);
+		        restore_flags(flags);
+                }
+
+                if (ms->ispi == 0) {
+                        /* no response yet, keep timeout short */
+			timeout = MASQUERADE_EXPIRE_IPSEC_INIT;
+                        if (ms->blocking) {
+                                /* prevent DoS: limit init packet timer resets */
+                                ms->ocnt++;
+        #ifdef DEBUG_IP_MASQUERADE_IPSEC
+                                printk(KERN_INFO "ip_fw_masq_esp(): ");
+                                printk("init %s ", in_ntoa(iph->saddr));
+                                printk("-> %s SPI %lX ", in_ntoa(iph->daddr), ntohl(o_spi));
+                                printk("retry %d\n", ms->ocnt);
+        #endif /* DEBUG_IP_MASQUERADE_IPSEC */
+                                if (ms->ocnt > IPSEC_INIT_RETRIES) {
+                                        /* more than IPSEC_INIT_RETRIES tries, give up */
+                                        printk(KERN_INFO "ip_fw_masq_esp(): ");
+                                        printk("init %s ", in_ntoa(iph->saddr));
+                                        printk("-> %s SPI %lX ", in_ntoa(iph->daddr), ntohl(o_spi));
+                                        printk("no response after %d tries, unblocking & squelching\n", ms->ocnt);
+                                        /* squelch that source+SPI for a bit */
+                                        timeout = 30*HZ;
+                                        save_flags(flags);
+                                        cli();
+                                        ip_masq_unhash(ms);
+                                        ms->ispi = IPSEC_INIT_SQUELCHED;
+                                        ms->dport = IPSEC_INIT_SQUELCHED;
+                                        ip_masq_hash(ms);
+                                        restore_flags(flags);
+                                        ip_masq_set_expire(ms, timeout);
+                                        /* toss the packet */
+                                        return -1;
+                                }
+                        }
+                }
+	} else {
+                /*
+                 *	Nope, not found, create a new entry for it, maybe
+                 */
+	
+                /* see if there are any pending inits with the same destination... */
+                ms = ip_masq_in_get_ipsec(IPPROTO_ESP,
+                        iph->daddr, 0,
+                        0, 0,
+                        0);
+                
+                if (ms != NULL) {
+                        /* found one with ispi == 0 */
+                        if (ms->saddr != iph->saddr) {
+                                /* it's not ours, don't step on their toes */
+                                printk(KERN_INFO "ip_fw_masq_esp(): ");
+                                printk("init %s ", in_ntoa(iph->saddr));
+                                printk("-> %s ", in_ntoa(iph->daddr));
+                                printk("temporarily blocked by pending ");
+                                printk("%s init\n", in_ntoa(ms->saddr));
+                                /* let it know it has competition */
+                                ms->blocking = 1;
+                                /* toss the packet */
+                                return -1;
+                        }
+                        if (ms->ospi != o_spi) {
+                                /* SPIs differ, still waiting for a previous attempt to expire */
+                                printk(KERN_INFO "ip_fw_masq_esp(): ");
+                                printk("init %s ", in_ntoa(iph->saddr));
+                                printk("-> %s SPI %lX ", in_ntoa(iph->daddr), ntohl(o_spi));
+                                printk("temporarily blocked by pending ");
+                                printk("init w/ SPI %lX\n", ntohl(ms->ospi));
+                                /* let it know it has competition */
+                                ms->blocking = 1;
+                                /* toss the packet */
+                                return -1;
+                        }
+                } else  /* nothing pending, make new entry, pending response */
+                        ms = ip_masq_new(dev, iph->protocol,
+				 iph->saddr, fake_sport,
+				 iph->daddr, 0,
+				 0);
+
+                if (ms == NULL) {
+                        printk(KERN_NOTICE "ip_fw_masq_esp(): Couldn't create masq table entry.\n");
+			return -1;
+                }
+
+                ms->blocking = ms->ocnt = 0;
+                ms->ospi = o_spi;
+                timeout = MASQUERADE_EXPIRE_IPSEC_INIT;      /* fairly brief timeout while waiting for a response */
+ 	}
+
+        /*
+         *	Set iph source addr from ip_masq obj.
+         */
+ 	iph->saddr = ms->maddr;
+
+ 	/*
+ 	 *	set timeout and check IP header
+ 	 */
+ 	
+        ip_masq_set_expire(ms, timeout);
+ 	ip_send_check(iph);
+
+#ifdef DEBUG_IP_MASQUERADE_IPSEC_VERBOSE
+ 	printk(KERN_DEBUG "MASQ: ESP O-routed from %s over %s\n",
+                in_ntoa(ms->maddr), dev->name);
+#endif /* DEBUG_IP_MASQUERADE_IPSEC_VERBOSE */
+
+	return 0;
+}
+
+/*
+ *	Handle inbound ESP packets.
+ *
+ */
+
+int ip_fw_demasq_esp(struct sk_buff **skb_p, struct device *dev)
+{
+        struct sk_buff 	*skb   = *skb_p;
+ 	struct iphdr	*iph   = skb->h.iph;
+        struct ip_masq	*ms;
+        unsigned long    flags;
+        __u32 i_spi;
+        __u16 fake_sport;
+
+
+        i_spi = *((__u32 *)&(((char *)iph)[iph->ihl*4]));
+        fake_sport = (__u16) ntohl(i_spi) & 0xffff;
+
+#ifdef DEBUG_IP_MASQUERADE_IPSEC
+        printk(KERN_DEBUG "ip_fw_demasq_esp(): ");
+	printk("pkt %s", in_ntoa(iph->saddr));
+	printk(" -> %s SPI %lX (fakeport %X)\n", in_ntoa(iph->daddr), ntohl(i_spi), fake_sport);
+#endif /* DEBUG_IP_MASQUERADE_IPSEC */
+
+        if (i_spi == 0) {
+                /* illegal SPI - discard */
+                printk(KERN_INFO "ip_fw_demasq_esp(): ");
+                printk("zero SPI from %s discarded\n", in_ntoa(iph->saddr));
+                return 0;
+        }
+
+        if (i_spi == IPSEC_INIT_SQUELCHED) {
+                /* Ack! This shouldn't happen! */
+                printk(KERN_NOTICE "ip_fw_demasq_esp(): ");
+                printk("SPI from %s is IPSEC_INIT_SQUELCHED - modify ip_masq.c!\n", in_ntoa(iph->saddr));
+                return 0;
+        }
+
+ 	/*
+ 	 *      Look for a masq table entry and reroute if found
+         */
+
+        ms = ip_masq_in_get_ipsec(IPPROTO_ESP,
+                iph->saddr, fake_sport,
+                iph->daddr, 0,
+                i_spi);
+
+        if (ms != NULL)
+        {
+                /* delete the expiration timer */
+		ip_masq_set_expire(ms,0);
+
+                iph->daddr = ms->saddr;
+
+                if (ms->ispi == 0) {
+#ifdef DEBUG_IP_MASQUERADE_IPSEC
+                        printk(KERN_INFO "ip_fw_demasq_esp(): ");
+                        printk("resp from %s SPI %lX", in_ntoa(iph->saddr), ntohl(i_spi));
+                        printk(" routed to %s (SPI %lX)\n", in_ntoa(ms->saddr), ntohl(ms->ospi));
+#endif /* DEBUG_IP_MASQUERADE_IPSEC */
+		        save_flags(flags);
+		        cli();
+		        ip_masq_unhash(ms);
+		        ms->ispi = i_spi;
+		        ms->dport = fake_sport;
+		        ip_masq_hash(ms);
+		        restore_flags(flags);
+                }
+                
+                /*
+                 * resum checksums and set timeout
+                 */
+		ip_masq_set_expire(ms, MASQUERADE_EXPIRE_IPSEC);
+                ip_send_check(iph);
+
+#ifdef DEBUG_IP_MASQUERADE_IPSEC_VERBOSE
+                printk(KERN_DEBUG "MASQ: ESP I-routed to %s\n", in_ntoa(iph->daddr));
+#endif /* DEBUG_IP_MASQUERADE_IPSEC_VERBOSE */
+                return 1;
+ 	}
+
+ 	/* sorry, all this trouble for a no-hit :) */
+        printk(KERN_INFO "ip_fw_demasq_esp(): ");
+	printk("Inbound from %s SPI %lX has no masq table entry.\n", in_ntoa(iph->saddr), ntohl(i_spi));
+ 	return 0;
+}
+
+static struct symbol_table ipsec_masq_syms = {
+#include <linux/symtab_begin.h>
+	X(ip_masq_out_get_ipsec),
+	X(ip_masq_in_get_ipsec),
+	X(ip_masq_out_get_isakmp),
+	X(ip_masq_in_get_isakmp),
+	X(ip_fw_masq_esp),
+	X(ip_fw_demasq_esp),
+#include <linux/symtab_end.h>
+};
+
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
+
+
 int ip_fw_masquerade(struct sk_buff **skb_ptr, struct device *dev)
 {
 	struct sk_buff  *skb=*skb_ptr;
@@ -1100,10 +2240,38 @@
 
         if (iph->protocol==IPPROTO_ICMP) 
             return (ip_fw_masq_icmp(skb_ptr,dev));
-#ifdef CONFIG_IP_MASQUERADE_PPTP
         if (iph->protocol==IPPROTO_GRE) 
+#ifdef CONFIG_IP_MASQUERADE_PPTP
             return (ip_fw_masq_gre(skb_ptr,dev));
+#else
+        {
+                /* received the traffic but can't handle it - let user know. */
+                printk(KERN_INFO "MASQ: %s %s ", "GRE", in_ntoa(iph->saddr));
+                printk("-> %s: ", in_ntoa(iph->daddr));
+                printk("%s Masq not enabled - reconfigure kernel\n", "PPTP");
+                return -1;
+        }
 #endif /* CONFIG_IP_MASQUERADE_PPTP */
+        if (iph->protocol==IPPROTO_ESP) 
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+            return (ip_fw_masq_esp(skb_ptr,dev));
+#else
+        {
+                /* received the traffic but can't handle it - let user know. */
+                printk(KERN_INFO "MASQ: %s %s ", "ESP", in_ntoa(iph->saddr));
+                printk("-> %s: ", in_ntoa(iph->daddr));
+                printk("%s Masq not enabled - reconfigure kernel\n", "IPSEC/ISAKMP");
+                return -1;
+        }
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
+        if (iph->protocol==IPPROTO_AH) 
+        {
+                /* received the traffic but can't handle it - let user know. */
+                printk(KERN_INFO "MASQ: %s %s ", "AH", in_ntoa(iph->saddr));
+                printk("-> %s: ", in_ntoa(iph->daddr));
+                printk("protocol cannot be masqueraded.\n");
+                return -1;
+        }
 	if (iph->protocol!=IPPROTO_UDP && iph->protocol!=IPPROTO_TCP)
 		return -1;
 
@@ -1120,6 +2288,7 @@
 #endif
 
         ms = ip_masq_out_get(iph);
+
 	if (ms!=NULL) {
                 ip_masq_set_expire(ms,0);
                 
@@ -1197,8 +2366,29 @@
                         	         0);
                 if (ms == NULL)
 			return -1;
+
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+                if (iph->protocol == IPPROTO_UDP && ntohs(portptr[0]) == UDP_PORT_ISAKMP && ntohs(portptr[1]) == UDP_PORT_ISAKMP) {
+                        /* save the initiator cookie */
+                        ms->ospi = *((__u32 *)&portptr[4]);
+                }
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
  	}
 
+#ifdef CONFIG_IP_MASQUERADE_PPTP
+#ifdef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+	if (iph->protocol == IPPROTO_TCP && ntohs(portptr[1]) == PPTP_CONTROL_PORT)
+	{
+                /*
+                 * Packet sent to PPTP control port. Process it.
+                 * May change call ID word in request, but
+                 * packet length will not change.
+                 */
+		ip_masq_pptp(skb, ms, dev);
+	}
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
+#endif /* CONFIG_IP_MASQUERADE_PPTP */
+
  	/*
  	 *	Change the fragments origin
  	 */
@@ -1722,11 +2912,12 @@
  	__u16	*portptr;
  	struct ip_masq	*ms;
 	unsigned short len;
-	unsigned long 	timeout;
+	unsigned long 	timeout = MASQUERADE_EXPIRE_TCP;
 #ifdef CONFIG_IP_MASQUERADE_IPAUTOFW 
  	struct ip_autofw *af;
 #endif /* CONFIG_IP_MASQUERADE_IPAUTOFW */
 
+
 	switch (iph->protocol) {
 	case IPPROTO_ICMP:
 		return(ip_fw_demasq_icmp(skb_p, dev));
@@ -1734,6 +2925,10 @@
 	case IPPROTO_GRE:
 		return(ip_fw_demasq_gre(skb_p, dev));
 #endif /* CONFIG_IP_MASQUERADE_PPTP */
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+	case IPPROTO_ESP:
+		return(ip_fw_demasq_esp(skb_p, dev));
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
 	case IPPROTO_TCP:
 	case IPPROTO_UDP:
 		/* Make sure packet is in the masq range */
@@ -1746,6 +2941,9 @@
 		    && !ip_autofw_check_direct(portptr[1], iph->protocol)
 		    && !ip_autofw_check_port(portptr[1], iph->protocol)
 #endif /* CONFIG_IP_MASQUERADE_IPAUTOFW */
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+                    && ((iph->protocol != IPPROTO_UDP) || (ntohs(portptr[0]) != UDP_PORT_ISAKMP) || (ntohs(portptr[1]) != UDP_PORT_ISAKMP))
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
 			)
 			return 0;
 
@@ -1868,6 +3066,20 @@
                         len = ntohs(iph->tot_len) - (iph->ihl * 4);
                 }
 
+#ifdef CONFIG_IP_MASQUERADE_PPTP
+#ifdef CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT
+                if (iph->protocol == IPPROTO_TCP && ntohs(portptr[0]) == PPTP_CONTROL_PORT)
+                {
+                        /*
+                         * Packet received from PPTP control port. Process it.
+                         * May change call ID word in request, but
+                         * packet length will not change.
+                         */
+                        ip_masq_pptp(skb, ms, dev);
+                }
+#endif /* CONFIG_IP_MASQUERADE_PPTP_MULTICLIENT */
+#endif /* CONFIG_IP_MASQUERADE_PPTP */
+
                 /*
                  * Yug! adjust UDP/TCP and IP checksums, also update
 		 * timeouts.
@@ -2041,6 +3253,12 @@
 int ip_masq_init(void)
 {
         register_symtab (&ip_masq_syms);
+#ifdef CONFIG_IP_MASQUERADE_PPTP
+        register_symtab (&pptp_masq_syms);
+#endif /* CONFIG_IP_MASQUERADE_PPTP */
+#ifdef CONFIG_IP_MASQUERADE_IPSEC
+        register_symtab (&ipsec_masq_syms);
+#endif /* CONFIG_IP_MASQUERADE_IPSEC */
 #ifdef CONFIG_PROC_FS        
 	proc_net_register(&(struct proc_dir_entry) {
 		PROC_NET_IPMSQHST, 13, "ip_masquerade",
diff -urN linux-2.0.37-pre6/pot linux-2.0.37-pre7/pot
--- linux-2.0.37-pre6/pot	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/pot	1969-12-31 16:00:00.000000000 -0800
@@ -1,410 +0,0 @@
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o init/main.o init/main.c
-dnsdomainname: Host name lookup failure
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DUTS_MACHINE='"i386"' -c -o init/version.o init/version.c
-set -e; for i in kernel drivers mm fs net ipc lib arch/i386/kernel arch/i386/mm arch/i386/lib; do make -C $i; done
-make[1]: Entering directory `/usr/src/linux/kernel'
-make all_targets
-make[2]: Entering directory `/usr/src/linux/kernel'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODVERSIONS -DEXPORT_SYMTAB -c ksyms.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -fno-omit-frame-pointer -c sched.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o fork.o fork.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o exec_domain.o exec_domain.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o panic.o panic.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o printk.o printk.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sys.o sys.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o module.o module.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o exit.o exit.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o signal.o signal.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o itimer.o itimer.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o info.o info.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o time.o time.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o softirq.o softirq.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o resource.o resource.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sysctl.o sysctl.c
-rm -f kernel.o
-ld -m elf_i386  -r -o kernel.o ksyms.o sched.o dma.o fork.o exec_domain.o panic.o printk.o sys.o module.o exit.o signal.o itimer.o info.o time.o softirq.o resource.o sysctl.o
-make[2]: Leaving directory `/usr/src/linux/kernel'
-make[1]: Leaving directory `/usr/src/linux/kernel'
-make[1]: Entering directory `/usr/src/linux/drivers'
-set -e; for i in block char net  pci scsi cdrom; do make -C $i; done
-make[2]: Entering directory `/usr/src/linux/drivers/block'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/drivers/block'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ll_rw_blk.o ll_rw_blk.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o genhd.o genhd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o floppy.o floppy.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ide.o ide.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o rz1000.o rz1000.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o cmd640.o cmd640.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o triton.o triton.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ide-cd.o ide-cd.c
-rm -f block.a
-ar  rcs block.a  ll_rw_blk.o genhd.o floppy.o ide.o rz1000.o cmd640.o triton.o ide-cd.o
-make[3]: Leaving directory `/usr/src/linux/drivers/block'
-make[2]: Leaving directory `/usr/src/linux/drivers/block'
-make[2]: Entering directory `/usr/src/linux/drivers/char'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/drivers/char'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODVERSIONS -DEXPORT_SYMTAB -c serial.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODVERSIONS -DEXPORT_SYMTAB -c misc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o tty_io.o tty_io.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o n_tty.o n_tty.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o console.o console.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o tty_ioctl.o tty_ioctl.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o pty.o pty.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o vt.o vt.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o mem.o mem.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o vc_screen.o vc_screen.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o random.o random.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o consolemap.o consolemap.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o selection.o selection.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o keyboard.o keyboard.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o psaux.o psaux.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o rtc.o rtc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o vga.o vga.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o vesa_blank.o vesa_blank.c
-rm -f char.a
-ar  rcs char.a serial.o misc.o tty_io.o n_tty.o console.o tty_ioctl.o pty.o vt.o mem.o vc_screen.o random.o consolemap.o selection.o keyboard.o defkeymap.o psaux.o rtc.o vga.o vesa_blank.o
-make[3]: Leaving directory `/usr/src/linux/drivers/char'
-make[2]: Leaving directory `/usr/src/linux/drivers/char'
-make[2]: Entering directory `/usr/src/linux/drivers/net'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/drivers/net'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o auto_irq.o auto_irq.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c Space.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o net_init.o net_init.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o loopback.o loopback.c
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o 3c509.o 3c509.c
-rm -f net.a
-ar  rcs net.a  auto_irq.o Space.o net_init.o loopback.o 3c509.o
-make[3]: Leaving directory `/usr/src/linux/drivers/net'
-make[2]: Leaving directory `/usr/src/linux/drivers/net'
-make[2]: Entering directory `/usr/src/linux/drivers/pci'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/drivers/pci'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o pci.o pci.c
-rm -f pci.a
-ar  rcs pci.a  pci.o
-make[3]: Leaving directory `/usr/src/linux/drivers/pci'
-make[2]: Leaving directory `/usr/src/linux/drivers/pci'
-make[2]: Entering directory `/usr/src/linux/drivers/scsi'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/drivers/scsi'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODVERSIONS -DEXPORT_SYMTAB -c scsi_syms.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o hosts.o hosts.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o scsi.o scsi.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o scsi_ioctl.o scsi_ioctl.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o constants.o constants.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o scsicam.o scsicam.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o scsi_proc.o scsi_proc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sd.o sd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sd_ioctl.o sd_ioctl.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o BusLogic.o BusLogic.c
-rm -f scsi.a
-ar  rcs scsi.a scsi_syms.o  hosts.o scsi.o scsi_ioctl.o constants.o scsicam.o scsi_proc.o sd.o sd_ioctl.o BusLogic.o
-make[3]: Leaving directory `/usr/src/linux/drivers/scsi'
-make[2]: Leaving directory `/usr/src/linux/drivers/scsi'
-make[2]: Entering directory `/usr/src/linux/drivers/cdrom'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/drivers/cdrom'
-rm -f cdrom.a
-ar  rcs cdrom.a  
-make[3]: Leaving directory `/usr/src/linux/drivers/cdrom'
-make[2]: Leaving directory `/usr/src/linux/drivers/cdrom'
-make all_targets
-make[2]: Entering directory `/usr/src/linux/drivers'
-make[2]: Nothing to be done for `all_targets'.
-make[2]: Leaving directory `/usr/src/linux/drivers'
-make[1]: Leaving directory `/usr/src/linux/drivers'
-make[1]: Entering directory `/usr/src/linux/mm'
-make all_targets
-make[2]: Entering directory `/usr/src/linux/mm'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o memory.o memory.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o mmap.o mmap.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o filemap.o filemap.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o mprotect.o mprotect.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o mlock.o mlock.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o mremap.o mremap.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o kmalloc.o kmalloc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o vmalloc.o vmalloc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o swap.o swap.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o vmscan.o vmscan.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o page_io.o page_io.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o page_alloc.o page_alloc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o swap_state.o swap_state.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o swapfile.o swapfile.c
-rm -f mm.o
-ld -m elf_i386  -r -o mm.o  memory.o mmap.o filemap.o mprotect.o mlock.o mremap.o kmalloc.o vmalloc.o swap.o vmscan.o page_io.o page_alloc.o swap_state.o swapfile.o
-make[2]: Leaving directory `/usr/src/linux/mm'
-make[1]: Leaving directory `/usr/src/linux/mm'
-make[1]: Entering directory `/usr/src/linux/fs'
-set -e; for i in ext2 proc; do make -C $i; done
-make[2]: Entering directory `/usr/src/linux/fs/ext2'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/fs/ext2'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o acl.o acl.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o balloc.o balloc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o bitmap.o bitmap.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o file.o file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o fsync.o fsync.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ialloc.o ialloc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ioctl.o ioctl.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o namei.o namei.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o super.o super.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o symlink.o symlink.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o truncate.o truncate.c
-rm -f ext2.o
-ld -m elf_i386  -r -o ext2.o  acl.o balloc.o bitmap.o dir.o file.o fsync.o ialloc.o inode.o ioctl.o namei.o super.o symlink.o truncate.o
-make[3]: Leaving directory `/usr/src/linux/fs/ext2'
-make[2]: Leaving directory `/usr/src/linux/fs/ext2'
-make[2]: Entering directory `/usr/src/linux/fs/proc'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/fs/proc'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODVERSIONS -DEXPORT_SYMTAB -c procfs_syms.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o root.o root.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o base.o base.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o mem.o mem.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o link.o link.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o fd.o fd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o array.o array.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o kmsg.o kmsg.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o net.o net.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o scsi.o scsi.c
-rm -f proc.o
-ld -m elf_i386  -r -o proc.o procfs_syms.o inode.o root.o base.o mem.o link.o fd.o array.o kmsg.o net.o scsi.o
-make[3]: Leaving directory `/usr/src/linux/fs/proc'
-make[2]: Leaving directory `/usr/src/linux/fs/proc'
-make all_targets
-make[2]: Entering directory `/usr/src/linux/fs'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o open.o open.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o read_write.o read_write.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o devices.o devices.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o file_table.o file_table.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o buffer.o buffer.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o super.o super.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o block_dev.o block_dev.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o stat.o stat.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o exec.o exec.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o pipe.o pipe.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o namei.o namei.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o fcntl.o fcntl.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ioctl.o ioctl.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o readdir.o readdir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o select.o select.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o fifo.o fifo.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o locks.o locks.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o filesystems.o filesystems.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o dcache.o dcache.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o bad_inode.o bad_inode.c
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o binfmt_elf.o binfmt_elf.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o binfmt_script.o binfmt_script.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o dquot.o dquot.c
-rm -f fs.o
-ld -m elf_i386  -r -o fs.o  open.o read_write.o inode.o devices.o file_table.o buffer.o super.o  block_dev.o stat.o exec.o pipe.o namei.o fcntl.o ioctl.o readdir.o select.o fifo.o locks.o filesystems.o dcache.o bad_inode.o binfmt_elf.o binfmt_script.o dquot.o
-rm -f filesystems.a
-ar  rcs filesystems.a  ext2/ext2.o proc/proc.o
-make[2]: Leaving directory `/usr/src/linux/fs'
-make[1]: Leaving directory `/usr/src/linux/fs'
-make[1]: Entering directory `/usr/src/linux/net'
-set -e; for i in core ethernet unix 802 ipv4; do make -C $i; done
-make[2]: Entering directory `/usr/src/linux/net/core'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/net/core'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODVERSIONS -DEXPORT_SYMTAB -c firewall.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sock.o sock.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o skbuff.o skbuff.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o iovec.o iovec.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o datagram.o datagram.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sysctl_net_core.o sysctl_net_core.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o dev.o dev.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o dev_mcast.o dev_mcast.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o net_alias.o net_alias.c
-rm -f core.o
-ld -m elf_i386  -r -o core.o firewall.o sock.o skbuff.o iovec.o datagram.o sysctl_net_core.o dev.o dev_mcast.o net_alias.o
-make[3]: Leaving directory `/usr/src/linux/net/core'
-make[2]: Leaving directory `/usr/src/linux/net/core'
-make[2]: Entering directory `/usr/src/linux/net/ethernet'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/net/ethernet'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o eth.o eth.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sysctl_net_ether.o sysctl_net_ether.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o pe2.o pe2.c
-rm -f ethernet.o
-ld -m elf_i386  -r -o ethernet.o  eth.o sysctl_net_ether.o pe2.o
-make[3]: Leaving directory `/usr/src/linux/net/ethernet'
-make[2]: Leaving directory `/usr/src/linux/net/ethernet'
-make[2]: Entering directory `/usr/src/linux/net/unix'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/net/unix'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o af_unix.o af_unix.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o garbage.o garbage.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sysctl_net_unix.o sysctl_net_unix.c
-rm -f unix.o
-ld -m elf_i386  -r -o unix.o  af_unix.o garbage.o sysctl_net_unix.o
-make[3]: Leaving directory `/usr/src/linux/net/unix'
-make[2]: Leaving directory `/usr/src/linux/net/unix'
-make[2]: Entering directory `/usr/src/linux/net/802'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/net/802'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODVERSIONS -DEXPORT_SYMTAB -c p8022.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODVERSIONS -DEXPORT_SYMTAB -c psnap.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODVERSIONS -DEXPORT_SYMTAB -c p8022tr.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o p8023.o p8023.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sysctl_net_802.o sysctl_net_802.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o tr.o tr.c
-rm -f 802.o
-ld -m elf_i386  -r -o 802.o p8022.o psnap.o p8022tr.o p8023.o sysctl_net_802.o tr.o
-make[3]: Leaving directory `/usr/src/linux/net/802'
-make[2]: Leaving directory `/usr/src/linux/net/802'
-make[2]: Entering directory `/usr/src/linux/net/ipv4'
-make all_targets
-make[3]: Entering directory `/usr/src/linux/net/ipv4'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o utils.o utils.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o route.o route.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o proc.o proc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o timer.o timer.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o protocol.o protocol.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o packet.o packet.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ip_input.o ip_input.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ip_fragment.o ip_fragment.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ip_forward.o ip_forward.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ip_options.o ip_options.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ip_output.o ip_output.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ip_sockglue.o ip_sockglue.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o tcp.o tcp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o tcp_input.o tcp_input.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o tcp_output.o tcp_output.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o tcp_timer.o tcp_timer.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o raw.o raw.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o udp.o udp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o arp.o arp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o icmp.o icmp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o devinet.o devinet.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o af_inet.o af_inet.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o igmp.o igmp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ip_fw.o ip_fw.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sysctl_net_ipv4.o sysctl_net_ipv4.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ip_alias.o ip_alias.c
-rm -f ipv4.o
-ld -m elf_i386  -r -o ipv4.o  utils.o route.o proc.o timer.o protocol.o packet.o ip_input.o ip_fragment.o ip_forward.o ip_options.o ip_output.o ip_sockglue.o tcp.o tcp_input.o tcp_output.o tcp_timer.o raw.o udp.o arp.o icmp.o devinet.o af_inet.o igmp.o ip_fw.o sysctl_net_ipv4.o ip_alias.o
-make[3]: Leaving directory `/usr/src/linux/net/ipv4'
-make[2]: Leaving directory `/usr/src/linux/net/ipv4'
-make all_targets
-make[2]: Entering directory `/usr/src/linux/net'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODVERSIONS -DEXPORT_SYMTAB -c netsyms.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o socket.o socket.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o protocols.o protocols.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sysctl_net.o sysctl_net.c
-rm -f network.a
-ar  rcs network.a netsyms.o socket.o protocols.o sysctl_net.o core/core.o ethernet/ethernet.o unix/unix.o 802/802.o ipv4/ipv4.o
-make[2]: Leaving directory `/usr/src/linux/net'
-make[1]: Leaving directory `/usr/src/linux/net'
-make[1]: Entering directory `/usr/src/linux/ipc'
-make all_targets
-make[2]: Entering directory `/usr/src/linux/ipc'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o util.o util.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o msg.o msg.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sem.o sem.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o shm.o shm.c
-rm -f ipc.o
-ld -m elf_i386  -r -o ipc.o  util.o msg.o sem.o shm.o
-make[2]: Leaving directory `/usr/src/linux/ipc'
-make[1]: Leaving directory `/usr/src/linux/ipc'
-make[1]: Entering directory `/usr/src/linux/lib'
-make all_targets
-make[2]: Entering directory `/usr/src/linux/lib'
-rm -f lib.a
-ar  rcs lib.a  errno.o ctype.o string.o vsprintf.o
-make[2]: Leaving directory `/usr/src/linux/lib'
-make[1]: Leaving directory `/usr/src/linux/lib'
-make[1]: Entering directory `/usr/src/linux/arch/i386/kernel'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o process.o process.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o signal.o signal.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o traps.o traps.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o irq.o irq.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o vm86.o vm86.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o bios32.o bios32.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ptrace.o ptrace.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ioport.o ioport.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ldt.o ldt.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o setup.o setup.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o time.o time.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o sys_i386.o sys_i386.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o ksyms.o ksyms.c
-rm -f kernel.o
-ld -m elf_i386  -r -o kernel.o  process.o signal.o entry.o traps.o irq.o vm86.o bios32.o ptrace.o ioport.o ldt.o setup.o time.o sys_i386.o ksyms.o
-gcc -D__KERNEL__ -I/usr/src/linux/include -D__ASSEMBLY__ -traditional -c head.S -o head.o
-make[1]: Leaving directory `/usr/src/linux/arch/i386/kernel'
-make[1]: Entering directory `/usr/src/linux/arch/i386/mm'
-make all_targets
-make[2]: Entering directory `/usr/src/linux/arch/i386/mm'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o init.o init.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o fault.o fault.c
-rm -f mm.o
-ld -m elf_i386  -r -o mm.o  init.o fault.o
-make[2]: Leaving directory `/usr/src/linux/arch/i386/mm'
-make[1]: Leaving directory `/usr/src/linux/arch/i386/mm'
-make[1]: Entering directory `/usr/src/linux/arch/i386/lib'
-make all_targets
-make[2]: Entering directory `/usr/src/linux/arch/i386/lib'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486  -c -o checksum.o checksum.c
-rm -f lib.a
-ar  rcs lib.a  checksum.o semaphore.o delay.o
-make[2]: Leaving directory `/usr/src/linux/arch/i386/lib'
-make[1]: Leaving directory `/usr/src/linux/arch/i386/lib'
-ld -m elf_i386 -Ttext 0x100000 -e stext arch/i386/kernel/head.o init/main.o init/version.o \
-	arch/i386/kernel/kernel.o arch/i386/mm/mm.o kernel/kernel.o mm/mm.o fs/fs.o ipc/ipc.o net/network.a \
-	fs/filesystems.a \
-	drivers/block/block.a drivers/char/char.a drivers/net/net.a drivers/cdrom/cdrom.a drivers/scsi/scsi.a drivers/pci/pci.a \
-	/usr/src/linux/arch/i386/lib/lib.a /usr/src/linux/lib/lib.a /usr/src/linux/arch/i386/lib/lib.a -o vmlinux
-nm vmlinux | grep -v '\(compiled\)\|\(\.o$\)\|\( a \)' | sort > System.map
-make[1]: Entering directory `/usr/src/linux/arch/i386/boot'
-gcc -D__KERNEL__ -I/usr/src/linux/include -E -D__ELF__ -traditional -DSVGA_MODE=NORMAL_VGA  bootsect.S -o bootsect.s
-as86 -0 -a -o bootsect.o bootsect.s
-ld86 -0 -s -o bootsect bootsect.o
-gcc -D__KERNEL__ -I/usr/src/linux/include -E -D__ELF__ -traditional -DSVGA_MODE=NORMAL_VGA  setup.S -o setup.s
-as86 -0 -a -o setup.o setup.s
-ld86 -0 -s -o setup setup.o
-make[2]: Entering directory `/usr/src/linux/arch/i386/boot/compressed'
-tmppiggy=/tmp/$$piggy; \
-rm -f $tmppiggy $tmppiggy.gz $tmppiggy.lnk; \
-if hash encaps 2> /dev/null; then \
-  objdump -k -q  -o 0x100000 /usr/src/linux/vmlinux > $tmppiggy; \
-else \
-  objcopy -O binary -R .note -R .comment -R .stab -R .stabstr /usr/src/linux/vmlinux $tmppiggy; \
-fi; \
-gzip -f -9 < $tmppiggy > $tmppiggy.gz; \
-if hash encaps 2> /dev/null; then \
-  encaps --target elf32-i386 piggy.o $tmppiggy.gz input_data input_len; \
-else \
-  echo "SECTIONS { .data : { input_len = .; LONG(input_data_end - input_data) input_data = .; *(.data) input_data_end = .; }}" > $tmppiggy.lnk; \
-  ld -m elf_i386 -m elf_i386 -r -o piggy.o -b binary $tmppiggy.gz -b elf32-i386 -T $tmppiggy.lnk; \
-fi; \
-rm -f $tmppiggy $tmppiggy.gz $tmppiggy.lnk
-ld -m elf_i386 -Ttext 0x1000 -e startup_32  -o vmlinux head.o misc.o piggy.o
-make[2]: Leaving directory `/usr/src/linux/arch/i386/boot/compressed'
-if hash encaps 2> /dev/null; then \
-  objdump -k -q  -o 0x1000 compressed/vmlinux > compressed/vmlinux.out; \
-else \
-  objcopy -O binary -R .note -R .comment -R .stab -R .stabstr compressed/vmlinux compressed/vmlinux.out; \
-fi
-tools/build bootsect setup compressed/vmlinux.out CURRENT > zImage
-Root device is (22, 2)
-Boot sector 512 bytes.
-Setup is 4428 bytes.
-System is 386 kB
-sync
-make[1]: Leaving directory `/usr/src/linux/arch/i386/boot'
diff -urN linux-2.0.37-pre6/pot2 linux-2.0.37-pre7/pot2
--- linux-2.0.37-pre6/pot2	2003-08-15 15:04:36.000000000 -0700
+++ linux-2.0.37-pre7/pot2	1969-12-31 16:00:00.000000000 -0800
@@ -1,770 +0,0 @@
-make[1]: Entering directory `/usr/src/linux/kernel'
-make[1]: Nothing to be done for `modules'.
-make[1]: Leaving directory `/usr/src/linux/kernel'
-make[1]: Entering directory `/usr/src/linux/drivers'
-set -e; for i in block char net  scsi cdrom isdn; do make -C $i modules; done
-make[2]: Entering directory `/usr/src/linux/drivers/block'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rd.o rd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o loop.o loop.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o xd.o xd.c
-set -e; for i in paride; do make -C $i modules; done
-make[3]: Entering directory `/usr/src/linux/drivers/block/paride'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -E -D__GENKSYMS__ paride.c | /sbin/genksyms /usr/src/linux/include/linux/modules
-In file included from paride.c:21:
-/usr/src/linux/include/linux/module.h:11: warning: `_set_ver' redefined
-/usr/src/linux/include/linux/modversions.h:5: warning: this is the location of the previous definition
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DEXPORT_SYMTAB -c paride.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o pd.o pd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o pcd.o pcd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o pf.o pf.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o pt.o pt.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o pg.o pg.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o aten.o aten.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o bpck.o bpck.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o comm.o comm.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dstr.o dstr.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o kbic.o kbic.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o epat.o epat.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o epia.o epia.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o fit2.o fit2.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o fit3.o fit3.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o frpw.o frpw.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o friq.o friq.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o on20.o on20.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o on26.o on26.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ktti.o ktti.c
-rm -f $TOPDIR/modules/PARIDE_MODULES
-echo  paride.o pd.o pcd.o pf.o pt.o pg.o aten.o bpck.o comm.o dstr.o kbic.o epat.o epia.o fit2.o fit3.o frpw.o friq.o on20.o on26.o ktti.o >> $TOPDIR/modules/PARIDE_MODULES
-echo drivers/block/paride/
-drivers/block/paride/
-cd $TOPDIR/modules; for i in  paride.o pd.o pcd.o pf.o pt.o pg.o aten.o bpck.o comm.o dstr.o kbic.o epat.o epia.o fit2.o fit3.o frpw.o friq.o on20.o on26.o ktti.o; do \
-    ln -sf ../drivers/block/paride//$i .; done
-make[3]: Leaving directory `/usr/src/linux/drivers/block/paride'
-rm -f $TOPDIR/modules/BLOCK_MODULES
-for i in paride; do \
-    echo `basename $i`.o >> $TOPDIR/modules/BLOCK_MODULES; done
-echo   rd.o loop.o xd.o >> $TOPDIR/modules/BLOCK_MODULES
-echo drivers/block/
-drivers/block/
-cd $TOPDIR/modules; for i in   rd.o loop.o xd.o; do \
-    ln -sf ../drivers/block//$i .; done
-make[2]: Leaving directory `/usr/src/linux/drivers/block'
-make[2]: Entering directory `/usr/src/linux/drivers/char'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o cyclades.o cyclades.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o stallion.o stallion.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o istallion.o istallion.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o riscom8.o riscom8.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o specialix.o specialix.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o atixlmouse.o atixlmouse.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o busmouse.o busmouse.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o lp.o lp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o msbusmouse.o msbusmouse.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o softdog.o softdog.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o pcwd.o pcwd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o wdt.o wdt.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o scc.o scc.c
-echo drivers/char/
-drivers/char/
-cd $TOPDIR/modules; for i in   cyclades.o stallion.o istallion.o riscom8.o specialix.o atixlmouse.o busmouse.o lp.o msbusmouse.o softdog.o pcwd.o wdt.o scc.o; do \
-    ln -sf ../drivers/char//$i .; done
-make[2]: Leaving directory `/usr/src/linux/drivers/char'
-make[2]: Entering directory `/usr/src/linux/drivers/net'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DEXPORT_SYMTAB -c ppp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DEXPORT_SYMTAB -c slhc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DEXPORT_SYMTAB -c hdlcdrv.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ibmtr.o ibmtr.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o shaper.o shaper.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o new_tunnel.o new_tunnel.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o hp100.o hp100.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o smc9194.o smc9194.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c wd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c 3c503.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c ne.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c hp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o hp-plus.o hp-plus.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o smc-ultra.o smc-ultra.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o smc-ultra32.o smc-ultra32.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o e2100.o e2100.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c plip.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o bsd_comp.o bsd_comp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -c slip.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -c strip.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -c dummy.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c de600.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c de620.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c lance.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o at1700.o at1700.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o fmv18x.o fmv18x.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o 3c501.o 3c501.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o 3c507.o 3c507.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o 3c515.o 3c515.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o 3c59x.o 3c59x.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o via-rhine.o via-rhine.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o eexpress.o eexpress.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o eepro.o eepro.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o eepro100.o eepro100.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o epic100.o epic100.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ne2k-pci.o ne2k-pci.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o pcnet32.o pcnet32.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rtl8139.o rtl8139.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o yellowfin.o yellowfin.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o wavelan.o wavelan.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c depca.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c ewrk3.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o atp.o atp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DDE4X5_AUTOSENSE=AUTO -c de4x5.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ni52.o ni52.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ni65.o ni65.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c 3c505.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ac3200.o ac3200.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o apricot.o apricot.c
-apricot.c: In function `init_i596_mem':
-apricot.c:266: warning: assignment discards `volatile' from pointer target type
-apricot.c:267: warning: assignment discards `volatile' from pointer target type
-apricot.c:291: warning: passing arg 2 of `i596_add_cmd' discards `volatile' from pointer target type
-apricot.c:295: warning: passing arg 2 of `i596_add_cmd' discards `volatile' from pointer target type
-apricot.c:298: warning: passing arg 2 of `i596_add_cmd' discards `volatile' from pointer target type
-apricot.c: In function `i596_cleanup_cmd':
-apricot.c:419: warning: unused variable `count'
-apricot.c: In function `i596_interrupt':
-apricot.c:829: warning: unused variable `count'
-apricot.c: In function `set_multicast_list':
-apricot.c:999: warning: passing arg 2 of `i596_add_cmd' discards `volatile' from pointer target type
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c tulip.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o tlan.o tlan.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o arcnet.o arcnet.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o eth16i.o eth16i.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o mkiss.o mkiss.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c pi2.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o pt.o pt.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o bpqether.o bpqether.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o baycom.o baycom.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o 8390.o 8390.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o eql.o eql.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dlci.o dlci.c
-gcc -D__KERNEL__ -I/usr/src/linux/include  -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -c dgrs.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rcpci45.o rcpci45.c
-ld -m elf_i386 -r -o rcpci.o rcpci45.o rclanmtl.o
-set -e; for i in  soundmodem; do make -C $i modules; done
-make[3]: Entering directory `/usr/src/linux/drivers/net/soundmodem'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sm.o sm.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sm_sbc.o sm_sbc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sm_wss.o sm_wss.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sm_afsk1200.o sm_afsk1200.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sm_afsk2400_7.o sm_afsk2400_7.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sm_afsk2400_8.o sm_afsk2400_8.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sm_afsk2666.o sm_afsk2666.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sm_hapn4800.o sm_hapn4800.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sm_psk4800.o sm_psk4800.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sm_fsk9600.o sm_fsk9600.c
-rm -f soundmodem.o
-ld -m elf_i386  -r -o soundmodem.o  sm.o sm_sbc.o sm_wss.o sm_afsk1200.o sm_afsk2400_7.o sm_afsk2400_8.o sm_afsk2666.o sm_hapn4800.o sm_psk4800.o sm_fsk9600.o
-echo drivers/net/soundmodem/
-drivers/net/soundmodem/
-cd $TOPDIR/modules; for i in  soundmodem.o; do \
-    ln -sf ../drivers/net/soundmodem//$i .; done
-make[3]: Leaving directory `/usr/src/linux/drivers/net/soundmodem'
-rm -f $TOPDIR/modules/NET_MODULES
-for i in  soundmodem; do \
-    echo `basename $i`.o >> $TOPDIR/modules/NET_MODULES; done
-echo ppp.o slhc.o hdlcdrv.o  ibmtr.o shaper.o new_tunnel.o hp100.o smc9194.o wd.o 3c503.o ne.o hp.o hp-plus.o smc-ultra.o smc-ultra32.o e2100.o plip.o bsd_comp.o slip.o strip.o dummy.o de600.o de620.o lance.o at1700.o fmv18x.o 3c501.o 3c507.o 3c515.o 3c59x.o via-rhine.o eexpress.o eepro.o eepro100.o epic100.o ne2k-pci.o pcnet32.o rtl8139.o yellowfin.o wavelan.o depca.o ewrk3.o atp.o de4x5.o ni52.o ni65.o 3c505.o ac3200.o apricot.o tulip.o tlan.o arcnet.o eth16i.o mkiss.o pi2.o pt.o bpqether.o baycom.o 8390.o eql.o dlci.o dgrs.o rcpci.o >> $TOPDIR/modules/NET_MODULES
-echo drivers/net/
-drivers/net/
-cd $TOPDIR/modules; for i in ppp.o slhc.o hdlcdrv.o  ibmtr.o shaper.o new_tunnel.o hp100.o smc9194.o wd.o 3c503.o ne.o hp.o hp-plus.o smc-ultra.o smc-ultra32.o e2100.o plip.o bsd_comp.o slip.o strip.o dummy.o de600.o de620.o lance.o at1700.o fmv18x.o 3c501.o 3c507.o 3c515.o 3c59x.o via-rhine.o eexpress.o eepro.o eepro100.o epic100.o ne2k-pci.o pcnet32.o rtl8139.o yellowfin.o wavelan.o depca.o ewrk3.o atp.o de4x5.o ni52.o ni65.o 3c505.o ac3200.o apricot.o tulip.o tlan.o arcnet.o eth16i.o mkiss.o pi2.o pt.o bpqether.o baycom.o 8390.o eql.o dlci.o dgrs.o rcpci.o; do \
-    ln -sf ../drivers/net//$i .; done
-make[2]: Leaving directory `/usr/src/linux/drivers/net'
-make[2]: Entering directory `/usr/src/linux/drivers/scsi'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o st.o st.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sr.o sr.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sr_ioctl.o sr_ioctl.c
-ld -m elf_i386 -m elf_i386 -r -o sr_mod.o sr.o sr_ioctl.o
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sg.o sg.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o advansys.o advansys.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ppa.o ppa.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o qlogicfas.o qlogicfas.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o qlogicisp.o qlogicisp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o atp870u.o atp870u.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ini9100u.o ini9100u.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o i91uscsi.o i91uscsi.c
-ld -m elf_i386 -r -o initio.o ini9100u.o i91uscsi.o
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DDEBUG_AHA152X -DAUTOCONF -c aha152x.c 
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o aha1542.o aha1542.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o aha1740.o aha1740.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -c -o aic7xxx.o aic7xxx.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -c tmscsim.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o AM53C974.o AM53C974.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o eata_dma.o eata_dma.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o eata_pio.o eata_pio.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o u14-34f.o u14-34f.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c gdth.c 
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o fdomain.o fdomain.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o in2000.o in2000.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DGENERIC_NCR5380_OVERRIDE="{{(NCR5380_map_type)0x350,5,0, BOARD_NCR53C400}};" -c g_NCR5380.c
-g_NCR5380.c: In function `generic_NCR5380_proc_info':
-g_NCR5380.c:617: warning: unused variable `dev'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o 53c7,8xx.o 53c7,8xx.c
-53c7,8xx.c:713: warning: `request_synchronous' defined but not used
-53c7,8xx.c:761: warning: `request_disconnect' defined but not used
-53c7,8xx.c:5415: warning: `ncr_state' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ncr53c8xx.o ncr53c8xx.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o pas16.o pas16.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DARBITRATE -DSLOW_HANDSHAKE -DFAST32 -c seagate.c 
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o wd7000.o wd7000.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o t128.o t128.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dtc.o dtc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ultrastor.o ultrastor.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o eata.o eata.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o NCR53c406a.o NCR53c406a.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sym53c416.o sym53c416.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -c megaraid.c
-rm -f $TOPDIR/modules/SCSI_MODULES
-echo   st.o sr_mod.o sg.o advansys.o ppa.o qlogicfas.o qlogicisp.o  atp870u.o  initio.o aha152x.o aha1542.o aha1740.o aic7xxx.o tmscsim.o AM53C974.o eata_dma.o eata_pio.o u14-34f.o gdth.o fdomain.o in2000.o g_NCR5380.o 53c7,8xx.o ncr53c8xx.o pas16.o seagate.o wd7000.o t128.o dtc.o ultrastor.o eata.o NCR53c406a.o sym53c416.o  megaraid.o >> $TOPDIR/modules/SCSI_MODULES
-echo drivers/scsi/
-drivers/scsi/
-cd $TOPDIR/modules; for i in   st.o sr_mod.o sg.o advansys.o ppa.o qlogicfas.o qlogicisp.o  atp870u.o  initio.o aha152x.o aha1542.o aha1740.o aic7xxx.o tmscsim.o AM53C974.o eata_dma.o eata_pio.o u14-34f.o gdth.o fdomain.o in2000.o g_NCR5380.o 53c7,8xx.o ncr53c8xx.o pas16.o seagate.o wd7000.o t128.o dtc.o ultrastor.o eata.o NCR53c406a.o sym53c416.o  megaraid.o; do \
-    ln -sf ../drivers/scsi//$i .; done
-make[2]: Leaving directory `/usr/src/linux/drivers/scsi'
-make[2]: Entering directory `/usr/src/linux/drivers/cdrom'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o cdrom.o cdrom.c
-cdrom.c: In function `register_cdrom':
-cdrom.c:67: warning: initialization discards `const' from pointer target type
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o aztcd.o aztcd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o cdu31a.o cdu31a.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o mcd.o mcd.c
-In file included from mcd.c:93:
-/usr/src/linux/include/linux/mcd.h:114: warning: #warning You have not edited mcd.h
-/usr/src/linux/include/linux/mcd.h:115: warning: #warning Perhaps irq and i/o settings are wrong.
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o mcdx.o mcdx.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sbpcd.o sbpcd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sonycd535.o sonycd535.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o gscd.o gscd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o cm206.o cm206.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o optcd.o optcd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sjcd.o sjcd.c
-rm -f $TOPDIR/modules/CDROM_MODULES
-echo   cdrom.o aztcd.o cdu31a.o mcd.o mcdx.o sbpcd.o sonycd535.o gscd.o cm206.o optcd.o sjcd.o >> $TOPDIR/modules/CDROM_MODULES
-echo drivers/cdrom/
-drivers/cdrom/
-cd $TOPDIR/modules; for i in   cdrom.o aztcd.o cdu31a.o mcd.o mcdx.o sbpcd.o sonycd535.o gscd.o cm206.o optcd.o sjcd.o; do \
-    ln -sf ../drivers/cdrom//$i .; done
-make[2]: Leaving directory `/usr/src/linux/drivers/cdrom'
-make[2]: Entering directory `/usr/src/linux/drivers/isdn'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DMODVERSIONS -DEXPORT_SYMTAB -c isdn_syms.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o isdn_common.o isdn_common.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o isdn_net.o isdn_net.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o isdn_tty.o isdn_tty.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o isdn_ppp.o isdn_ppp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o isdn_audio.o isdn_audio.c
-rm -f isdn.o
-ld -m elf_i386  -r -o isdn.o  isdn_syms.o  isdn_common.o isdn_net.o isdn_tty.o isdn_ppp.o isdn_audio.o
-set -e; for i in  hisax icn pcbit sc avmb1 isdnloop; do make -C $i modules; done
-make[3]: Entering directory `/usr/src/linux/drivers/isdn/hisax'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DMODVERSIONS -DEXPORT_SYMTAB -c config.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o isdnl1.o isdnl1.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o tei.o tei.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o isdnl2.o isdnl2.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o isdnl3.o isdnl3.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o lmgr.o lmgr.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o q931.o q931.c
-q931.c:211: warning: `fac_1tr6' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o callc.o callc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o fsm.o fsm.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -D CERTIFICATION=0 -c -o cert.o cert.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o l3dss1.o l3dss1.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o teles0.o teles0.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o isac.o isac.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o hscx.o hscx.c
-rm -f hisax.o
-ld -m elf_i386  -r -o hisax.o  config.o isdnl1.o tei.o isdnl2.o isdnl3.o lmgr.o q931.o callc.o fsm.o cert.o l3dss1.o teles0.o isac.o hscx.o     
-echo drivers/isdn/hisax/
-drivers/isdn/hisax/
-cd $TOPDIR/modules; for i in   hisax.o; do \
-    ln -sf ../drivers/isdn/hisax//$i .; done
-make[3]: Leaving directory `/usr/src/linux/drivers/isdn/hisax'
-make[3]: Entering directory `/usr/src/linux/drivers/isdn/icn'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o icn.o icn.c
-echo drivers/isdn/icn/
-drivers/isdn/icn/
-cd $TOPDIR/modules; for i in   icn.o; do \
-    ln -sf ../drivers/isdn/icn//$i .; done
-make[3]: Leaving directory `/usr/src/linux/drivers/isdn/icn'
-make[3]: Entering directory `/usr/src/linux/drivers/isdn/pcbit'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o module.o module.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o edss1.o edss1.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o drv.o drv.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o layer2.o layer2.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o capi.o capi.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o callbacks.o callbacks.c
-rm -f pcbit.o
-ld -m elf_i386  -r -o pcbit.o  module.o edss1.o drv.o layer2.o capi.o callbacks.o 
-echo drivers/isdn/pcbit/
-drivers/isdn/pcbit/
-cd $TOPDIR/modules; for i in   pcbit.o; do \
-    ln -sf ../drivers/isdn/pcbit//$i .; done
-make[3]: Leaving directory `/usr/src/linux/drivers/isdn/pcbit'
-make[3]: Entering directory `/usr/src/linux/drivers/isdn/sc'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o shmem.o shmem.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o init.o init.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o debug.o debug.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o packet.o packet.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o command.o command.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o event.o event.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ioctl.o ioctl.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o interrupt.o interrupt.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o message.o message.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o timer.o timer.c
-rm -f sc.o
-ld -m elf_i386  -r -o sc.o  shmem.o init.o debug.o packet.o command.o event.o ioctl.o interrupt.o message.o timer.o
-echo drivers/isdn/sc/
-drivers/isdn/sc/
-cd $TOPDIR/modules; for i in   sc.o; do \
-    ln -sf ../drivers/isdn/sc//$i .; done
-make[3]: Leaving directory `/usr/src/linux/drivers/isdn/sc'
-make[3]: Entering directory `/usr/src/linux/drivers/isdn/avmb1'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DEXPORT_SYMTAB -c capiutil.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DEXPORT_SYMTAB -c capidrv.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DEXPORT_SYMTAB -c b1pci.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o capi.o capi.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DMODVERSIONS -DEXPORT_SYMTAB -c b1capi.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o b1lli.o b1lli.c
-rm -f kernelcapi.o
-ld -m elf_i386  -r -o kernelcapi.o  b1capi.o  b1lli.o
-echo drivers/isdn/avmb1/
-drivers/isdn/avmb1/
-cd $TOPDIR/modules; for i in  capiutil.o capidrv.o b1pci.o  capi.o kernelcapi.o; do \
-    ln -sf ../drivers/isdn/avmb1//$i .; done
-make[3]: Leaving directory `/usr/src/linux/drivers/isdn/avmb1'
-make[3]: Entering directory `/usr/src/linux/drivers/isdn/isdnloop'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o isdnloop.o isdnloop.c
-echo drivers/isdn/isdnloop/
-drivers/isdn/isdnloop/
-cd $TOPDIR/modules; for i in   isdnloop.o; do \
-    ln -sf ../drivers/isdn/isdnloop//$i .; done
-make[3]: Leaving directory `/usr/src/linux/drivers/isdn/isdnloop'
-echo drivers/isdn/
-drivers/isdn/
-cd $TOPDIR/modules; for i in   isdn.o; do \
-    ln -sf ../drivers/isdn//$i .; done
-make[2]: Leaving directory `/usr/src/linux/drivers/isdn'
-make[1]: Leaving directory `/usr/src/linux/drivers'
-make[1]: Entering directory `/usr/src/linux/mm'
-make[1]: Nothing to be done for `modules'.
-make[1]: Leaving directory `/usr/src/linux/mm'
-make[1]: Entering directory `/usr/src/linux/fs'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DEXPORT_SYMTAB -c nls.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o binfmt_aout.o binfmt_aout.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o binfmt_java.o binfmt_java.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp437.o nls_cp437.c
-nls_cp437.c:361: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp737.o nls_cp737.c
-nls_cp737.c:289: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp775.o nls_cp775.c
-nls_cp775.c:289: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp850.o nls_cp850.c
-nls_cp850.c:253: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp852.o nls_cp852.c
-nls_cp852.c:253: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp855.o nls_cp855.c
-nls_cp855.c:253: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp857.o nls_cp857.c
-nls_cp857.c:217: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp860.o nls_cp860.c
-nls_cp860.c:325: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp861.o nls_cp861.c
-nls_cp861.c:361: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp862.o nls_cp862.c
-nls_cp862.c:397: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp863.o nls_cp863.c
-nls_cp863.c:361: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp864.o nls_cp864.c
-nls_cp864.c:352: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp865.o nls_cp865.c
-nls_cp865.c:361: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp866.o nls_cp866.c
-nls_cp866.c:289: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp869.o nls_cp869.c
-nls_cp869.c:253: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_cp874.o nls_cp874.c
-nls_cp874.c:217: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_iso8859_1.o nls_iso8859_1.c
-nls_iso8859_1.c:138: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_iso8859_2.o nls_iso8859_2.c
-nls_iso8859_2.c:210: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_iso8859_3.o nls_iso8859_3.c
-nls_iso8859_3.c:210: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_iso8859_4.o nls_iso8859_4.c
-nls_iso8859_4.c:210: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_iso8859_5.o nls_iso8859_5.c
-nls_iso8859_5.c:214: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_iso8859_6.o nls_iso8859_6.c
-nls_iso8859_6.c:174: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_iso8859_7.o nls_iso8859_7.c
-nls_iso8859_7.c:250: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_iso8859_8.o nls_iso8859_8.c
-nls_iso8859_8.c:214: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_iso8859_9.o nls_iso8859_9.c
-nls_iso8859_9.c:174: warning: `charset2upper' defined but not used
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_iso8859_15.o nls_iso8859_15.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nls_koi8_r.o nls_koi8_r.c
-nls_koi8_r.c:286: warning: `charset2upper' defined but not used
-set -e; for i in minix ext fat msdos vfat isofs nfs xiafs umsdos sysv smbfs ncpfs hpfs ufs affs autofs; do make -C $i modules; done
-make[2]: Entering directory `/usr/src/linux/fs/minix'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o bitmap.o bitmap.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o truncate.o truncate.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o namei.o namei.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o file.o file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o symlink.o symlink.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o fsync.o fsync.c
-rm -f minix.o
-ld -m elf_i386  -r -o minix.o  bitmap.o truncate.o namei.o inode.o file.o dir.o symlink.o fsync.o
-echo fs/minix/
-fs/minix/
-cd $TOPDIR/modules; for i in  minix.o; do \
-    ln -sf ../fs/minix//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/minix'
-make[2]: Entering directory `/usr/src/linux/fs/ext'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o freelists.o freelists.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o truncate.o truncate.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o namei.o namei.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o file.o file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o symlink.o symlink.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o fsync.o fsync.c
-rm -f ext.o
-ld -m elf_i386  -r -o ext.o  freelists.o truncate.o namei.o inode.o file.o dir.o symlink.o fsync.o
-echo fs/ext/
-fs/ext/
-cd $TOPDIR/modules; for i in  ext.o; do \
-    ln -sf ../fs/ext//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/ext'
-make[2]: Entering directory `/usr/src/linux/fs/fat'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DMODVERSIONS -DEXPORT_SYMTAB -c fatfs_syms.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o buffer.o buffer.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o cache.o cache.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o file.o file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o misc.o misc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o mmap.o mmap.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o tables.o tables.c
-rm -f fat.o
-ld -m elf_i386  -r -o fat.o fatfs_syms.o buffer.o cache.o dir.o file.o inode.o misc.o mmap.o tables.o
-echo fs/fat/
-fs/fat/
-cd $TOPDIR/modules; for i in  fat.o; do \
-    ln -sf ../fs/fat//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/fat'
-make[2]: Entering directory `/usr/src/linux/fs/msdos'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DMODVERSIONS -DEXPORT_SYMTAB -c msdosfs_syms.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o namei.o namei.c
-rm -f msdos.o
-ld -m elf_i386  -r -o msdos.o msdosfs_syms.o namei.o
-echo fs/msdos/
-fs/msdos/
-cd $TOPDIR/modules; for i in  msdos.o; do \
-    ln -sf ../fs/msdos//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/msdos'
-make[2]: Entering directory `/usr/src/linux/fs/vfat'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DMODVERSIONS -DEXPORT_SYMTAB -c vfatfs_syms.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o namei.o namei.c
-rm -f vfat.o
-ld -m elf_i386  -r -o vfat.o vfatfs_syms.o namei.o
-echo fs/vfat/
-fs/vfat/
-cd $TOPDIR/modules; for i in  vfat.o; do \
-    ln -sf ../fs/vfat//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/vfat'
-make[2]: Entering directory `/usr/src/linux/fs/isofs'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o namei.o namei.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o file.o file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o util.o util.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rock.o rock.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o symlink.o symlink.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o joliet.o joliet.c
-rm -f isofs.o
-ld -m elf_i386  -r -o isofs.o  namei.o inode.o file.o dir.o util.o rock.o symlink.o joliet.o
-echo fs/isofs/
-fs/isofs/
-cd $TOPDIR/modules; for i in  isofs.o; do \
-    ln -sf ../fs/isofs//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/isofs'
-make[2]: Entering directory `/usr/src/linux/fs/nfs'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o proc.o proc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sock.o sock.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rpcsock.o rpcsock.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o file.o file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o bio.o bio.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nfsiod.o nfsiod.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o symlink.o symlink.c
-rm -f nfs.o
-ld -m elf_i386  -r -o nfs.o  proc.o sock.o rpcsock.o inode.o file.o bio.o nfsiod.o dir.o symlink.o
-echo fs/nfs/
-fs/nfs/
-cd $TOPDIR/modules; for i in  nfs.o; do \
-    ln -sf ../fs/nfs//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/nfs'
-make[2]: Entering directory `/usr/src/linux/fs/xiafs'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o bitmap.o bitmap.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o truncate.o truncate.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o namei.o namei.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o file.o file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o symlink.o symlink.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o fsync.o fsync.c
-rm -f xiafs.o
-ld -m elf_i386  -r -o xiafs.o  bitmap.o truncate.o namei.o inode.o file.o dir.o symlink.o fsync.o
-echo fs/xiafs/
-fs/xiafs/
-cd $TOPDIR/modules; for i in  xiafs.o; do \
-    ln -sf ../fs/xiafs//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/xiafs'
-make[2]: Entering directory `/usr/src/linux/fs/umsdos'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o emd.o emd.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o file.o file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ioctl.o ioctl.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o mangle.o mangle.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o namei.o namei.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rdir.o rdir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o symlink.o symlink.c
-rm -f umsdos.o
-ld -m elf_i386  -r -o umsdos.o  dir.o emd.o file.o inode.o ioctl.o mangle.o namei.o rdir.o symlink.o 
-echo fs/umsdos/
-fs/umsdos/
-cd $TOPDIR/modules; for i in  umsdos.o; do \
-    ln -sf ../fs/umsdos//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/umsdos'
-make[2]: Entering directory `/usr/src/linux/fs/sysv'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ialloc.o ialloc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o balloc.o balloc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o file.o file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o symlink.o symlink.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o namei.o namei.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o fsync.o fsync.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o truncate.o truncate.c
-rm -f sysv.o
-ld -m elf_i386  -r -o sysv.o  ialloc.o balloc.o inode.o file.o dir.o symlink.o namei.o fsync.o truncate.o
-echo fs/sysv/
-fs/sysv/
-cd $TOPDIR/modules; for i in  sysv.o; do \
-    ln -sf ../fs/sysv//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/sysv'
-make[2]: Entering directory `/usr/src/linux/fs/smbfs'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o proc.o proc.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sock.o sock.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o file.o file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ioctl.o ioctl.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o mmap.o mmap.c
-rm -f smbfs.o
-ld -m elf_i386  -r -o smbfs.o  proc.o sock.o inode.o file.o dir.o ioctl.o mmap.o
-echo fs/smbfs/
-fs/smbfs/
-cd $TOPDIR/modules; for i in  smbfs.o; do \
-    ln -sf ../fs/smbfs//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/smbfs'
-make[2]: Entering directory `/usr/src/linux/fs/ncpfs'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o file.o file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ioctl.o ioctl.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o mmap.o mmap.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -finline-functions -c -o ncplib_kernel.o ncplib_kernel.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sock.o sock.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ncpsign_kernel.o ncpsign_kernel.c
-rm -f ncpfs.o
-ld -m elf_i386  -r -o ncpfs.o  dir.o file.o inode.o ioctl.o mmap.o ncplib_kernel.o sock.o ncpsign_kernel.o
-echo fs/ncpfs/
-fs/ncpfs/
-cd $TOPDIR/modules; for i in  ncpfs.o; do \
-    ln -sf ../fs/ncpfs//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/ncpfs'
-make[2]: Entering directory `/usr/src/linux/fs/hpfs'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o hpfs_fs.o hpfs_fs.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o hpfs_caps.o hpfs_caps.c
-rm -f hpfs.o
-ld -m elf_i386  -r -o hpfs.o  hpfs_fs.o hpfs_caps.o
-echo fs/hpfs/
-fs/hpfs/
-cd $TOPDIR/modules; for i in  hpfs.o; do \
-    ln -sf ../fs/hpfs//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/hpfs'
-make[2]: Entering directory `/usr/src/linux/fs/ufs'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ufs_dir.o ufs_dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ufs_file.o ufs_file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ufs_inode.o ufs_inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ufs_namei.o ufs_namei.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ufs_super.o ufs_super.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ufs_symlink.o ufs_symlink.c
-rm -f ufs.o
-ld -m elf_i386  -r -o ufs.o  ufs_dir.o ufs_file.o ufs_inode.o ufs_namei.o ufs_super.o ufs_symlink.o
-echo fs/ufs/
-fs/ufs/
-cd $TOPDIR/modules; for i in  ufs.o; do \
-    ln -sf ../fs/ufs//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/ufs'
-make[2]: Entering directory `/usr/src/linux/fs/affs'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o namei.o namei.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o file.o file.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o amigaffs.o amigaffs.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o bitmap.o bitmap.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o symlink.o symlink.c
-rm -f affs.o
-ld -m elf_i386  -r -o affs.o  namei.o inode.o file.o dir.o amigaffs.o bitmap.o symlink.o
-echo fs/affs/
-fs/affs/
-cd $TOPDIR/modules; for i in  affs.o; do \
-    ln -sf ../fs/affs//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/affs'
-make[2]: Entering directory `/usr/src/linux/fs/autofs'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dir.o dir.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o dirhash.o dirhash.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o init.o init.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o inode.o inode.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o root.o root.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o symlink.o symlink.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o waitq.o waitq.c
-rm -f autofs.o
-ld -m elf_i386  -r -o autofs.o  dir.o dirhash.o init.o inode.o root.o symlink.o waitq.o
-echo fs/autofs/
-fs/autofs/
-cd $TOPDIR/modules; for i in  autofs.o; do \
-    ln -sf ../fs/autofs//$i .; done
-make[2]: Leaving directory `/usr/src/linux/fs/autofs'
-rm -f $TOPDIR/modules/FS_MODULES
-for i in minix ext fat msdos vfat isofs nfs xiafs umsdos sysv smbfs ncpfs hpfs ufs affs autofs; do \
-    echo `basename $i`.o >> $TOPDIR/modules/FS_MODULES; done
-echo nls.o binfmt_aout.o binfmt_java.o nls_cp437.o nls_cp737.o nls_cp775.o nls_cp850.o nls_cp852.o nls_cp855.o nls_cp857.o nls_cp860.o nls_cp861.o nls_cp862.o nls_cp863.o nls_cp864.o nls_cp865.o nls_cp866.o nls_cp869.o nls_cp874.o nls_iso8859_1.o nls_iso8859_2.o nls_iso8859_3.o nls_iso8859_4.o nls_iso8859_5.o nls_iso8859_6.o nls_iso8859_7.o nls_iso8859_8.o nls_iso8859_9.o nls_iso8859_15.o nls_koi8_r.o >> $TOPDIR/modules/FS_MODULES
-echo fs/
-fs/
-cd $TOPDIR/modules; for i in nls.o binfmt_aout.o binfmt_java.o nls_cp437.o nls_cp737.o nls_cp775.o nls_cp850.o nls_cp852.o nls_cp855.o nls_cp857.o nls_cp860.o nls_cp861.o nls_cp862.o nls_cp863.o nls_cp864.o nls_cp865.o nls_cp866.o nls_cp869.o nls_cp874.o nls_iso8859_1.o nls_iso8859_2.o nls_iso8859_3.o nls_iso8859_4.o nls_iso8859_5.o nls_iso8859_6.o nls_iso8859_7.o nls_iso8859_8.o nls_iso8859_9.o nls_iso8859_15.o nls_koi8_r.o; do \
-    ln -sf ../fs//$i .; done
-make[1]: Leaving directory `/usr/src/linux/fs'
-make[1]: Entering directory `/usr/src/linux/net'
-set -e; for i in ipv4 ipx appletalk netrom rose ax25; do make -C $i modules; done
-make[2]: Entering directory `/usr/src/linux/net/ipv4'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rarp.o rarp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ipip.o ipip.c
-rm -f $TOPDIR/modules/IPV4_MODULES
-echo   rarp.o ipip.o >> $TOPDIR/modules/IPV4_MODULES
-echo net/ipv4/
-net/ipv4/
-cd $TOPDIR/modules; for i in   rarp.o ipip.o; do \
-    ln -sf ../net/ipv4//$i .; done
-make[2]: Leaving directory `/usr/src/linux/net/ipv4'
-make[2]: Entering directory `/usr/src/linux/net/ipx'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o af_ipx.o af_ipx.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sysctl_net_ipx.o sysctl_net_ipx.c
-rm -f ipx.o
-ld -m elf_i386  -r -o ipx.o  af_ipx.o sysctl_net_ipx.o
-echo net/ipx/
-net/ipx/
-cd $TOPDIR/modules; for i in  ipx.o; do \
-    ln -sf ../net/ipx//$i .; done
-make[2]: Leaving directory `/usr/src/linux/net/ipx'
-make[2]: Entering directory `/usr/src/linux/net/appletalk'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o aarp.o aarp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ddp.o ddp.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sysctl_net_atalk.o sysctl_net_atalk.c
-rm -f appletalk.o
-ld -m elf_i386  -r -o appletalk.o  aarp.o ddp.o sysctl_net_atalk.o
-echo net/appletalk/
-net/appletalk/
-cd $TOPDIR/modules; for i in  appletalk.o; do \
-    ln -sf ../net/appletalk//$i .; done
-make[2]: Leaving directory `/usr/src/linux/net/appletalk'
-make[2]: Entering directory `/usr/src/linux/net/netrom'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o af_netrom.o af_netrom.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sysctl_net_netrom.o sysctl_net_netrom.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nr_dev.o nr_dev.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nr_in.o nr_in.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nr_out.o nr_out.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nr_route.o nr_route.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nr_subr.o nr_subr.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nr_timer.o nr_timer.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o nr_loopback.o nr_loopback.c
-rm -f netrom.o
-ld -m elf_i386  -r -o netrom.o  af_netrom.o sysctl_net_netrom.o nr_dev.o nr_in.o nr_out.o nr_route.o nr_subr.o nr_timer.o nr_loopback.o
-echo net/netrom/
-net/netrom/
-cd $TOPDIR/modules; for i in  netrom.o; do \
-    ln -sf ../net/netrom//$i .; done
-make[2]: Leaving directory `/usr/src/linux/net/netrom'
-make[2]: Entering directory `/usr/src/linux/net/rose'
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o af_rose.o af_rose.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sysctl_net_rose.o sysctl_net_rose.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rose_dev.o rose_dev.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rose_in.o rose_in.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rose_link.o rose_link.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rose_loopback.o rose_loopback.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rose_out.o rose_out.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rose_route.o rose_route.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rose_subr.o rose_subr.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o rose_timer.o rose_timer.c
-rm -f rose.o
-ld -m elf_i386  -r -o rose.o  af_rose.o sysctl_net_rose.o rose_dev.o rose_in.o rose_link.o rose_loopback.o rose_out.o rose_route.o rose_subr.o rose_timer.o
-echo net/rose/
-net/rose/
-cd $TOPDIR/modules; for i in  rose.o; do \
-    ln -sf ../net/rose//$i .; done
-make[2]: Leaving directory `/usr/src/linux/net/rose'
-make[2]: Entering directory `/usr/src/linux/net/ax25'
-updating /usr/src/linux/include/linux/modversions.h
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h -DMODVERSIONS -DEXPORT_SYMTAB -c af_ax25.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o sysctl_net_ax25.o sysctl_net_ax25.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ax25_in.o ax25_in.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ax25_out.o ax25_out.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ax25_route.o ax25_route.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ax25_subr.o ax25_subr.c
-gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -DCPU=486 -DMODULE -DMODVERSIONS -include /usr/src/linux/include/linux/modversions.h  -c -o ax25_timer.o ax25_timer.c
-rm -f ax25.o
-ld -m elf_i386  -r -o ax25.o af_ax25.o sysctl_net_ax25.o ax25_in.o ax25_out.o ax25_route.o ax25_subr.o ax25_timer.o
-echo net/ax25/
-net/ax25/
-cd $TOPDIR/modules; for i in  ax25.o; do \
-    ln -sf ../net/ax25//$i .; done
-make[2]: Leaving directory `/usr/src/linux/net/ax25'
-rm -f $TOPDIR/modules/NET_MISC_MODULES
-for i in ipv4 ipx appletalk netrom rose ax25; do \
-    echo `basename $i`.o >> $TOPDIR/modules/NET_MISC_MODULES; done
-make[1]: Leaving directory `/usr/src/linux/net'
-make[1]: Entering directory `/usr/src/linux/ipc'
-make[1]: Nothing to be done for `modules'.
-make[1]: Leaving directory `/usr/src/linux/ipc'
-make[1]: Entering directory `/usr/src/linux/lib'
-make[1]: Nothing to be done for `modules'.
-make[1]: Leaving directory `/usr/src/linux/lib'
-make[1]: Entering directory `/usr/src/linux/arch/i386/kernel'
-make[1]: Nothing to be done for `modules'.
-make[1]: Leaving directory `/usr/src/linux/arch/i386/kernel'
-make[1]: Entering directory `/usr/src/linux/arch/i386/mm'
-make[1]: Nothing to be done for `modules'.
-make[1]: Leaving directory `/usr/src/linux/arch/i386/mm'
-make[1]: Entering directory `/usr/src/linux/arch/i386/lib'
-make[1]: Nothing to be done for `modules'.
-make[1]: Leaving directory `/usr/src/linux/arch/i386/lib'
