Hi all,

I have some probably dumb questions regarding the definition of i2c slaves in the of device tree file...

My test system is a lite5200b board to which I attached two pca8575 io expander chips at i2c addresses 0x20 and 0x21. Using the stock kernel 2.6.29, I added the driver from the GPIO section, but I couldn't figure out how to add them to the dts file. I tried e.g.

<snip>
i...@3d40 {
        [...]
        compatible = "fsl,mpc5200b-i2c","fsl,mpc5200-i2c","fsl-i2c";
        [...]

        g...@20 {
                compatible = "pcf857x";
                device_type = "gpio";
                reg = <0x20 1>;
        };
};
</snip>

and some other like "gpio-controller" instead of "gpio" but (surprise) it doesn't work - dmesg says that the driver is registered, but nothing else shows up. Unfortunately, I couldn't find documentation about the naming conventions of the i2c child nodes.

As I actually want to use the chips as parallel io (not separate gpio's) and thus would need to write my own driver I wonder if I really have to declare it in the device tree? Would the simple way -just load the kernel module as with arm/intel- also work? Would it be possible to use additional resources like an interrupt pin on the '5200 without the device tree?

Any information about a proper approach would be really helpful!

Thanks in advance, Albrecht.

Attachment: pgpRGaBHnsAS5.pgp
Description: PGP signature

_______________________________________________
Linuxppc-dev mailing list
Linuxppc-dev@ozlabs.org
https://ozlabs.org/mailman/listinfo/linuxppc-dev

Reply via email to