Lines Matching refs:lessor
69 #define drm_for_each_lessee(lessee, lessor) \ argument
70 list_for_each_entry((lessee), &(lessor)->lessees, lessee_list)
76 while (master->lessor != NULL) in drm_lease_owner()
77 master = master->lessor; in drm_lease_owner()
91 if (master->lessor) in _drm_lease_held_master()
137 if (!master->lessor) { in drm_lease_held()
168 if (!master->lessor) { in drm_lease_filter_crtcs()
207 static struct drm_master *drm_lease_create(struct drm_master *lessor, struct idr *leases) in drm_lease_create() argument
209 struct drm_device *dev = lessor->dev; in drm_lease_create()
216 DRM_DEBUG_LEASE("lessor %d\n", lessor->lessee_id); in drm_lease_create()
218 lessee = drm_master_create(lessor->dev); in drm_lease_create()
230 else if (_drm_has_leased(lessor, object)) in drm_lease_create()
240 id = idr_alloc(&(drm_lease_owner(lessor)->lessee_idr), lessee, 1, 0, GFP_KERNEL); in drm_lease_create()
247 lessee->lessor = drm_master_get(lessor); in drm_lease_create()
248 list_add_tail(&lessee->lessee_list, &lessor->lessees); in drm_lease_create()
252 …UG_LEASE("new lessee %d %p, lessor %d %p\n", lessee->lessee_id, lessee, lessor->lessee_id, lessor); in drm_lease_create()
289 if (master->lessor) { in drm_lease_destroy()
292 drm_master_put(&master->lessor); in drm_lease_destroy()
324 …while (master != top && master == list_last_entry(&master->lessor->lessees, struct drm_master, les… in _drm_lease_revoke()
325 master = master->lessor; in _drm_lease_revoke()
480 struct drm_master *lessor; in drm_mode_create_lease_ioctl() local
497 lessor = drm_file_get_master(lessor_priv); in drm_mode_create_lease_ioctl()
499 if (lessor->lessor) { in drm_mode_create_lease_ioctl()
539 lessee = drm_lease_create(lessor, &leases); in drm_mode_create_lease_ioctl()
570 drm_master_put(&lessor); in drm_mode_create_lease_ioctl()
581 drm_master_put(&lessor); in drm_mode_create_lease_ioctl()
592 struct drm_master *lessor, *lessee; in drm_mode_list_lessees_ioctl() local
603 lessor = drm_file_get_master(lessor_priv); in drm_mode_list_lessees_ioctl()
604 DRM_DEBUG_LEASE("List lessees for %d\n", lessor->lessee_id); in drm_mode_list_lessees_ioctl()
609 drm_for_each_lessee(lessee, lessor) { in drm_mode_list_lessees_ioctl()
627 drm_master_put(&lessor); in drm_mode_list_lessees_ioctl()
658 if (lessee->lessor == NULL) in drm_mode_get_lease_ioctl()
695 struct drm_master *lessor; in drm_mode_revoke_lease_ioctl() local
705 lessor = drm_file_get_master(lessor_priv); in drm_mode_revoke_lease_ioctl()
708 lessee = _drm_find_lessee(lessor, arg->lessee_id); in drm_mode_revoke_lease_ioctl()
717 if (lessee->lessor != lessor) { in drm_mode_revoke_lease_ioctl()
726 drm_master_put(&lessor); in drm_mode_revoke_lease_ioctl()