Re: [PATCH 0 of 3] [RFC] I/O Hints

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Jun 5, 2008 at 5:35 AM, Matthew Wilcox <matthew@xxxxxx> wrote:
> On Thu, Jun 05, 2008 at 12:27:54AM -0600, Andreas Dilger wrote:
>> To be honest, however, having the information exported only via sysfs
>> is a bit ugly IMHO.  I've had all sorts of grief with settings there
>> because there isn't always a match between the device that is being
>> specified by the user and what appears in sysfs (e.g. /dev/disk/by-id/foo
>> doesn't match /sys/block/sda) and hoops have to be jumped through to
>> find this mapping, before parsing a text value in C.
>
> readlink() is too hard?
>
> $ readlink /dev/disk/by-id/ata-FUJITSU_MHV2080AH_NT61T6325UGM
> ../../hda
>
>> Having an ioctl() that can be called on the block device (getting
>> the right device regardless of its name) seems a lot more useful to
>> applications in my experience, unless you are using a script.
>
> It's certainly easier.
>

We've had this discussion before:

http://marc.info/?t=120641785300005&r=6&w=2

...and it resulted in this patch that is pending is Greg's tree:

http://git.kernel.org/?p=linux/kernel/git/gregkh/patches.git;a=blob;f=driver-core/sysfs-add-sys-dev-char-block-to-lookup-sysfs-path-by-major-minor.patch;h=ed9a41a564f73db74f7260f24552352ab86bc893;hb=HEAD

Regards,
Dan
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux