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 10:01:48AM -0600, Matthew Wilcox wrote:
> On Thu, Oct 30, 2008 at 11:25:02PM -0700, Greg KH wrote:
> > 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?
> 
> Nothing -- there can be up to 2048 MSI-X entries and each interrupt
> number might reasonably be five bytes ("1234\n"), so we're looking at
> a maximum output of around 10k.

Ok, then I'm going to have to say that this file is not allowed as it
will cause oopses :(

> > Is there any way you can think of only having one value per file here?
> 
> Urgh.  I suppose we could create one sysfs file per MSI vector, but see
> the "2048" above.  It would be nice from a sparse usage point of view, in
> that you'd get a file called msix947 that had the contents "190", but this
> could cause a _lot_ of files to get created.  Are we all OK with this?

Lots of sysfs files are not a problem, I think that would be a much
better solution here.

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