do not ignore sysfs class being zero - #619
Conversation
Since commit [1] an i2c bus gets ignored when no corresponding class file is found. This causes platforms, where the i2c host controller is not connect via PCIe, to be ignored completely, even though the bus is still valid. This makes the ddcutil useless on those platforms. The absence of such a file is not enough to tell whether a bus is valid or not. Partially revert commit [1], to avoid ignoring an i2c bus [1] 3df4af0 ("add comments re invalid bus number in i2c_device_sysfs_class(), is_ignorable_i2c_device()") Signed-off-by: Fabian Pfitzner <f.pfitzner@pengutronix.de>
|
|
What precisely is the hardware platform in question? Please run sudo ddcutil interrogate and submit the output as an attachment. I need to better understand what is going on before relaxing the check. |
|
I'm using a Skov I.MX8MP CPU board matching this Device Tree. I build a customized Yocto image based on I think it is not usual on ARM/i.MX8 that the i2c controller has a PCIe parent that exposes this class file. This seems like the cause of my problem. Here you find the output of |
…ot found on SOC system - added sysfs_is_soc_system() - safer version of pull request #619
|
Commit 1a4871e to branch 2.2.8-dev implements a more conservative version of your patch. If the device adapter class is not found (sysfs adapter class 0), the /dev/i2c device is not ignored on a SOC system. Let me know if this resolves your problem. |
|
Thank you very much. This solves my problem. |



Since commit [1] an i2c bus gets ignored when no corresponding class file is found.
This causes platforms, where the i2c host controller is not connect via PCIe, to be ignored completely, even though the bus is still valid. This makes the ddcutil useless on those platforms.
The absence of such a file is not enough to tell whether a bus is valid or not. Partially revert commit [1], to avoid ignoring an i2c bus
[1] 3df4af0 ("add comments re invalid bus number in i2c_device_sysfs_class(), is_ignorable_i2c_device()")