patch-2.0.31 linux/drivers/scsi/scsi.h
Next file: linux/drivers/scsi/scsi_ioctl.c
Previous file: linux/drivers/scsi/scsi.c
Back to the patch index
Back to the overall index
- Lines: 42
- Date:
Wed Oct 15 15:24:02 1997
- Orig file:
v2.0.30/linux/drivers/scsi/scsi.h
- Orig date:
Tue Mar 11 15:40:02 1997
diff -u --recursive --new-file v2.0.30/linux/drivers/scsi/scsi.h linux/drivers/scsi/scsi.h
@@ -39,11 +39,12 @@
extern volatile int in_scan_scsis;
extern const unsigned char scsi_command_size[8];
#define COMMAND_SIZE(opcode) scsi_command_size[((opcode) >> 5) & 7]
-
#define IDENTIFY_BASE 0x80
#define IDENTIFY(can_disconnect, lun) (IDENTIFY_BASE |\
((can_disconnect) ? 0x40 : 0) |\
((lun) & 0x07))
+#define MAX_SCSI_DEVICE_CODE 10
+extern const char *const scsi_device_types[MAX_SCSI_DEVICE_CODE];
@@ -218,6 +219,12 @@
extern Scsi_Device * scsi_devices;
+extern struct hd_struct * sd;
+
+#if defined(MAJOR_NR) && (MAJOR_NR == SCSI_DISK_MAJOR)
+extern struct hd_struct * sd;
+#endif
+
/*
* Initializes all SCSI devices. This scans all scsi busses.
*/
@@ -498,8 +505,14 @@
req = &SCpnt->request;
req->errors = 0;
if (!uptodate) {
+#if defined(MAJOR_NR) && (MAJOR_NR == SCSI_DISK_MAJOR)
+ printk(DEVICE_NAME " I/O error: dev %s, sector %lu, absolute sector %lu\n",
+ kdevname(req->rq_dev), req->sector,
+ req->sector + sd[MINOR(SCpnt->request.rq_dev)].start_sect);
+#else
printk(DEVICE_NAME " I/O error: dev %s, sector %lu\n",
kdevname(req->rq_dev), req->sector);
+#endif
}
do {
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov