Dave Airlie writes:
> I think a comment in here is definitely warranted with what you expect
> from the idr interface here.
I've added a longer comment where this value is used; I tried replacing
the IDR with a sorted array and the result wasn't any easier to use or
understand. I'm pretty sure i
On 5 October 2017 at 13:24, Dave Airlie wrote:
> On 5 October 2017 at 13:17, Dave Airlie wrote:
>>> ---
>>> drivers/gpu/drm/drm_ioctl.c | 4 +
>>> drivers/gpu/drm/drm_lease.c | 270
>>>
>>> include/drm/drm_lease.h | 12 ++
>>> include/uapi/drm
On 5 October 2017 at 13:17, Dave Airlie wrote:
>> ---
>> drivers/gpu/drm/drm_ioctl.c | 4 +
>> drivers/gpu/drm/drm_lease.c | 270
>>
>> include/drm/drm_lease.h | 12 ++
>> include/uapi/drm/drm.h | 5 +
>> include/uapi/drm/drm_mode.h | 6
> ---
> drivers/gpu/drm/drm_ioctl.c | 4 +
> drivers/gpu/drm/drm_lease.c | 270
>
> include/drm/drm_lease.h | 12 ++
> include/uapi/drm/drm.h | 5 +
> include/uapi/drm/drm_mode.h | 64 +++
> 5 files changed, 355 insertions(+)
>
>
Dave Airlie writes:
> I think this needs a pad ^.
> And this.
Yup. Thanks!
>> +struct drm_mode_revoke_lease {
>> + /** Unique ID of lessee
>> +*/
>> + __u32 lessee_id;
>
> And this.
None of the other bare 32-bit ioctl structures are padded; I think
that's probably fine as
> +/**
> + * Lease mode resources, creating another drm_master.
> + */
> +struct drm_mode_create_lease {
> + /** Pointer to array of object ids (__u32) */
> + __u64 object_ids;
> + /** Number of object ids */
> + __u32 object_count;
> + /** flags for new FD (O_CLOEXEC,
drm_mode_create_lease
Creates a lease for a list of drm mode objects, returning an
fd for the new drm_master and a 64-bit identifier for the lessee
drm_mode_list_lesees
List the identifiers of the lessees for a master file
drm_mode_get_lease
List the leased obje