arm64: dts: rockchip: use BCLK to GPIO switch on rk3399
authorJudy Hsiao <judyhsiao@chromium.org>
Fri, 8 Jul 2022 08:07:26 +0000 (08:07 +0000)
committerHeiko Stuebner <heiko@sntech.de>
Fri, 9 Sep 2022 23:08:48 +0000 (01:08 +0200)
commit91419ae0420f0c91a326655d687b740826d0a3f9
tree449f09de483eedfe4cd2f7554adb686edad6628a
parent03d86fb5a56919ccf47e1cc5861bb5452017ab93
arm64: dts: rockchip: use BCLK to GPIO switch on rk3399

We discoverd that the state of BCLK on, LRCLK off and SD_MODE on
may cause the speaker melting issue. Removing LRCLK while BCLK
is present can cause unexpected output behavior including a large
DC output voltage as described in the Max98357a datasheet.

In order to:
  1. prevent BCLK from turning on by other component.
  2. keep BCLK and LRCLK being present at the same time

This patch adjusts the device tree to allow BCLK to switch
to GPIO func before LRCLK output, and switch back during
LRCLK is output.

Signed-off-by: Judy Hsiao <judyhsiao@chromium.org>
Reviewed-by: Brian Norris <briannorris@chromium.org>
Link: https://lore.kernel.org/r/20220708080726.4170711-1-judyhsiao@chromium.org
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
arch/arm64/boot/dts/rockchip/rk3399-gru-scarlet.dtsi
arch/arm64/boot/dts/rockchip/rk3399.dtsi