X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Fblock%2Facsi_slm.c;h=4cb9c13362874cedbed44c24a2982046d1e74e4c;hb=9464c7cf61b9433057924c36e6e02f303a00e768;hp=4030a8fd11872992e2c5040746c873f6e8a6f01a;hpb=41689045f6a3cbe0550e1d34e9cc20d2e8c432ba;p=linux-2.6.git diff --git a/drivers/block/acsi_slm.c b/drivers/block/acsi_slm.c index 4030a8fd1..4cb9c1336 100644 --- a/drivers/block/acsi_slm.c +++ b/drivers/block/acsi_slm.c @@ -65,6 +65,7 @@ not be guaranteed. There are several ways to assure this: #include #include #include +#include #include #include @@ -1004,6 +1005,11 @@ int slm_init( void ) BufferP = SLMBuffer; SLMState = IDLE; + devfs_mk_dir("slm"); + for (i = 0; i < MAX_SLM; i++) { + devfs_mk_cdev(MKDEV(ACSI_MAJOR, i), + S_IFCHR|S_IRUSR|S_IWUSR, "slm/%d", i); + } return 0; } @@ -1026,6 +1032,10 @@ int init_module(void) void cleanup_module(void) { + int i; + for (i = 0; i < MAX_SLM; i++) + devfs_remove("slm/%d", i); + devfs_remove("slm"); if (unregister_chrdev( ACSI_MAJOR, "slm" ) != 0) printk( KERN_ERR "acsi_slm: cleanup_module failed\n"); atari_stram_free( SLMBuffer );