Re: [PATCH v17 3/4] PCI/DOE: Expose the DOE features via sysfs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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




[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux