Some customers want to expose their i3c device on the /dev, In order to develop their i3c APP or operation the i3c device like I2C. But in our default BSP code, we do not support this feature for I3C device, This article will introduce how to make the i3c device expose to the user space.
Board : i.MX 93 EVK
BSP Version : lf-6.1.55-2.2.0
I3C device : LSM6DSOXTR
Step 1 : Rework the i.MX93 EVK Board, Install the R1010.
Step 2 : Apply the add_i3c_device_to_dev.patch file to the linux kernel code
Command : git apply add_i3c_device_to_dev.patch
Step 3 : Re-compile the kernel Image file.
Command : make imx_v8_defconfig
make
Step 4 : Boot your board with "imx93-11x11-evk-i3c.dtb" file and see if you can see the I3C device on the /dev directory.
Result : We can see the i3c device is appeared in /dev directory, The i2c-8 is an i2c device mounted to the i3c bus. The i3c is backward compatible with i2c device. It will simulate the I2C signal loading i2c device.
PS : You can also use the i2ctool detect i2c-8 device. As shown in the following picture:
Note : If you need the patch file, Please contact me any time for free.
Hello, can you send me the patch file add_i3c_device_to_dev.patch?
I am also interested for the patch.