diff options
author | Tvrtko Ursulin <tvrtko.ursulin@intel.com> | 2023-06-05 13:32:24 +0100 |
---|---|---|
committer | Tvrtko Ursulin <tvrtko.ursulin@intel.com> | 2023-06-06 10:01:06 +0100 |
commit | e894b724c316d9b45d963f929c97578cdffbbe8d (patch) | |
tree | a905301635a2e935680bfd7e985274b6fb6449e0 /drivers/gpu/drm/i915/i915_drm_client.h | |
parent | 744bbf2a67e7798118c39cd6652a0e1e4ad86498 (diff) | |
download | linux-e894b724c316d9b45d963f929c97578cdffbbe8d.tar.gz linux-e894b724c316d9b45d963f929c97578cdffbbe8d.tar.bz2 linux-e894b724c316d9b45d963f929c97578cdffbbe8d.zip |
drm/i915: Use the fdinfo helper
Use the common fdinfo helper for printing the basics. Remove now unused
client id allocation code.
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Cc: Rob Clark <robdclark@chromium.org>
Reviewed-by: Andi Shyti <andi.shyti@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20230605123224.373633-1-tvrtko.ursulin@linux.intel.com
Diffstat (limited to 'drivers/gpu/drm/i915/i915_drm_client.h')
-rw-r--r-- | drivers/gpu/drm/i915/i915_drm_client.h | 22 |
1 files changed, 4 insertions, 18 deletions
diff --git a/drivers/gpu/drm/i915/i915_drm_client.h b/drivers/gpu/drm/i915/i915_drm_client.h index 69496af996d9..4c18b99e10a4 100644 --- a/drivers/gpu/drm/i915/i915_drm_client.h +++ b/drivers/gpu/drm/i915/i915_drm_client.h @@ -9,20 +9,13 @@ #include <linux/kref.h> #include <linux/list.h> #include <linux/spinlock.h> -#include <linux/xarray.h> #include <uapi/drm/i915_drm.h> #define I915_LAST_UABI_ENGINE_CLASS I915_ENGINE_CLASS_COMPUTE -struct drm_i915_private; - -struct i915_drm_clients { - struct drm_i915_private *i915; - - struct xarray xarray; - u32 next_id; -}; +struct drm_file; +struct drm_printer; struct i915_drm_client { struct kref kref; @@ -32,17 +25,12 @@ struct i915_drm_client { spinlock_t ctx_lock; /* For add/remove from ctx_list. */ struct list_head ctx_list; /* List of contexts belonging to client. */ - struct i915_drm_clients *clients; - /** * @past_runtime: Accumulation of pphwsp runtimes from closed contexts. */ atomic64_t past_runtime[I915_LAST_UABI_ENGINE_CLASS + 1]; }; -void i915_drm_clients_init(struct i915_drm_clients *clients, - struct drm_i915_private *i915); - static inline struct i915_drm_client * i915_drm_client_get(struct i915_drm_client *client) { @@ -57,12 +45,10 @@ static inline void i915_drm_client_put(struct i915_drm_client *client) kref_put(&client->kref, __i915_drm_client_free); } -struct i915_drm_client *i915_drm_client_add(struct i915_drm_clients *clients); +struct i915_drm_client *i915_drm_client_alloc(void); #ifdef CONFIG_PROC_FS -void i915_drm_client_fdinfo(struct seq_file *m, struct file *f); +void i915_drm_client_fdinfo(struct drm_printer *p, struct drm_file *file); #endif -void i915_drm_clients_fini(struct i915_drm_clients *clients); - #endif /* !__I915_DRM_CLIENT_H__ */ |