From: sashiko-bot@kernel.org
To: wyibo6109@gmail.com
Cc: devicetree@vger.kernel.org, robh@kernel.org, conor+dt@kernel.org,
media-ci@linuxtv.org
Subject: Re: [PATCH 1/2] dt-bindings: media: i2c: dongwoon,dw9719: Document DW9714VA
Date: Fri, 16 Oct 2026 09:18:31 +0000 [thread overview]
Message-ID: <sashiko-outbox-174065@kernel.org> (raw)
In-Reply-To: <20261016090930.947830-1-wyibo6109@gmail.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] dt-bindings: media: i2c: missing constraint on dongwoon,sac-mode causes driver truncation
--
commit 84f26b8e140dafb250c88ee38251a980482fc1db
Author: Yibo Wang <wyibo6109@gmail.com>
dt-bindings: media: i2c: dongwoon,dw9719: Document DW9714VA
This commit documents the DW9714VA silicon revision found on OnePlus Pad 4
camera modules. It adds the dongwoon,dw9714va compatible string to the
dongwoon,dw9719 schema, noting that this revision uses a register layout
similar to the DW9719 rather than the standard DW9714V.
Link: https://lore.kernel.org/linux-media/20260729-dw9714v-v1-0-3c479b3cf8c0@ixit.cz/
[Severity: Medium]
In Documentation/devicetree/bindings/media/i2c/dongwoon,dw9719.yaml at line 40,
the global property dongwoon,sac-mode allows values up to 7 and defaults to 4.
However, does this lack a necessary constraint for the DW9714VA and DW9800K
variants?
Looking at dw9719_power_up() in drivers/media/i2c/dw9719.c at line 133, the
driver handles the sac_mode configuration:
drivers/media/i2c/dw9719.c:dw9719_power_up() {
...
case DW9800K:
cci_write(dw9719->regmap, DW9719_CONTROL, DW9719_ENABLE_RINGING, &ret);
cci_write(dw9719->regmap, DW9719_MODE,
dw9719->sac_mode << DW9800K_MODE_SAC_SHIFT, &ret);
...
}
If a device tree uses the schema's default of 4 (or specifies 4-7) for these
variants, the driver shifts the value by DW9800K_MODE_SAC_SHIFT (which is 6).
This produces a value >= 256 which will truncate to 0 when written to the 8-bit
DW9719_MODE register via cci_write().
Because this truncation silently configures the device into Direct mode (0)
instead of the requested SAC mode, causing camera ringing and incorrect VCM
operation, should the schema include an allOf conditional block restricting
dongwoon,sac-mode to a maximum of 3 for the dongwoon,dw9714va and
dongwoon,dw9800k compatibles?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261016090930.947830-1-wyibo6109@gmail.com?part=1
next prev parent reply other threads:[~2026-10-16 9:18 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-16 9:09 [PATCH 1/2] dt-bindings: media: i2c: dongwoon,dw9719: Document DW9714VA wyibo6109
2026-10-16 9:09 ` [PATCH 2/2] media: i2c: dw9719: Add DW9714VA support wyibo6109
2026-10-16 9:18 ` sashiko-bot
2026-10-16 9:18 ` sashiko-bot [this message]
2026-10-16 13:03 ` [PATCH 1/2] dt-bindings: media: i2c: dongwoon,dw9719: Document DW9714VA Rob Herring (Arm)
2026-10-16 13:11 ` David Heidelberg
2026-10-16 16:04 ` Yibo Wang
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=sashiko-outbox-174065@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=media-ci@linuxtv.org \
--cc=robh@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
--cc=wyibo6109@gmail.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