add sysfs class support for raw devices [06/10]]
Subsystems (4)
PATCH 1/1 add sysfs class support for raw devices [06/10]]
Regarding the recent discussion on bonding/vlan/bridge/blah configuration...
This adds class/raw/ support for all raw devices. It also provides a symlink to the block device that the raw device is mapped to. For example:
$ tree /sys/class/raw/
/sys/class/raw/
|-- raw1
| |-- dev
| `-- device -> ../../../block/sda
|-- raw2
| |-- dev
| `-- device -> ../../../block/sda/sda2
`-- rawctl
`-- devNote, in order to get that symlink, I had to export get_gendisk() so that modules can use it. I hope this is ok with everyone.
This is based on a patch originally written by
Leann Ogasawara <[email protected]>
drivers/block/genhd.c +2 -0
@@ -224,6 +224,8 @@return kobj ?to_disk (kobj) :NULL ; } +EXPORT_SYMBOL (get_gendisk); +#ifdef CONFIG_PROC_FS /* iterator */ static void *part_start (struct seq_file *part,loff_t *pos)
drivers/char/raw.c +40 -1
82 lines not on this page · raw message
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/