Matthew Burgess wrote:
Alexander E. Patrakov wrote:
1. Target audience. It is impossible to understand udev and kernel
fully without reading the source. So, at least for some sections, a
working knowledge of C must be assumed. AFAIK, this is unacceptable
for the LFS book.
Indeed, and in fact, I think it is unacceptable for anywhere other than
upstream. i.e. patches should be made to udev to improve the man page
and/or other documentation it installs so as having to understand the C
code is no longer a requirement to understanding how to configure it to
meet one's needs.
The problem is not "how" (which is already dealt with), but "why". I.e., one
could say that some sysfs attributes for SCSI devices are created after the
uevent is sent. That's why we have the WAIT_FOR_SYSFS rule that waits for
"ioerr_cnt".
But it will be certainly better to show where exactly this takes place (i.e.,
the scsi_sysfs_add_sdev() function from drivers/scsi/scsi_sysfs.c). This
function, in its very end, creates all sysfs attributes listed in the
scsi_sysfs_sdev_attrs[] array. Upon examining the contents of that array, it is
clearly seen that the "ioerr_cnt" is really the last attribute created.
--
Alexander E. Patrakov
--
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page