patch-1.3.48 linux/include/linux/blk.h

Next file: linux/include/linux/busmouse.h
Previous file: linux/include/linux/a.out.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.47/linux/include/linux/blk.h linux/include/linux/blk.h
@@ -78,11 +78,14 @@
 #endif
 
 extern void set_device_ro(kdev_t dev,int flag);
+void add_blkdev_randomness(int major);
 
 extern int floppy_init(void);
 extern void rd_load(void);
-extern long rd_init(long mem_start, int length);
-extern int ramdisk_size;
+extern int rd_init(void);
+extern int rd_doload;		/* 1 = load ramdisk, 0 = don't load */
+extern int rd_prompt;		/* 1 = prompt for ramdisk, 0 = don't prompt */
+extern int rd_image_start;	/* starting block # of image */
 
 #define RO_IOCTLS(dev,where) \
   case BLKROSET: if (!suser()) return -EACCES; \
@@ -102,14 +105,15 @@
 #define DEVICE_ON(device)	/* nothing */
 #define DEVICE_OFF(device)	/* nothing */
 
-#elif (MAJOR_NR == MEM_MAJOR)
+#elif (MAJOR_NR == RAMDISK_MAJOR)
 
 /* ram disk */
 #define DEVICE_NAME "ramdisk"
-#define DEVICE_REQUEST do_rd_request
-#define DEVICE_NR(device) (MINOR(device) & 7)
+#define DEVICE_REQUEST rd_request
+#define DEVICE_NR(device) (MINOR(device))
 #define DEVICE_ON(device) 
 #define DEVICE_OFF(device)
+#define DEVICE_NO_RANDOM
 
 #elif (MAJOR_NR == FLOPPY_MAJOR)
 
@@ -374,6 +378,9 @@
 			return;
 		}
 	}
+#ifndef DEVICE_NO_RANDOM
+	add_blkdev_randomness(MAJOR(req->rq_dev));
+#endif
 #ifdef IDE_DRIVER
 	blk_dev[MAJOR(req->rq_dev)].current_request = req->next;
 	hwgroup->rq = NULL;

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