Messages in this thread Patches in this message | | | Date | Tue, 16 Dec 1997 18:37:25 +0100 (CET) | From | "Andrzej M. Krzysztofowicz" <> | Subject | Some 2.1.72 patches |
| |
I am enclosing seven minor patches for 2.1.72.
1. Adding some "forgotten" ioctl()'s to sd driver 2. Mistake in bsd_disklabel_partition in high limit for numbering slices(?). Limitting condition cannot be satisfied as mask==hd->max_p-1 in fact... It can cause problem with SCSI disks with some "starnge" partitioning (eg.: 4 primary+4 on DOS extended+8 BSD "slices"=16; while limit for SCSI is 15). 3. Two typos in Configure.help & some forgotten entries for floppies in devices.txt (they exist in *.tex version) 4 & 5. Removing record from gendisk_head based list for asci.c (Atari) and ddv.c (ap1000) 6. Enabling setting high-numbered SCSI disks as containing root-fs Forgotten? I noticed, that higher IDE disks have already been added... 7. New (I hope the last) version of xd patch which include (may be not if I'll find somewhere one more unsupported controller :) ) - support for a Xebec controller - ioctl()'s for DMA setting/reading, reading "read ahead" parameter, and reading multicount setting. Forgotten ? - removing record from gendisk_head based list (same as 4 & 5 for other drivers) - registering I/O ports in /proc/ioports - invalidate_buffers() while unloading (if module)
All problems except 4, 5 and "Configure.help" typos exist also in 2.0.32. Apropriate patches are available at: ftp://rudy.mif.pg.gda.pl/pub/People/ankry/linux-patches/2.0/
With regards -- ======================================================================= Andrzej M. Krzysztofowicz ankry@mif.pg.gda.pl phone: (48)(58) 347 14 61 fax: (48)(58) 347 28 21 Faculty of Applied Phys.& Maths, Technical University of Gdansk, Poland
diff -u v2.1.72/drivers/scsi/sd_ioctl.c linux/drivers/scsi/sd_ioctl.c --- v2.1.72/drivers/scsi/sd_ioctl.c Fri Nov 29 10:20:08 1996 +++ linux/drivers/scsi/sd_ioctl.c Sun Dec 14 00:56:45 1997 @@ -91,6 +91,9 @@ case BLKRRPART: /* Re-read partition tables */ return revalidate_scsidisk(dev, 1); + + RO_IOCTLS(dev, arg); + default: return scsi_ioctl(rscsi_disks[MINOR(dev) >> 4].device , cmd, (void *) arg); }diff -u v2.1.72/drivers/block/genhd.c linux/drivers/block/genhd.c --- v2.1.72/drivers/block/genhd.c Sat Aug 16 18:53:08 1997 +++ linux/drivers/block/genhd.c Sun Dec 14 20:10:05 1997 @@ -278,7 +278,7 @@ p = &l->d_partitions[0]; while (p - &l->d_partitions[0] <= BSD_MAXPARTITIONS) { - if ((current_minor & mask) >= (4 + hd->max_p)) + if ((current_minor & mask) == 0) break; if (p->p_fstype != BSD_FS_UNUSED) { @@ -808,7 +808,7 @@ static int atari_partition (struct gendisk *hd, kdev_t dev, unsigned long first_sector) { - int minor = current_minor, m_lim = current_minor + hd->max_p; + int minor = current_minor, m_lim = hd->max_p; struct buffer_head *bh; struct rootsector *rs; struct partition_info *pi;diff -u v2.1.72/Documentation/devices.txt linux/Documentation/devices.txt --- v2.1.72/Documentation/devices.txt Sun Dec 14 00:20:48 1997 +++ linux/Documentation/devices.txt Sun Dec 14 18:25:12 1997 @@ -93,10 +93,14 @@ the position within the series. block Floppy disks - 0 = /dev/fd0 First floppy disk autodetect - 1 = /dev/fd1 Second floppy disk autodetect - 2 = /dev/fd2 Third floppy disk autodetect - 3 = /dev/fd3 Fourth floppy disk autodetect + 0 = /dev/fd0 Controller 1, drive 1 autodetect + 1 = /dev/fd1 Controller 1, drive 2 autodetect + 2 = /dev/fd2 Controller 1, drive 3 autodetect + 3 = /dev/fd3 Controller 1, drive 4 autodetect + 128 = /dev/fd4 Controller 2, drive 1 autodetect + 129 = /dev/fd5 Controller 2, drive 2 autodetect + 130 = /dev/fd6 Controller 2, drive 3 autodetect + 131 = /dev/fd7 Controller 2, drive 4 autodetect To specify format, add to the autodetect device number: 0 = /dev/fd? Autodetect format diff -u v2.1.72/Documentation/Configure.help linux/Documentation/devices/Configure.help --- v2.1.72/Documentation/Configure.help Sun Dec 14 00:20:48 1997 +++ linux/Documentation/Configure.help Mon Dec 15 23:50:17 1997 @@ -1497,9 +1497,9 @@ Unix domain sockets CONFIG_UNIX Y if you want Unix domain sockets. Unless you are working on an - embedded system or somthing, you probably want to say Y. If you try + embedded system or something, you probably want to say Y. If you try building this as a module and you are running kerneld, you need to make - sure and add 'alias net-pf-1 unix' to your /etc/conf.module file. + sure and add 'alias net-pf-1 unix' to your /etc/conf.modules file. The IPv6 protocol CONFIG_IPV6diff -u linux/drivers/block/acsi.c.orig linux/drivers/block/acsi.c --- linux/drivers/block/acsi.c.orig Thu Jul 31 22:09:17 1997 +++ linux/drivers/block/acsi.c Thu Dec 4 23:00:10 1997 @@ -1820,12 +1820,19 @@ void cleanup_module(void) { + struct gendisk ** gdp; + del_timer( &acsi_timer ); blk_dev[MAJOR_NR].request_fn = 0; free_pages( (unsigned long)acsi_buffer, ACSI_BUFFER_ORDER ); if (unregister_blkdev( MAJOR_NR, "ad" ) != 0) printk( KERN_ERR "acsi: cleanup_module failed\n"); + for (gdp = &gendisk_head; *gdp; gdp = &((*gdp)->next)) + if (*gdp == &acsi_gendisk) + break; + if (*gdp) + *gdp = (*gdp)->next; } #endif diff -u linux/drivers/ap1000/ddv.c.orig linux/drivers/ap1000/ddv.c --- linux/drivers/ap1000/ddv.c.orig Sun Jan 26 11:07:10 1997 +++ linux/drivers/ap1000/ddv.c Thu Dec 4 23:00:55 1997 @@ -980,9 +980,10 @@ int init_module(void) { int error = ddv_init(); - ddv_geninit(&(struct gendisk) { 0,0,0,0,0,0,0,0,0,0,0 }); - if (!error) + if (!error) { + ddv_geninit(&(struct gendisk) { 0,0,0,0,0,0,0,0,0,0,0 }); printk(KERN_INFO "DDV: Loaded as module.\n"); + } return error; } @@ -990,6 +991,7 @@ void cleanup_module(void) { int i; + struct gendisk ** gdp; for (i = 0 ; i < NUM_DDVDEVS; i++) invalidate_buffers(MKDEV(MAJOR_NR, i)); @@ -999,6 +1001,11 @@ OPT_IO(PRST) = PRST_IRST; unregister_blkdev( MAJOR_NR, DEVICE_NAME ); + for (gdp = &gendisk_head; *gdp; gdp = &((*gdp)->next)) + if (*gdp == &ddv_gendisk) + break; + if (*gdp) + *gdp = (*gdp)->next; free_irq(APOPT0_IRQ, NULL); blk_dev[MAJOR_NR].request_fn = 0; }diff -u linuxold/init/main.c linux/inin/main.c --- linuxold/init/main.c.orig Thu Dec 4 00:32:21 1997 +++ linux/init/main.c Thu Dec 4 00:36:16 1997 @@ -705,6 +705,17 @@ { "sdc", 0x0820 }, { "sdd", 0x0830 }, { "sde", 0x0840 }, + { "sdf", 0x0850 }, + { "sdg", 0x0860 }, + { "sdh", 0x0870 }, + { "sdi", 0x0880 }, + { "sdj", 0x0890 }, + { "sdk", 0x08a0 }, + { "sdl", 0x08b0 }, + { "sdm", 0x08c0 }, + { "sdn", 0x08d0 }, + { "sdo", 0x08e0 }, + { "sdp", 0x08f0 }, { "ada", 0x1c00 }, { "adb", 0x1c10 }, { "adc", 0x1c20 },[unhandled content-type:application/x-gunzip]
| |