[i2c] linux-i2c and smbalert

Hendrik Sattler post at hendrik-sattler.de
Mon Sep 11 16:22:46 CEST 2006


I reqrote the most part of it. i2c-smbalert now registers as i2c_driver and 
has to be manually attached to the bus by the i2c_adapter driver that want to 
support it.
I also attached the implementation for i2c-i801 (also contains some other 
cleanups) that runs fine on my system (Intel Corporation 82801BA/BAM SMBus)

* If reading the ARA contains an I2C address that is not registered by a 
driver with an smbus_alert function, an asserted SMBALERT# might never get 
deasserted. If it has the highest address, the ARA will always contain that 
address. This is a problem of the system (SMBALERTs should only be issued 
after explicit configuration), not resolvable.
* Some host adapters have an unconnected SMBALERT pin (e.g. my system). I 
solved this for i2c-i801 with a Kconfig option that only enables conditional 
poll based on that choice. This could also be a module option, instead.

How can I make a loose dependency with Kconfig: i2c_i801 must not be compiled 
built-in if i2c_smbalert is configured as module (linking error). However, it 
also shall not depend on it (after all, it's optional).

Comments (especially on better variable and function names) are welcome.

I also have an i2c_client driver but this is only useful for a Lifebook C-6637 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: smbalert.patch
Type: text/x-diff
Size: 11439 bytes
Desc: not available
Url : http://lists.lm-sensors.org/pipermail/i2c/attachments/20060911/beeb35ca/attachment.bin 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: i801_smbalert.patch
Type: text/x-diff
Size: 9940 bytes
Desc: not available
Url : http://lists.lm-sensors.org/pipermail/i2c/attachments/20060911/beeb35ca/attachment-0001.bin 

More information about the i2c mailing list