Devicetree
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Linus Walleij" <linusw@kernel.org>
Cc: robh@kernel.org, conor+dt@kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCH v2 2/2] ARM: dts: ux500: Use AB8505 charger compatible
Date: Fri, 18 Sep 2026 17:07:33 +0000	[thread overview]
Message-ID: <20260918170734.2D5861F00898@smtp.kernel.org> (raw)
In-Reply-To: <20260918-ab8500-charger-dt-v2-2-5f17c332a2a7@kernel.org>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [High] driver: ab8500_charger probe fails due to missing interrupts
--

commit 2f9148d4b2214ca2ec295f5eefd937097f9378a9
Author: Linus Walleij <linusw@kernel.org>

ARM: dts: ux500: Use AB8505 charger compatible

This commit identifies the AB8505 charger using its variant-specific
compatible while retaining the AB8500 compatible as a fallback. It
removes five main charger interrupt sources that are non-existent on the
AB8505 from the device tree node.

> diff --git a/arch/arm/boot/dts/st/ste-ab8505.dtsi b/arch/arm/boot/dts/st/ste-ab8505.dtsi
> index 131c82508e820..4c9a8418f225a 100644
> --- a/arch/arm/boot/dts/st/ste-ab8505.dtsi
> +++ b/arch/arm/boot/dts/st/ste-ab8505.dtsi
> @@ -137,13 +137,9 @@ ab8500_btemp {
>  				};
>  
>  				ab8500_charger {
> -					compatible = "stericsson,ab8500-charger";
> -					interrupts = <10 IRQ_TYPE_LEVEL_HIGH>,
> -						     <11 IRQ_TYPE_LEVEL_HIGH>,
> -						     <0 IRQ_TYPE_LEVEL_HIGH>,
> -						     <107 IRQ_TYPE_LEVEL_HIGH>,
> -						     <106 IRQ_TYPE_LEVEL_HIGH>,
> -						     <14 IRQ_TYPE_LEVEL_HIGH>,
> +					compatible = "stericsson,ab8505-charger",
> +						     "stericsson,ab8500-charger";
> +					interrupts = <14 IRQ_TYPE_LEVEL_HIGH>,
>  						     <15 IRQ_TYPE_LEVEL_HIGH>,
>  						     <79 IRQ_TYPE_LEVEL_HIGH>,
>  						     <105 IRQ_TYPE_LEVEL_HIGH>,
> @@ -152,12 +148,7 @@ ab8500_charger {
>  						     <22 IRQ_TYPE_LEVEL_HIGH>,
>  						     <21 IRQ_TYPE_LEVEL_HIGH>,
>  						     <16 IRQ_TYPE_LEVEL_HIGH>;
> -					interrupt-names = "MAIN_CH_UNPLUG_DET",
> -							  "MAIN_CHARGE_PLUG_DET",
> -							  "MAIN_EXT_CH_NOT_OK",
> -							  "MAIN_CH_TH_PROT_R",
> -							  "MAIN_CH_TH_PROT_F",
> -							  "VBUS_DET_F",
> +					interrupt-names = "VBUS_DET_F",
>  							  "VBUS_DET_R",
>  							  "USB_LINK_STATUS",
>  							  "USB_CH_TH_PROT_R",

[Severity: High]
Will this cause the ab8500_charger driver probe to fail on AB8505 platforms?

The device tree node relies on the "stericsson,ab8500-charger" fallback
compatible, but removes several interrupts. When the driver probes, it
unconditionally searches for all 14 interrupts defined in ab8500_charger_irq:

drivers/power/supply/ab8500_charger.c:ab8500_charger_probe() {
	...
	/* Request interrupts */
	for (i = 0; i < ARRAY_SIZE(ab8500_charger_irq); i++) {
		irq = platform_get_irq_byname(pdev, ab8500_charger_irq[i].name);
		if (irq < 0)
			return irq;
	...
}

Because interrupts like "MAIN_CH_UNPLUG_DET" are now missing from the device
tree, platform_get_irq_byname() will return a negative error code. This
triggers the if (irq < 0) check and immediately aborts the probe, leaving
the system without USB charger support.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260918-ab8500-charger-dt-v2-0-5f17c332a2a7@kernel.org?part=2

  reply	other threads:[~2026-09-18 17:07 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-18 16:56 [PATCH v2 0/2] power: supply: Correct AB8505 charger device tree Linus Walleij
2026-09-18 16:56 ` [PATCH v2 1/2] dt-bindings: power: supply: ab8500: Add AB8505 charger Linus Walleij
2026-09-18 17:08   ` sashiko-bot
2026-09-20 18:14   ` Krzysztof Kozlowski
2026-09-18 16:56 ` [PATCH v2 2/2] ARM: dts: ux500: Use AB8505 charger compatible Linus Walleij
2026-09-18 17:07   ` sashiko-bot [this message]
2026-09-20 22:49     ` Linus Walleij

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=20260918170734.2D5861F00898@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=linusw@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox