patch-1.3.28 linux/drivers/scsi/scsicam.c

Next file: linux/drivers/scsi/sd.c
Previous file: linux/drivers/scsi/scsi_syms.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.27/linux/drivers/scsi/scsicam.c linux/drivers/scsi/scsicam.c
@@ -49,13 +49,14 @@
  */
 
 int scsicam_bios_param (Disk *disk, /* SCSI disk */
-	int dev,		/* Device major, minor */
+	kdev_t dev,		/* Device major, minor */
     	int *ip			/* Heads, sectors, cylinders in that order */) {
+
     struct buffer_head *bh;
     int ret_code;
     int size = disk->capacity;
 
-    if (!(bh = bread(dev & ~0xf,0,1024)))
+    if (!(bh = bread(MKDEV(MAJOR(dev), MINOR(dev)&~0xf), 0, 1024)))
 	return -1;
 
 #ifdef DEBUG

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov with Sam's (original) version
of this