Re: [PATCH] bsg, block layer sg

From: Jeff Garzik
Date: Thu Mar 02 2006 - 06:20:25 EST


Jens Axboe wrote:
Hi,

After all that SG_IO and cdrecord talk, I decided to brush off the bsg
driver I wrote some time ago. Basically this is a full (aims to be at
least, probably still some minor bits missing) SG v3 interface. It
supports both SG_IO (which we just pass through for now), as well as
read/write and readv/writev of sg_io_hdr structures.

What's new in this area is that the bsg character device is closely tied
to the block device. This relationsship is depicted in sysfs. bsg
devices will show up in /sys/class/bsg/<devname>, and there is a link
from /sys/block/<devname>/queue/bsg to that directory. With some
udev/hotplug magic, it should create device nodes for you automatically.

TODO:

- Fold block/scsi_ioctl.c and block/bsg.c into one
- Further improve the sysfs relations between a device and bsg
- Test and so on

Probably some bugs still pending, it works for me though.

For my part, this gets a strong ACK. I've been waiting for something like this since an OLS discussion years ago.

Thanks Jens!

Jeff



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/