Dear TI Support Team,
In our LS1028A based custom board 5 different devices are connected through I2C hub switch (TCA9548APWR) in bus-2 as shown in attached file.
I am able to read and write in i2c devices connected through I2C Hub in U-Boot but same thing is not happening in Linux when i am trying to write and read through i2ctransfer utility and separate application and getting Resource temporarily unavailable(using own app).
In U-Boot 1st i am writing in i2c hub to select devices connected to hub then i am writing in devices and getting correct data as shown below:
-----------------------
#TO check RTC:
i2c probe
i2c dev 2
i2c probe
i2c mw 0x71 0x0 0x1 (0x71 is I2C Hub address)
i2c probe
i2c mw 0x51 0xa2 0xe (0x51 in RTC address
i2c md 0x51 0xa2 0x1
------------------------
#TO check EEPROM2:
i2c mw 0x71 0x0 0x2
i2c probe
i2c mw 0x50 0x0 0xf
i2c md 0x50 0x0 0x1
Below is my Dts file:
i2c-switch@74 {
compatible = "nxp,pca9548";
#address-cells = <1>;
#size-cells = <0>;
reg = <0x74>;
interrupt-parent = <&ipic>;
interrupts = <17 IRQ_TYPE_LEVEL_LOW>;
interrupt-controller;
#interrupt-cells = <2>;
i2c@2 {
#address-cells = <1>;
#size-cells = <0>;
reg = <2>;
eeprom@54 {
compatible = "atmel,24c08";
reg = <0x54>;
};
};
i2c@4 {
#address-cells = <1>;
#size-cells = <0>;
reg = <4>;
rtc@51 {
compatible = "nxp,pcf8563";
reg = <0x51>;
};
};
};
But in linux with below i am using below utility:
i2ctransfer 2 w17@0x71 0x0 0xff- (to write 0xff in i2c hub address 0x71 to enable all i2c hub devices)
2ctransfer 2 w1@0x71 0x0 r1 (to read in i2c hub address 0x71)
i2ctransfer 2 w17@0x51 0x0 0x77- (to write 0x77 in RTC devices of hub address 0x51 )
2ctransfer 2 w1@0x51 0x0 r1 (to read RTC hub address 0x51)
But not getting proper data with utility.
For this i contact to NXP Support team and they said "Please contact TI to require Linux driver for TCA9548APWR device".
So I Just need driver source code for TCA9548APWR I2C HUB device.
Please help me on this.
Regards,
Amit Kumar Keshri

