mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Miguel Garcia <miguelgarciaroman8@gmail.com>
Cc: rafael@kernel.org, u.kleine-koenig@baylibre.com,
	kmehltretter@gmail.com, corbet@lwn.net,
	linux-acpi@vger.kernel.org, linux-doc@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ACPI: device-id: document struct acpi_device_id
Date: Mon, 14 Sep 2026 16:11:43 +0300	[thread overview]
Message-ID: <aqfyj9saFPR2K8j2@ashevche-desk.local> (raw)
In-Reply-To: <20260913095111.2543502-1-miguelgarciaroman8@gmail.com>

On Sun, Sep 13, 2026 at 11:51:05AM +0200, Miguel Garcia wrote:
> struct acpi_device_id lacks kernel-doc, so extracting documentation from
> its header describes ACPI_DEVICE_CLASS but not the matching table entry.

ACPI_DEVICE_CLASS()

> Document the four members, ID and class-code matching, and the table
> terminator. This complements the pending documentation header-split
> update without changing its include directives.

> An LLM drafted this comment and changelog after being asked to address
> the missing documentation noted in the header-split discussion. The
> field descriptions were checked against the ACPI matching code. The
> extracted documentation passes kernel-doc and a focused Sphinx HTML
> build with warnings treated as errors; checkpatch reports no warnings.

This paragraph is more for the comment, no need to include as is into
the commit message.

...

> +/**
> + * struct acpi_device_id - ACPI device matching table entry
> + * @id: NUL-terminated hardware ID (_HID) or compatible ID (_CID) to match.
> + * @driver_data: Data private to the driver.

> + * @cls: PCI-defined class, subclass and programming interface code (_CLS).
> + * @cls_msk: Mask selecting the class-code fields to match.

Hmm... The only driver which uses this is AHCI. Yeah, that's fine, of course,
but might be that in the future we can replace that with a traditional list of
_HID:s, who knows...

> + * Use @id for ID matching or ACPI_DEVICE_CLASS() for class-code matching.
> + * Terminate the table with an entry whose @id is empty and @cls is zero.
> + */

-- 
With Best Regards,
Andy Shevchenko



      reply	other threads:[~2026-09-14 13:11 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-13  9:51 Miguel Garcia
2026-09-14 13:11 ` Andy Shevchenko [this message]

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=aqfyj9saFPR2K8j2@ashevche-desk.local \
    --to=andriy.shevchenko@linux.intel.com \
    --cc=corbet@lwn.net \
    --cc=kmehltretter@gmail.com \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=miguelgarciaroman8@gmail.com \
    --cc=rafael@kernel.org \
    --cc=u.kleine-koenig@baylibre.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

all inboxes | Powered by JetHome®