> On Mon, 2005-04-11 at 14:55 +0200, Norbert Preining wrote:
> > On Mon, 11 Apr 2005, Kay Sievers wrote:
> > > > brw-rw---- 1 root root 8, 0 2005-04-10 14:58 /dev/sdcard
> > > > brw-rw---- 1 root root 8, 1 2005-04-10 14:58 /dev/sdcard1
> > > > brw-rw---- 1 root root 8, 1 2005-04-10 14:58 /dev/sdcard2
> > > > brw-rw---- 1 root root 8, 1 2005-04-10 14:58 /dev/sdcard3
> > >
> > > This looks broken.
> >
> > Good to hear.
Yeah, I guess it's broken. In create_node() in udev_add.c there is
always added 1 to the minor number, thus the error. The attached patch
should fix this.
subsys => "block",
devpath => "/block/sda",
exp_name => "boot_disk15" ,
+ exp_majorminor => "8:15",
rules => <<EOF
BUS=="scsi", SYSFS{vendor}=="IBM-ESXS", NAME{all_partitions}="boot_disk"
EOF
snprintf(partitionname, sizeof(partitionname), "%s%d", filename, i);
partitionname[sizeof(partitionname)-1] = '\0';
- part_devt = makedev(major(udev->devt), minor(udev->devt)+1);
+ part_devt = makedev(major(udev->devt), minor(udev->devt) + i);
udev_make_node(udev, partitionname, part_devt, udev->mode, uid, gid);
}
}