Linux PCI subsystem development
 help / color / mirror / Atom feed
From: Bjorn Helgaas <helgaas@kernel.org>
To: Alistair Francis <alistair@alistair23.me>
Cc: bhelgaas@google.com, linux-pci@vger.kernel.org,
	Jonathan.Cameron@huawei.com, lukas@wunner.de,
	alex.williamson@redhat.com, christian.koenig@amd.com,
	kch@nvidia.com, gregkh@linuxfoundation.org, logang@deltatee.com,
	linux-kernel@vger.kernel.org, alistair23@gmail.com,
	chaitanyak@nvidia.com, rdunlap@infradead.org
Subject: Re: [PATCH v17 3/4] PCI/DOE: Expose the DOE features via sysfs
Date: Fri, 21 Mar 2025 16:41:58 -0500	[thread overview]
Message-ID: <20250321214158.GA1162292@bhelgaas> (raw)
In-Reply-To: <20250306075211.1855177-3-alistair@alistair23.me>

On Thu, Mar 06, 2025 at 05:52:10PM +1000, Alistair Francis wrote:
> The PCIe 6 specification added support for the Data Object
> Exchange (DOE).
> When DOE is supported the DOE Discovery Feature must be implemented per
> PCIe r6.1 sec 6.30.1.1. DOE allows a requester to obtain
> information about the other DOE features supported by the device.

> +#ifdef CONFIG_SYSFS
> +static ssize_t doe_discovery_show(struct device *dev,
> +				  struct device_attribute *attr,
> +				  char *buf)
> +{
> +	return sysfs_emit(buf, "0001:00\n");
> +}
> +DEVICE_ATTR_RO(doe_discovery);

I think this needs:

  static DEVICE_ATTR_RO(doe_discovery);

Otherwise sparse complains:

  $ make C=2 drivers/pci/doe.o
    CHECK   scripts/mod/empty.c
    CALL    scripts/checksyscalls.sh
    DESCEND objtool
    INSTALL libsubcmd_headers
    CHECK   drivers/pci/doe.c
  drivers/pci/doe.c:109:1: warning: symbol 'dev_attr_doe_discovery' was not declared. Should it be static?


Right?  I added this in, so we're all set unless you think that's
wrong.

Bjorn

  parent reply	other threads:[~2025-03-21 21:42 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-06  7:52 [PATCH v17 1/4] PCI/DOE: Rename DOE protocol to feature Alistair Francis
2025-03-06  7:52 ` [PATCH v17 2/4] PCI/DOE: Rename Discovery Response Data Object Contents to type Alistair Francis
2025-03-06  7:52 ` [PATCH v17 3/4] PCI/DOE: Expose the DOE features via sysfs Alistair Francis
2025-03-07 12:05   ` kernel test robot
2025-03-07 14:10   ` kernel test robot
2025-03-07 15:18   ` kernel test robot
2025-03-07 16:01   ` kernel test robot
2025-03-21 21:41   ` Bjorn Helgaas [this message]
2025-03-24  3:02     ` Alistair Francis
2025-03-06  7:52 ` [PATCH v17 4/4] PCI/DOE: Allow enabling DOE without CXL Alistair Francis
2025-03-06 18:55 ` [PATCH v17 1/4] PCI/DOE: Rename DOE protocol to feature Bjorn Helgaas

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=20250321214158.GA1162292@bhelgaas \
    --to=helgaas@kernel.org \
    --cc=Jonathan.Cameron@huawei.com \
    --cc=alex.williamson@redhat.com \
    --cc=alistair23@gmail.com \
    --cc=alistair@alistair23.me \
    --cc=bhelgaas@google.com \
    --cc=chaitanyak@nvidia.com \
    --cc=christian.koenig@amd.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=kch@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=logang@deltatee.com \
    --cc=lukas@wunner.de \
    --cc=rdunlap@infradead.org \
    /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