Linux kernel and device drivers for NXP i.MX platforms
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
Cc: Frank.Li@kernel.org, imx@lists.linux.dev
Subject: Re: [PATCH v1 4/6] power: Use named initializers for platform_device_id arrays
Date: Fri, 29 May 2026 11:02:29 +0000	[thread overview]
Message-ID: <20260529110229.9474D1F00893@smtp.kernel.org> (raw)
In-Reply-To: <1ceacf4f9c3f827bcad85b378aa04cdca1c04635.1780048925.git.u.kleine-koenig@baylibre.com>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] The explicit `.driver_data` initialization `TYPE_MAX8998` for `max8998-battery` was silently dropped without mention in the commit message.
--

commit 02f2c38ebeef8dff34934050c70916818fb36a18
Author: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com>

power: Use named initializers for platform_device_id arrays

This commit updates various power supply and reset drivers to use named
initializers for platform_device_id arrays. It also unifies spacing and
comma usage across these array definitions.

> diff --git a/drivers/power/supply/max8998_charger.c b/drivers/power/supply/max8998_charger.c
> index 418b882b163d1..b0eda2b51e7f0 100644
> --- a/drivers/power/supply/max8998_charger.c
> +++ b/drivers/power/supply/max8998_charger.c
> @@ -188,7 +188,7 @@ static int max8998_battery_probe(struct platform_device *pdev)
>  }
>  
>  static const struct platform_device_id max8998_battery_id[] = {
> -	{ "max8998-battery", TYPE_MAX8998 },
> +	{ .name = "max8998-battery" },

[Severity: Low]
Is it intentional that the TYPE_MAX8998 driver data assignment was dropped
here?

The explicit .driver_data initialization TYPE_MAX8998 for max8998-battery
was silently dropped without mention in the commit message. While this has
no functional impact as TYPE_MAX8998 evaluates to 0 and the driver data is
entirely unused in max8998_battery_probe(), it constitutes a minor code
and commit message mismatch.

Should this removal be documented in the commit message, or perhaps moved
to an earlier patch in the series that drops unused assignments of
platform_device_id driver data?

>  	{ }
>  };
>  MODULE_DEVICE_TABLE(platform, max8998_battery_id);

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/cover.1780048925.git.u.kleine-koenig@baylibre.com?part=4

  reply	other threads:[~2026-05-29 11:02 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-29 10:18 [PATCH v1 0/6] power: Use named initializers for platform_device_id arrays Uwe Kleine-König (The Capable Hub)
2026-05-29 10:18 ` [PATCH v1 4/6] " Uwe Kleine-König (The Capable Hub)
2026-05-29 11:02   ` sashiko-bot [this message]
2026-06-26 13:58     ` Uwe Kleine-König
2026-05-29 11:29   ` Joshua Peisach
2026-05-29 18:49     ` Uwe Kleine-König (The Capable Hub)
2026-06-01  6:48   ` Matti Vaittinen
2026-06-03 20:46 ` (subset) [PATCH v1 0/6] " Sebastian Reichel
2026-06-26  8:20 ` patchwork-bot+linux-riscv

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=20260529110229.9474D1F00893@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=Frank.Li@kernel.org \
    --cc=imx@lists.linux.dev \
    --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