Re: [Intel-gfx] [PATCH 1/9] drm/i915: Add i915 perf infrastructure

2016-04-20 Thread Chris Wilson
On Wed, Apr 20, 2016 at 03:23:06PM +0100, Robert Bragg wrote: > +static struct intel_context * > +lookup_context(struct drm_i915_private *dev_priv, > +struct file *user_filp, > +u32 ctx_user_handle) > +{ > + struct intel_context *ctx; > + > + mutex_lock(&dev_priv->de

[Intel-gfx] [PATCH 1/9] drm/i915: Add i915 perf infrastructure

2016-04-20 Thread Robert Bragg
Adds base i915 perf infrastructure for Gen performance metrics. This adds a DRM_IOCTL_I915_PERF_OPEN ioctl that takes an array of uint64 properties to configure a stream of metrics and returns a new fd usable with standard VFS system calls including read() to read typed and sized records; ioctl()