sensors-detect enhancement needed for sysfs
I've enhanced i2cdetect, i2cdump, and i2cset using the new common function ini2cbusses.c to list all the i2c busses, whether in 2.4 or 2.6 kernels. In 2.6 it's essentially 'cat /sys/class/i2c-adapter/*/device/name' but see i2cbusses for details like finding the sysfs mount point.
We need a perl volunteer to make a similar enhancement at two places in sensors-detect where it scans /proc/bus/i2c.
Note that the adapter name, but not the algorithm, is available in sysfs.
I've hacked around that in libsensors and in the programs above. Guess it's not really necessary.
Anybody like to tackle sensors-detect?
Quoted 5 lines · Mark D. Studebaker
I've enhanced i2cdetect, i2cdump, and i2cset using the new common function in
i2cbusses.cto list all the i2c busses, whether in 2.4 or 2.6 kernels. In 2.6 it's essentially 'cat/sys/class/i2c-adapter/*/device/name' but see i2cbusses for details like finding the sysfs mount point.
Hmm, did you forgot to 'cvs add prog/dump/isaset.c'? I'm getting a build error...
make: *** No rule to make target `prog/dump/isaset.rd'. Stop.
Regards,
Signature · 2 lines
Mark M. Hoffman [email protected]
Quoted 7 lines
I've enhanced i2cdetect, i2cdump, and i2cset using the new common function in
i2cbusses.cto list all the i2c busses, whether in 2.4 or 2.6 kernels. In 2.6 it's essentially 'cat/sys/class/i2c-adapter/*/device/name' but see i2cbusses for details like finding the sysfs mount point.
Quoted 8 lines
We need a perl volunteer to make a similar enhancement at two places in sensors-detect where it scans
/proc/bus/i2c.Note that the adapter name, but not the algorithm, is available in sysfs. I've hacked around that in libsensors and in the programs above. Guess it's not really necessary.
Anybody like to tackle sensors-detect?
I'm on it, providing you tell me what exactly I'm supposed to do there.
Signature · 2 lines
Jean Delvare http://www.ensicaen.ismra.fr/~delvare/
oops, I've been working on an isaset and forgot it was in Module.mk. isaset isn't ready yet so feel free to remove it from Module.mk or I'll do it tonight.
thanks
mds
Quoted 17 lines · Mark M. Hoffman
Quoted 5 lines · Mark D. Studebaker
I've enhanced i2cdetect, i2cdump, and i2cset using the new common function in
i2cbusses.cto list all the i2c busses, whether in 2.4 or 2.6 kernels. In 2.6 it's essentially 'cat/sys/class/i2c-adapter/*/device/name' but see i2cbusses for details like finding the sysfs mount point.Hmm, did you forgot to 'cvs add
prog/dump/isaset.c'? I'm getting a build error...make: *** No rule to make target `prog/dump/isaset.rd'. Stop.
Regards,
cat /proc/bus/i2c on a 2.4 machine. look what it gives you:
bus number, adapter name, algo name.
The perl code pulls each of those out.
Now do cat /sys/class/i2c-adapter/*/device/name on a 2.6 machine. It gives you adapter name (bus number is in the *). Algo name isn't available.
Your assignment: scan /sys/class/i2c-adapter for installed busses, get the name for each, put in a dummy algo name.
Quoted 18 lines · Jean Delvare
Quoted 6 lines
I've enhanced i2cdetect, i2cdump, and i2cset using the new common function in
i2cbusses.cto list all the i2c busses, whether in 2.4 or 2.6 kernels. In 2.6 it's essentially 'cat/sys/class/i2c-adapter/*/device/name' but see i2cbusses for details like finding the sysfs mount point.Quoted 8 lines
We need a perl volunteer to make a similar enhancement at two places in sensors-detect where it scans
/proc/bus/i2c.Note that the adapter name, but not the algorithm, is available in sysfs. I've hacked around that in libsensors and in the programs above. Guess it's not really necessary.
Anybody like to tackle sensors-detect?
I'm on it, providing you tell me what exactly I'm supposed to do there.