patch-2.1.75 linux/drivers/scsi/eata_pio_proc.c

Next file: linux/drivers/scsi/esp.c
Previous file: linux/drivers/scsi/eata_pio.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.74/linux/drivers/scsi/eata_pio_proc.c linux/drivers/scsi/eata_pio_proc.c
@@ -81,14 +81,12 @@
     if (pos > offset + length)
 	goto stop_output;
     
-    scd = scsi_devices;
-    
-    size = sprintf(buffer+len,"Attached devices: %s\n", (scd)?"":"none");
+    size = sprintf(buffer+len,"Attached devices: %s\n", 
+		   (HBA_ptr->host_queue)?"":"none");
     len += size; 
     pos = begin + len;
     
-    while (scd) {
-	if (scd->host == HBA_ptr) {
+    for(scd = HBA_ptr->host_queue; scd; scd = scd->next) {
 	    proc_print_scsidevice(scd, buffer, &size, len);
 	    len += size; 
 	    pos = begin + len;
@@ -99,8 +97,6 @@
 	    }
 	    if (pos > offset + length)
 		goto stop_output;
-	}
-	scd = scd->next;
     }
     
  stop_output:

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov