[systemd-devel] How to use libudev to monitor for /sys/firmware/iscsi_boot*?
lduncan at suse.com
Fri Dec 5 13:42:29 PST 2014
On 12/05/2014 01:14 PM, Greg KH wrote:
> On Fri, Dec 05, 2014 at 11:51:16AM -0800, Lee Duncan wrote:
>> I am trying to figure out how to use libudev to monitor for new iSCSI
>> boot targets.
>> For Emulex CNA cards, a new directory gets created of the form
> Really? That's horrid, what kernel driver is doing that?
Why is it horrid? drivers/scsi/iscsi_boot_sysfs.c does that, and it
looks like it's been doing it for quite a while.
The code in open-iscsi that looks for firmware iSCSI boot targets knows
to look in both "/sys/firmware/iscsi_boot%d, and in /sys/firmware/ibft.
iBFT is actually the standard, but many iSCSI CNA cards don't follow the
>> I am new to libudev, but it looks like it's set up to monitor for new
>> devices. Can I use it to monitor for non-device events? There must be
>> some better way than polling.
> Yes, go kick some kernel developers to do this "properly", which does
> not mean using "raw" kobjects. If you want, I will be glad to do that,
> just point me at them...
Feel free to kick away, though I'm still not sure why (or who). The
'/sys/firmware' subsystem seems like a good place to me for iSCSI CNA
cards to place their firmware target information. But I obviously have
much to learn about it.
And, for the record, I believe you are saying that my interpretation of
libudev was right: it's not the tool to detect new iSCSI boot target
presence, at least using the current /sys/firmware/iscsi_boot%d
> greg k-h
More information about the systemd-devel