Hi! > Add Documentation/ABI/testing/sysfs-class-led-trigger-blkdev to > document: > > * /sys/class/leds//blink_time > * /sys/class/leds//interval > * /sys/class/leds//mode > * /sys/class/leds//add_blkdev > * /sys/class/leds//delete_blkdev > * /sys/class/leds//block_devices > > Add /sys/block//blkdev_leds to Documentation/ABI/testing/sysfs-block > > Add overview in Documentation/leds/ledtrig-blkdev.rst > +What: /sys/class/leds//add_blkdev > +Date: September 2021 > +Contact: Ian Pilcher > +Description: > + Associate a block device with this LED by writing its kernel > + name (as shown in /sys/block) to this attribute. Multiple > + device names may be written at once, separated by whitespace. This is seriously strange interface. > +What: /sys/class/leds//delete_blkdev > +Date: September 2021 > +Contact: Ian Pilcher > +Description: > + Remove the association between this LED and a block device by > + writing the device's kernel name to this attribute. Multiple > + device names may be written at once, separated by whitespace. > + > +What: /sys/class/leds//block_devices > +Date: September 2021 > +Contact: Ian Pilcher > +Description: > + Directory containing links to all block devices that are > + associated with this LED. If you have directory with symlinks, why not use symlink() syscall instead of add_blkdev, and unlink() syscall instead of delete_blkdev? Best regards, Pavel -- http://www.livejournal.com/~pavelmachek