[PATCH] sensors-detect and udev

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> sensors-detect currently checks at the beginning of its execution if
> the i2c device nodes exists. It can't work on a system using udev as
> the nodes are created when the i2c-dev module is inserted.
> 
> The attached patch fixes that.

I don't get this:

+  if (-d './dev') {

How does the existence of a directory named "dev" in the current
directory (which can be just anything) demonstrate the use of udev?

And could you please explain how udev is working? I don't know anything
about it.

Also,

+  if ((!$use_devfs) and (!$use_udev)) {

Please use "&&" instead of "and". Also notice that !(A && B) is more
efficient than (!A) && (!B), but I admit I am splitting hairs here ;)

Thanks.

-- 
Jean "Khali" Delvare
http://khali.linux-fr.org/



[Index of Archives]     [Linux Kernel]     [Linux Hardware Monitoring]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux