Thread (11 messages) 11 messages, 3 authors, 2020-02-13

Re: [PATCH v7 2/2] fpga: dfl: fme: add performance reporting support

From: Wu Hao <hidden>
Date: 2020-02-13 03:12:46
Also in: linux-fpga, lkml

On Wed, Feb 12, 2020 at 05:20:45AM -0800, Greg KH wrote:
On Wed, Feb 12, 2020 at 06:02:11PM +0800, Wu Hao wrote:
quoted
On Tue, Feb 11, 2020 at 09:30:35PM -0800, Greg KH wrote:
quoted
On Wed, Feb 12, 2020 at 11:19:29AM +0800, Wu Hao wrote:
quoted
On Mon, Feb 10, 2020 at 04:34:01PM +0000, Will Deacon wrote:
quoted
Hi,

On Mon, Feb 10, 2020 at 11:47:49AM +0800, Wu Hao wrote:
quoted
This patch adds support for performance reporting private feature
for FPGA Management Engine (FME). Now it supports several different
performance counters, including 'basic', 'cache', 'fabric', 'vtd'
and 'vtd_sip'. It allows user to use standard linux tools to access
these performance counters.
I had a quick look at this, and it mostly looks alright to me. Just a few
high-level comments/questions:
Hi Will

Thanks a lot for the review! :)
quoted
  - I would still prefer for the PMU drivers to live under drivers/perf/
Hm.. one possible way is to create a platform device, and introduce a new
platform device driver under drivers/perf/.
No, do not abuse platform drivers, you have a real device, use it.
Sure, thanks for the comments. Then I don't have any other idea to move code to
drivers/perf/ directory, so probably only can live with current code.
The location of the file in the kernel tree has no bearing on if you use
a platform device, a USB device, or a PCI device.  It is just a location
of a file.

You are interacting with the perf api as the driver's primary userspace
api, so put the driver into the drivers/perf/ directory.  That's all
that Will is asking you to do here.
Thanks a lot for the patient explanation. : )

Actually this patch only adds a new file to existing fme platform driver, fme
platform driver already has several different types userspace interfaces,
including hwmon, sysfs and etc, so the new perf api is only one of them, as
we can't move the whole fme platform driver into drivers/perf/, we feel that
maybe we should keep that code together with other fme files in drivers/fpga/.

Thanks
Hao
greg k-h
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help