Re: [Intel-gfx] [RFC 1/8] drm/i915: Expose list of clients in sysfs

2020-01-10 Thread Chris Wilson
Quoting Tvrtko Ursulin (2020-01-10 13:30:42) > +static ssize_t > +show_client_name(struct device *kdev, struct device_attribute *attr, char > *buf) > +{ > + struct i915_drm_client *client = > + container_of(attr, typeof(*client), attr.name); > + > + return snprintf(buf, P

[Intel-gfx] [RFC 1/8] drm/i915: Expose list of clients in sysfs

2020-01-10 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Expose a list of clients with open file handles in sysfs. This will be a basis for a top-like utility showing per-client and per- engine GPU load. Currently we only expose each client's pid and name under opaque numbered directories in /sys/class/drm/card0/clients/. For in