Hi
In our custom board with IMX8mq, we are using pin SAI1_MCLK or SAI5_MCLK for power enables for a backlight led driver,
I am configuring them as GPIO in u-boot and setting them as high, when the unit boots up , the u-boot set those pin as high, but when kernel boots up it becomes low,
I had removed all SAI1 and SAI5 related configuration (with respect to audio from DT ). still it becomes low while boot up.
I tried toggling the GPIO after boot up, not change ( tried both GPIO sysfs and libgpiod). bot behaves same.
but in the same place if I use PIN SAI3_RXD - i am able to use it as expected and I ma able to toggle it after bootup.
does it means that I cannot use MCLK pin as GPIO ? or is there something I am missing at my end.
Thank you for the help.
Thanks and Regards
Terry
Solved! Go to Solution.
HI Aldo,
Thank you for the response, Found the issue , it was HW issue , because of the soldering , tried with a new board, it works as expected. Thank you for the help, highly appreciate it.
Thanks and Regards
Terry
Hello,
Could you share the dts or the pinmux configuration you have used?
Best regards,
Aldo.
Hi Aldo
I configured the SAI1_MCLK as GPIO in pincntrl_hog, and tried to access the GPIO through sysfs and libgpiod.
pinctrl_hog: hoggrp {
fsl,pins = <
MX8MQ_IOMUXC_SAI1_MCLK_GPIO4_IO20 0x19
MX8MQ_IOMUXC_SAI5_MCLK_GPIO3_IO25 0x19
>;
};
for sysfs : I did a echo of the gpio number (bank-1)*32 + pinnumber to the /sys/class/gpio/export. and then tried setting the value after setting the direction.
with both the MCLK , I am not able to toggle it, but I am able to do the same for SAI3_RXD.(able to toggle).
Thanks and Regards
Terry
Hi,
Please check that you don’t have both SAI1_MCLK & SAI5_MCLK, muxed to other pads.
Also, if you could share the dts so I may take a look to it may be great.
Best regards,
Aldo.
HI Aldo,
Thank you for the response, Found the issue , it was HW issue , because of the soldering , tried with a new board, it works as expected. Thank you for the help, highly appreciate it.
Thanks and Regards
Terry