Re: [RFC][PATCH] Add sysfs entry that displays MSI-X IRQs

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

 



On Fri, Oct 31, 2008 at 02:48:21PM +1100, Vincent Rizza wrote:
> Michael raised the issue of dev->stop() calling pci_disable_msi()
> on ifconfig down. The rtnl_lock eliminates that problem.
>
>
>
> Signed-off-by: Vincent Rizza <vinnie@xxxxxxx>
> Signed-off-by: Brett Grandbois <brettg@xxxxxxx>
> Signed-off-by: Greg Banks <gnb@xxxxxxx>
> ---
> Documentation/ABI/testing/sysfs-bus-pci |    9 +++++++++
> drivers/pci/pci-sysfs.c                 |   26 ++++++++++++++++++++++++++
> 2 files changed, 35 insertions(+), 0 deletions(-)
>
> diff --git a/Documentation/ABI/testing/sysfs-bus-pci 
> b/Documentation/ABI/testing/sysfs-bus-pci
> index ceddcff..15d48ed 100644
> --- a/Documentation/ABI/testing/sysfs-bus-pci
> +++ b/Documentation/ABI/testing/sysfs-bus-pci
> @@ -9,3 +9,12 @@ Description:
> 		that some devices may have malformatted data.  If the
> 		underlying VPD has a writable section then the
> 		corresponding section of this file will be writable.
> +
> +What:		/sys/bus/pci/devices/.../msix
> +Date:		October 2008
> +Contact:	Vincent Rizza <vinnie@xxxxxxx>
> +Description:
> +		The "msix" file (read only) in the device directory
> +		provides a list of MSI-X IRQs for the given device.
> +		Each line contains a MSI-X IRQ (represented in decimal).
> +		The file is empty if there are no MSI-X IRQs.

The file should just not be present if there are no MSI-X irqs, right?
That's the way lots of other sysfs files work.

Also, this will be returning more than one value per single sysfs file,
which generally is not allowed.  What is to keep you from overrunning
the buffer passed to the show function?

Is there any way you can think of only having one value per file here?

And, what tools will be using this sysfs file?  Please include them in
this documentation if you know of any (hint, I think you do...)

thanks,

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[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