From: Hermes Wu via B4 Relay <devnull+Hermes.wu.ite.com.tw@kernel.org>
To: Hermes Wu <Hermes.Wu@ite.com.tw>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Hans Verkuil <hverkuil+cisco@kernel.org>,
Hans Verkuil <hverkuil@kernel.org>
Cc: linux-media@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org, Mark Brown <broonie@kernel.org>,
Liam Girdwood <lgirdwood@gmail.com>,
linux-sound@vger.kernel.org, linux-api@vger.kernel.org,
Hermes Wu <Hermes.wu@ite.com.tw>
Subject: [PATCH v2 8/9] media: i2c: it6625: use the standard audio rate and present controls
Date: Tue, 24 Nov 2026 11:04:45 +0800 [thread overview]
Message-ID: <20261124-upstream-it6625-alsa-i2s-v2-8-a154685f6989@ite.com.tw> (raw)
In-Reply-To: <20261124-upstream-it6625-alsa-i2s-v2-0-a154685f6989@ite.com.tw>
From: Hermes Wu <Hermes.wu@ite.com.tw>
The driver reports the HDMI audio sampling rate and whether audio is
present through the driver-specific controls
V4L2_CID_IT6625_AUDIO_SAMPLING_RATE and V4L2_CID_IT6625_AUDIO_PRESENT.
There are now standard controls for both.
Report V4L2_CID_DV_RX_AUDIO_SAMPLING_RATE and
V4L2_CID_DV_RX_AUDIO_PRESENT instead, with the same range and the same
values. The driver-specific control IDs are no longer used.
---
drivers/media/i2c/it6625.c | 30 ++++--------------------------
1 file changed, 4 insertions(+), 26 deletions(-)
diff --git a/drivers/media/i2c/it6625.c b/drivers/media/i2c/it6625.c
index 72ca1d4ecdc932609f1a38129bfa1e188a024ddf..e4487e8111b94b2fa9f599e37ecd2b8a11425862 100644
--- a/drivers/media/i2c/it6625.c
+++ b/drivers/media/i2c/it6625.c
@@ -2127,28 +2127,6 @@ static const struct v4l2_subdev_internal_ops it6625_internal_ops = {
.init_state = it6625_init_state,
};
-static const struct v4l2_ctrl_config it6625_ctrl_audio_sampling_rate = {
- .id = V4L2_CID_IT6625_AUDIO_SAMPLING_RATE,
- .name = "Audio Sampling Rate",
- .type = V4L2_CTRL_TYPE_INTEGER,
- .min = 0,
- .max = 1536000,
- .step = 1,
- .def = 0,
- .flags = V4L2_CTRL_FLAG_READ_ONLY,
-};
-
-static const struct v4l2_ctrl_config it6625_ctrl_audio_present = {
- .id = V4L2_CID_IT6625_AUDIO_PRESENT,
- .name = "Audio Present",
- .type = V4L2_CTRL_TYPE_BOOLEAN,
- .min = 0,
- .max = 1,
- .step = 1,
- .def = 0,
- .flags = V4L2_CTRL_FLAG_READ_ONLY,
-};
-
static int it6625_v4l2_init_controls(struct v4l2_subdev *sd)
{
struct it6625 *it6625 = sd_to_6625(sd);
@@ -2163,11 +2141,11 @@ static int it6625_v4l2_init_controls(struct v4l2_subdev *sd)
0, 1, 0, 0);
it6625->ctrl_audio_sampling_rate =
- v4l2_ctrl_new_custom(hdl,
- &it6625_ctrl_audio_sampling_rate,
- NULL);
+ v4l2_ctrl_new_std(hdl, NULL, V4L2_CID_DV_RX_AUDIO_SAMPLING_RATE,
+ 0, 1536000, 1, 0);
it6625->ctrl_audio_present =
- v4l2_ctrl_new_custom(hdl, &it6625_ctrl_audio_present, NULL);
+ v4l2_ctrl_new_std(hdl, NULL, V4L2_CID_DV_RX_AUDIO_PRESENT,
+ 0, 1, 1, 0);
it6625->ctrl_audio_type =
v4l2_ctrl_new_std_menu(hdl, NULL, V4L2_CID_DV_RX_AUDIO_TYPE,
V4L2_DV_RX_AUDIO_TYPE_ONE_BIT, 0,
--
2.34.1
next prev parent reply other threads:[~2026-11-24 3:05 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-24 3:04 [PATCH v2 0/9] media: i2c: it6625: add HDMI audio capture over I2S Hermes Wu via B4 Relay
2026-11-24 3:04 ` [PATCH v2 1/9] media: v4l2-ctrls: add DV RX audio sampling rate and present controls Hermes Wu via B4 Relay
2026-11-24 4:02 ` Hermes.Wu
2026-11-24 3:04 ` [PATCH v2 2/9] media: v4l2-ctrls: add the DV RX audio type control Hermes Wu via B4 Relay
2026-11-24 4:03 ` Hermes.Wu
2026-11-24 3:04 ` [PATCH v2 3/9] media: i2c: tc358743: also report the standard audio controls Hermes Wu via B4 Relay
2026-11-24 4:04 ` Hermes.Wu
2026-11-24 3:04 ` [PATCH v2 4/9] dt-bindings: media: ite,it6625: add audio DAI properties Hermes Wu via B4 Relay
2026-11-24 3:04 ` [PATCH v2 5/9] media: i2c: it6625: decode audio status fields with FIELD_GET() Hermes Wu via B4 Relay
2026-11-24 3:04 ` [PATCH v2 6/9] media: i2c: it6625: add I2S audio capture DAI Hermes Wu via B4 Relay
2026-11-24 3:04 ` [PATCH v2 7/9] media: i2c: it6625: capture compressed and HBR audio, not just LPCM Hermes Wu via B4 Relay
2026-11-24 3:04 ` Hermes Wu via B4 Relay [this message]
2026-11-24 4:04 ` [PATCH v2 8/9] media: i2c: it6625: use the standard audio rate and present controls Hermes.Wu
2026-11-24 3:04 ` [PATCH v2 9/9] media: uapi: it6625: remove the driver-specific audio controls Hermes Wu via B4 Relay
2026-11-24 4:04 ` Hermes.Wu
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=20261124-upstream-it6625-alsa-i2s-v2-8-a154685f6989@ite.com.tw \
--to=devnull+hermes.wu.ite.com.tw@kernel.org \
--cc=Hermes.Wu@ite.com.tw \
--cc=broonie@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=hverkuil+cisco@kernel.org \
--cc=hverkuil@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=lgirdwood@gmail.com \
--cc=linux-api@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-sound@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=robh@kernel.org \
/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®