XenevaOS
Loading...
Searching...
No Matches
drm_auth.h
Go to the documentation of this file.
1#ifndef _DRM_AUTH_H_
2#define _DRM_AUTH_H_
3
4/*
5 * Internal Header for the Direct Rendering Manager
6 *
7 * Copyright 2016 Intel Corporation
8 *
9 * Author: Daniel Vetter <daniel.vetter@ffwll.ch>
10 *
11 * Permission is hereby granted, free of charge, to any person obtaining a
12 * copy of this software and associated documentation files (the "Software"),
13 * to deal in the Software without restriction, including without limitation
14 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
15 * and/or sell copies of the Software, and to permit persons to whom the
16 * Software is furnished to do so, subject to the following conditions:
17 *
18 * The above copyright notice and this permission notice (including the next
19 * paragraph) shall be included in all copies or substantial portions of the
20 * Software.
21 *
22 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
23 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
24 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
25 * VA LINUX SYSTEMS AND/OR ITS SUPPLIERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
26 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
27 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
28 * OTHER DEALINGS IN THE SOFTWARE.
29 */
30
31#include <linux/idr.h>
32#include <linux/kref.h>
33#include <linux/wait.h>
34
35struct drm_file;
36
47struct drm_master {
48 struct kref refcount;
49 struct drm_device *dev;
54 char *unique;
64 struct idr magic_map;
66
82
90
99
111
121 struct idr leases;
122
130};
131
133struct drm_master *drm_file_get_master(struct drm_file *file_priv);
135bool drm_is_current_master(struct drm_file *fpriv);
136
138
139#endif
struct drm_master * drm_master_create(struct drm_device *dev)
bool drm_is_current_master(struct drm_file *fpriv)
void drm_master_put(struct drm_master **master)
struct drm_master * drm_master_get(struct drm_master *master)
struct drm_master * drm_file_get_master(struct drm_file *file_priv)
const struct device * dev
Definition drm_print.h:519
struct i915_engine_class_instance master
Definition i915_drm.h:2
Definition drm_device.h:75
Definition drm_file.h:165
Definition drm_auth.h:47
struct idr magic_map
Definition drm_auth.h:64
struct list_head lessee_list
Definition drm_auth.h:98
int unique_len
Definition drm_auth.h:59
void * driver_priv
Definition drm_auth.h:65
struct list_head lessees
Definition drm_auth.h:110
struct drm_device * dev
Definition drm_auth.h:49
struct idr leases
Definition drm_auth.h:121
struct kref refcount
Definition drm_auth.h:48
struct drm_master * lessor
Definition drm_auth.h:81
int lessee_id
Definition drm_auth.h:89
char * unique
Definition drm_auth.h:54
struct idr lessee_idr
Definition drm_auth.h:129
Definition idr.h:80
Definition kref.h:44
Definition list.h:11