mbox series

[v3,0/4] drm/panfrost: Expose perf counters to userspace

Message ID 20190529095233.26277-1-boris.brezillon@collabora.com (mailing list archive)
Headers show
Series drm/panfrost: Expose perf counters to userspace | expand

Message

Boris Brezillon May 29, 2019, 9:52 a.m. UTC
Hello,

This a new version of the panfrost perfcnt series, this time exposing
this functionality through 2 ioctls instead of the debugfs approach
used in v2.

I also went for Emil's suggestion to expose those ioctls only when
the unstable_iocts unsafe param is set to true. This way, I hope we'll
be able to deprecate those ioctls when the generic solution to expose
global perf counters is out.

Also addressed the problems reported by Rob and Steven.

Regards,

Boris

Changes in v3:
* Expose things through ioctls instead of debugfs (needed for
  per-FD address space that is being worked on by Rob)

Changes in v2:
* Complete rewrite to expose things through debugfs

Boris Brezillon (4):
  drm/panfrost: Move gpu_{write,read}() macros to panfrost_regs.h
  drm/panfrost: Add a module parameter to expose unstable ioctls
  drm/panfrost: Add an helper to check the GPU generation
  drm/panfrost: Expose performance counters through unstable ioctls

 drivers/gpu/drm/panfrost/Makefile           |   3 +-
 drivers/gpu/drm/panfrost/panfrost_device.c  |   8 +
 drivers/gpu/drm/panfrost/panfrost_device.h  |  10 +
 drivers/gpu/drm/panfrost/panfrost_drv.c     |  15 +
 drivers/gpu/drm/panfrost/panfrost_gpu.c     |  10 +-
 drivers/gpu/drm/panfrost/panfrost_perfcnt.c | 329 ++++++++++++++++++++
 drivers/gpu/drm/panfrost/panfrost_perfcnt.h |  18 ++
 drivers/gpu/drm/panfrost/panfrost_regs.h    |  22 ++
 include/uapi/drm/panfrost_drm.h             |  24 ++
 9 files changed, 435 insertions(+), 4 deletions(-)
 create mode 100644 drivers/gpu/drm/panfrost/panfrost_perfcnt.c
 create mode 100644 drivers/gpu/drm/panfrost/panfrost_perfcnt.h

Comments

Alyssa Rosenzweig May 29, 2019, 3:16 p.m. UTC | #1
Woohoo! Patches 1-3 are R-b; patch 4 is A-b. Exciting progress! Hoping
to hear what Rob and Steven think :)
Rob Herring June 14, 2019, 3:12 p.m. UTC | #2
On Wed, May 29, 2019 at 9:16 AM Alyssa Rosenzweig <alyssa@rosenzweig.io> wrote:
>
> Woohoo! Patches 1-3 are R-b; patch 4 is A-b. Exciting progress! Hoping
> to hear what Rob and Steven think :)

All looks fine to me, but there's a kbuild error on patch 4 that needs
to be fixed.

Rob
Boris Brezillon June 14, 2019, 4:23 p.m. UTC | #3
On Fri, 14 Jun 2019 09:12:39 -0600
Rob Herring <robh+dt@kernel.org> wrote:

> On Wed, May 29, 2019 at 9:16 AM Alyssa Rosenzweig <alyssa@rosenzweig.io> wrote:
> >
> > Woohoo! Patches 1-3 are R-b; patch 4 is A-b. Exciting progress! Hoping
> > to hear what Rob and Steven think :)  
> 
> All looks fine to me, but there's a kbuild error on patch 4 that needs
> to be fixed.

Yes, missing uintptr_t cast. I'll send a new version with that fixed.

Thanks,

Boris