mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Xing Zheng <zhengxing@rock-chips.com>
To: broonie@kernel.org, heiko@sntech.de, linux-sound@vger.kernel.org
Cc: luca.ceresoli@bootlin.com, lgirdwood@gmail.com, perex@perex.cz,
	tiwai@suse.com, linux-kernel@vger.kernel.org, robh@kernel.org,
	krzk+dt@kernel.org, conor+dt@kernel.org,
	devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-rockchip@lists.infradead.org, huangtao@rock-chips.com,
	sugar.zhang@rock-chips.com, lxt@rock-chips.com,
	xing.zheng@rock-chips.com
Subject: [PATCH v2 0/3] RK3308 codec audio sequencing and headphone support
Date: Sun,  1 Nov 2026 12:41:46 +0800	[thread overview]
Message-ID: <20261101044149.2018744-1-zhengxing@rock-chips.com> (raw)
In-Reply-To: <20261101040125.1864141-1-zhengxing@rock-chips.com>

Restore the full RK3308 codec analog power sequencing and headphone
support from the downstream 6.12 implementation, adapted to the current
ASoC interfaces. Keep the complete codec source and register definitions
in one patch, alongside the binding and SoC detection-resource changes.

The codec change includes revision-specific ADC/DAC supply sequencing,
reference-current and headphone gain ramps, A/B CIC fades, active ADC
resynchronization, MICBIAS restoration, microphone boost controls, ADC
stereo-group routing and B/C headphone detection. Machine drivers retain
ownership of the external amplifier GPIOs.

The SDK-only multicodecs shutdown fix and EVB/VAD routing patch are
outside this series because their target drivers and board files are
not present in the upstream tree.

Patches 1-2 are for the ASoC tree; patch 3 is for the Rockchip DT tree.
The detection resources remain optional for existing device trees.

Changes since v1:
- Restore the full analog sequencing omitted from the initial posting.
- Consolidate all codec C/header changes into a single patch.
- Use the original binding descriptions and legacy IRQ lookup rules.
- Preserve upstream automatic DAI format selection and adapt accessors.
- Use sleepable waits while preserving downstream minimum delay requests.
- Keep the SDK-only machine-driver and EVB/VAD work deferred.

Previous posting:
https://lore.kernel.org/r/20261101040125.1864141-1-zhengxing@rock-chips.com

Validation:
- ARM64 defconfig plus built-in RK3308 codec, Image and all six RK3308
  DTBs build on broonie/for-next and the Linus baseline with GCC 14.3.1.
- Codec W=1 builds, binding/example validation and codec-schema checks
  on the six DTBs pass; strict checkpatch reports no diagnostics.
- The three patches apply to the Linus baseline without 3-way fallback;
  range-diff reports all three patches unchanged.
- Extracted SDK/upstream analog functions match across 11520 modeled
  register traces, including operation order and minimum delay requests,
  under ASan/UBSan. Parameter/error-path probes also pass.

These host models do not verify actual hardware settling time.
No new playback, capture, hotplug, suspend/resume or electrical timing
measurements have been performed on hardware with this upstream series.

Xing Zheng (3):
  ASoC: dt-bindings: rk3308-codec: describe detection and ADC routing
  ASoC: codecs: rk3308: restore audio and headphone support
  arm64: dts: rockchip: restore RK3308 codec detection resources

 .../bindings/sound/rockchip,rk3308-codec.yaml |   55 +
 arch/arm64/boot/dts/rockchip/rk3308.dtsi      |    4 +
 sound/soc/codecs/rk3308_codec.c               | 1155 ++++++++++++++---
 sound/soc/codecs/rk3308_codec.h               |   18 +-
 4 files changed, 1064 insertions(+), 168 deletions(-)


base-commit: 11ae63bd9030349a0136fb2edd1622a4a029edc8

  parent reply	other threads:[~2026-11-01  4:42 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-01  4:01 [PATCH v1 0/6] RK3308 codec configuration and headphone detection Xing Zheng
2026-11-01  4:01 ` [PATCH v1 1/6] ASoC: codecs: rk3308: restore MICBIAS voltage after reset Xing Zheng
2026-11-01  4:01 ` [PATCH v1 2/6] ASoC: codecs: rk3308: expose per-channel microphone boost Xing Zheng
2026-11-01  4:01 ` [PATCH v1 3/6] ASoC: dt-bindings: rk3308-codec: describe ADC routing and jack detection Xing Zheng
2026-11-01  4:01 ` [PATCH v1 4/6] ASoC: codecs: rk3308: support ADC stereo-group routing Xing Zheng
2026-11-01  4:01 ` [PATCH v1 5/6] ASoC: codecs: rk3308: report B/C headphone detection through set_jack Xing Zheng
2026-11-01  4:01 ` [PATCH v1 6/6] arm64: dts: rockchip: describe RK3308 codec detection resources Xing Zheng
2026-11-01  4:41 ` Xing Zheng [this message]
2026-11-01  4:41   ` [PATCH v2 1/3] ASoC: dt-bindings: rk3308-codec: describe detection and ADC routing Xing Zheng
2026-11-01 22:45     ` Mark Brown
2026-11-05  1:25       ` Xing Zheng
2026-11-04 13:10     ` Krzysztof Kozlowski
2026-11-05  1:25       ` Xing Zheng
2026-11-01  4:41   ` [PATCH v2 2/3] ASoC: codecs: rk3308: restore audio and headphone support Xing Zheng
2026-11-08 11:49     ` Mark Brown
2026-11-01  4:41   ` [PATCH v2 3/3] arm64: dts: rockchip: restore RK3308 codec detection resources Xing Zheng

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261101044149.2018744-1-zhengxing@rock-chips.com \
    --to=zhengxing@rock-chips.com \
    --cc=broonie@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=heiko@sntech.de \
    --cc=huangtao@rock-chips.com \
    --cc=krzk+dt@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rockchip@lists.infradead.org \
    --cc=linux-sound@vger.kernel.org \
    --cc=luca.ceresoli@bootlin.com \
    --cc=lxt@rock-chips.com \
    --cc=perex@perex.cz \
    --cc=robh@kernel.org \
    --cc=sugar.zhang@rock-chips.com \
    --cc=tiwai@suse.com \
    --cc=xing.zheng@rock-chips.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®