arm64: dts: rockchip: yy3588: bind ES8388 codec via es8328 driver#499
Conversation
The codec is an ES8388; the es8323 binding predates SND_SOC_ES8328 being available in the kernel config. Signed-off-by: SuperKali <hello@superkali.me>
WalkthroughThis PR updates the device tree for the RK3588 Youyeetoo YY3588 board to replace the ES8323 audio codec with ES8388. The sound card node Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (2)
arch/arm64/boot/dts/rockchip/rk3588-youyeetoo-yy3588.dts (2)
613-614:⚠️ Potential issue | 🟡 MinorES8388 supports 12.288 MHz MCLK; DT value at lines 613-614 is appropriate.
- The ES8388 datasheet lists 12.288 MHz as one of the supported master-clock input frequencies, so
assigned-clock-rates = <12288000>;matches ES8388 requirements.- The “22.5792 or 11.2896 MHz” wording appears ES8328-specific; ensure the DT binding/description for this node references ES8388 (not ES8328) if that text was copied.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@arch/arm64/boot/dts/rockchip/rk3588-youyeetoo-yy3588.dts` around lines 613 - 614, The device tree already sets assigned-clock-rates = <12288000> and assigned-clocks = <&mclkout_i2s0> which is correct for ES8388; keep those values, but update the node's binding/description text (where the ES8328 wording was copied) to reference ES8388 and remove the “22.5792 or 11.2896 MHz” ES8328-specific phrasing so the comment/binding matches the ES8388-supported 12.288 MHz MCLK; locate the audio codec node that contains assigned-clock-rates/assigned-clocks and adjust its binding/description accordingly.
609-620:⚠️ Potential issue | 🔴 CriticalAdd missing DVDD/AVDD/PVDD (and HPVDD/IPVDD) regulator supply properties for ES8388
The ES8328 DT binding marks DVDD-supply, AVDD-supply, PVDD-supply, and IPVDD-supply as required, and the ES8328/ES8388 driver bulk-acquires DVDD/AVDD/PVDD/HPVDD viadevm_regulator_bulk_get()(no optional fallback). Inarch/arm64/boot/dts/rockchip/rk3588-youyeetoo-yy3588.dts(es8388@11, lines 609-620), those*-supplyproperties are missing, so regulator acquisition/probe cannot satisfy the contract (also resolve the binding/driver naming mismatch: IPVDD vs HPVDD).🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@arch/arm64/boot/dts/rockchip/rk3588-youyeetoo-yy3588.dts` around lines 609 - 620, The es8388@11 device node is missing the required regulator supply properties; add DVDD-supply, AVDD-supply, PVDD-supply and the video/IO regulator property the driver expects (resolve the IPVDD/HPVDD name mismatch by using the exact supply name the driver/binding requires—e.g., IPVDD-supply if the binding expects IPVDD, or HPVDD-supply if the driver uses HPVDD) and point each to the proper regulator phandle(s) defined elsewhere in the DTS (for example &vdd_xx or &vcc_xx nodes); update the es8388 node (es8388: es8388@11) to include these four supply properties so devm_regulator_bulk_get() can acquire them.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Outside diff comments:
In `@arch/arm64/boot/dts/rockchip/rk3588-youyeetoo-yy3588.dts`:
- Around line 613-614: The device tree already sets assigned-clock-rates =
<12288000> and assigned-clocks = <&mclkout_i2s0> which is correct for ES8388;
keep those values, but update the node's binding/description text (where the
ES8328 wording was copied) to reference ES8388 and remove the “22.5792 or
11.2896 MHz” ES8328-specific phrasing so the comment/binding matches the
ES8388-supported 12.288 MHz MCLK; locate the audio codec node that contains
assigned-clock-rates/assigned-clocks and adjust its binding/description
accordingly.
- Around line 609-620: The es8388@11 device node is missing the required
regulator supply properties; add DVDD-supply, AVDD-supply, PVDD-supply and the
video/IO regulator property the driver expects (resolve the IPVDD/HPVDD name
mismatch by using the exact supply name the driver/binding requires—e.g.,
IPVDD-supply if the binding expects IPVDD, or HPVDD-supply if the driver uses
HPVDD) and point each to the proper regulator phandle(s) defined elsewhere in
the DTS (for example &vdd_xx or &vcc_xx nodes); update the es8388 node (es8388:
es8388@11) to include these four supply properties so devm_regulator_bulk_get()
can acquire them.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: f8e44f75-b7ff-4308-9792-7e9520b8a4eb
📒 Files selected for processing (1)
arch/arm64/boot/dts/rockchip/rk3588-youyeetoo-yy3588.dts
The codec on this board is an ES8388. The es8323 binding dates back to when the es8328 driver was not enabled in the kernel config, hence the old comment claiming only the es8323 driver works.
With the driver enabled everything works: playback, jack detection and headset keys tested on the board. Card and sound node renamed accordingly, so vendor and mainline kernels share one ALSA state.