From: sashiko-bot@kernel.org
To: "Akhil R" <akhilrajeev@nvidia.com>
Cc: linux-i3c@lists.infradead.org,
"Alexandre Belloni" <alexandre.belloni@bootlin.com>,
conor+dt@kernel.org, Frank.Li@kernel.org,
devicetree@vger.kernel.org, robh@kernel.org,
linux-hwmon@vger.kernel.org
Subject: Re: [PATCH v7 09/12] i3c: dw-i3c-master: Add ACPI ID for Tegra410
Date: Tue, 28 Jul 2026 07:19:22 +0000 [thread overview]
Message-ID: <20260728071923.2EC361F00A3D@smtp.kernel.org> (raw)
In-Reply-To: <20260728065955.809445-10-akhilrajeev@nvidia.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
Pre-existing issues:
- [High] Pointer address assigned to an integer bitmask variable for quirks under ACPI PRP0001 matching.
--
--- Patch [9]: [PATCH v7 09/12] i3c: dw-i3c-master: Add ACPI ID for Tegra410 ---
commit 4b2659ca2047946e238179b5da94407cbd49ffa2
Author: Akhil R <akhilrajeev@nvidia.com>
i3c: dw-i3c-master: Add ACPI ID for Tegra410
Update variable names to generic names and add Tegra410 ACPI ID to
support the I3C controller in Tegra410, which is a DesignWare I3C host
controller.
> diff --git a/drivers/i3c/master/dw-i3c-master.c b/drivers/i3c/master/dw-i3c-master.c
> index 273d7a0020993..12069aa56fad8 100644
> --- a/drivers/i3c/master/dw-i3c-master.c
> +++ b/drivers/i3c/master/dw-i3c-master.c
> @@ -1855,11 +1855,12 @@ static const struct of_device_id dw_i3c_master_of_match[] = {
> };
> MODULE_DEVICE_TABLE(of, dw_i3c_master_of_match);
>
> -static const struct acpi_device_id amd_i3c_device_match[] = {
> +static const struct acpi_device_id dw_i3c_master_acpi_match[] = {
> { "AMDI0015", AMD_I3C_OD_PP_TIMING },
> + { "NVDA2018", DW_I3C_ACPI_SKIP_CLK_RST },
> { }
> };
[Severity: High]
This is a pre-existing issue, but does dw_i3c_common_probe() improperly cast
pointers to integer bitmasks under ACPI PRP0001 matching?
If a system uses the ACPI PRP0001 HID alongside the "altr,agilex5-dw-i3c-master"
compatible string, device_get_match_data() will return a pointer to
altr_agilex5_drvdata.
Because the device has an ACPI companion, the probe function processes it like
this:
drivers/i3c/master/dw-i3c-master.c:dw_i3c_common_probe() {
...
if (has_acpi_companion(&pdev->dev)) {
quirks = (unsigned long)device_get_match_data(&pdev->dev);
} else if (pdev->dev.of_node) {
...
}
Will this cause the memory address of altr_agilex5_drvdata to be cast directly
to an integer bitmask, resulting in random quirks being activated based on
memory alignment (e.g., falsely applying DW_I3C_ACPI_SKIP_CLK_RST or
DW_I3C_DISABLE_RUNTIME_PM_QUIRK)?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260728065955.809445-1-akhilrajeev@nvidia.com?part=9
WARNING: multiple messages have this Message-ID (diff)
From: sashiko-bot@kernel.org
To: "Akhil R" <akhilrajeev@nvidia.com>
Cc: linux-i3c@lists.infradead.org,
"Alexandre Belloni" <alexandre.belloni@bootlin.com>,
conor+dt@kernel.org, Frank.Li@kernel.org,
devicetree@vger.kernel.org, robh@kernel.org,
linux-hwmon@vger.kernel.org
Subject: Re: [PATCH v7 09/12] i3c: dw-i3c-master: Add ACPI ID for Tegra410
Date: Tue, 28 Jul 2026 07:19:22 +0000 [thread overview]
Message-ID: <20260728071923.2EC361F00A3D@smtp.kernel.org> (raw)
In-Reply-To: <20260728065955.809445-10-akhilrajeev@nvidia.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
Pre-existing issues:
- [High] Pointer address assigned to an integer bitmask variable for quirks under ACPI PRP0001 matching.
--
--- Patch [9]: [PATCH v7 09/12] i3c: dw-i3c-master: Add ACPI ID for Tegra410 ---
commit 4b2659ca2047946e238179b5da94407cbd49ffa2
Author: Akhil R <akhilrajeev@nvidia.com>
i3c: dw-i3c-master: Add ACPI ID for Tegra410
Update variable names to generic names and add Tegra410 ACPI ID to
support the I3C controller in Tegra410, which is a DesignWare I3C host
controller.
> diff --git a/drivers/i3c/master/dw-i3c-master.c b/drivers/i3c/master/dw-i3c-master.c
> index 273d7a0020993..12069aa56fad8 100644
> --- a/drivers/i3c/master/dw-i3c-master.c
> +++ b/drivers/i3c/master/dw-i3c-master.c
> @@ -1855,11 +1855,12 @@ static const struct of_device_id dw_i3c_master_of_match[] = {
> };
> MODULE_DEVICE_TABLE(of, dw_i3c_master_of_match);
>
> -static const struct acpi_device_id amd_i3c_device_match[] = {
> +static const struct acpi_device_id dw_i3c_master_acpi_match[] = {
> { "AMDI0015", AMD_I3C_OD_PP_TIMING },
> + { "NVDA2018", DW_I3C_ACPI_SKIP_CLK_RST },
> { }
> };
[Severity: High]
This is a pre-existing issue, but does dw_i3c_common_probe() improperly cast
pointers to integer bitmasks under ACPI PRP0001 matching?
If a system uses the ACPI PRP0001 HID alongside the "altr,agilex5-dw-i3c-master"
compatible string, device_get_match_data() will return a pointer to
altr_agilex5_drvdata.
Because the device has an ACPI companion, the probe function processes it like
this:
drivers/i3c/master/dw-i3c-master.c:dw_i3c_common_probe() {
...
if (has_acpi_companion(&pdev->dev)) {
quirks = (unsigned long)device_get_match_data(&pdev->dev);
} else if (pdev->dev.of_node) {
...
}
Will this cause the memory address of altr_agilex5_drvdata to be cast directly
to an integer bitmask, resulting in random quirks being activated based on
memory alignment (e.g., falsely applying DW_I3C_ACPI_SKIP_CLK_RST or
DW_I3C_DISABLE_RUNTIME_PM_QUIRK)?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260728065955.809445-1-akhilrajeev@nvidia.com?part=9
--
linux-i3c mailing list
linux-i3c@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-i3c
next prev parent reply other threads:[~2026-07-28 7:19 UTC|newest]
Thread overview: 50+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-28 6:59 [PATCH v7 00/12] Support ACPI and SETAASA device discovery Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 6:59 ` [PATCH v7 01/12] dt-bindings: i3c: Add mipi-i3c-static-method to support SETAASA Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 7:08 ` sashiko-bot
2026-07-28 7:08 ` sashiko-bot
2026-07-28 6:59 ` [PATCH v7 02/12] i3c: master: Use unified device property interface Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 7:21 ` sashiko-bot
2026-07-28 7:21 ` sashiko-bot
2026-07-28 6:59 ` [PATCH v7 03/12] i3c: master: Support ACPI enumeration of child devices Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 7:18 ` sashiko-bot
2026-07-28 7:18 ` sashiko-bot
2026-07-28 6:59 ` [PATCH v7 04/12] i3c: master: Add support for devices using SETAASA Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 7:22 ` sashiko-bot
2026-07-28 7:22 ` sashiko-bot
2026-07-28 6:59 ` [PATCH v7 05/12] i3c: master: Add support for devices without PID Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 7:20 ` sashiko-bot
2026-07-28 7:20 ` sashiko-bot
2026-07-28 6:59 ` [PATCH v7 06/12] i3c: master: match I3C device through DT and ACPI Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 7:20 ` sashiko-bot
2026-07-28 7:20 ` sashiko-bot
2026-07-28 6:59 ` [PATCH v7 07/12] i3c: dw-i3c-master: Add SETAASA as supported CCC Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 7:14 ` sashiko-bot
2026-07-28 7:14 ` sashiko-bot
2026-07-28 6:59 ` [PATCH v7 08/12] i3c: dw-i3c-master: Add ACPI core clock frequency quirk Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 7:17 ` sashiko-bot
2026-07-28 7:17 ` sashiko-bot
2026-07-28 6:59 ` [PATCH v7 09/12] i3c: dw-i3c-master: Add ACPI ID for Tegra410 Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 7:19 ` sashiko-bot [this message]
2026-07-28 7:19 ` sashiko-bot
2026-07-28 6:59 ` [PATCH v7 10/12] hwmon: spd5118: Remove 16-bit addressing Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 7:18 ` sashiko-bot
2026-07-28 7:18 ` sashiko-bot
2026-07-28 6:59 ` [PATCH v7 11/12] hwmon: spd5118: Add I3C support Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 7:32 ` sashiko-bot
2026-07-28 7:32 ` sashiko-bot
2026-07-28 6:59 ` [PATCH v7 12/12] arm64: defconfig: Enable I3C and SPD5118 hwmon Akhil R
2026-07-28 6:59 ` Akhil R
2026-07-28 7:24 ` sashiko-bot
2026-07-28 7:24 ` sashiko-bot
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=20260728071923.2EC361F00A3D@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=Frank.Li@kernel.org \
--cc=akhilrajeev@nvidia.com \
--cc=alexandre.belloni@bootlin.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=linux-hwmon@vger.kernel.org \
--cc=linux-i3c@lists.infradead.org \
--cc=robh@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.