blob: 1b5d0da6566d73a28941904a0d59954feb53c08c [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001/**
Dave Airlieb5e89ed2005-09-25 14:28:13 +10002 * \file drm_ioctl.c
Linus Torvalds1da177e2005-04-16 15:20:36 -07003 * IOCTL processing for DRM
4 *
5 * \author Rickard E. (Rik) Faith <faith@valinux.com>
6 * \author Gareth Hughes <gareth@valinux.com>
7 */
8
9/*
10 * Created: Fri Jan 8 09:01:26 1999 by faith@valinux.com
11 *
12 * Copyright 1999 Precision Insight, Inc., Cedar Park, Texas.
13 * Copyright 2000 VA Linux Systems, Inc., Sunnyvale, California.
14 * All Rights Reserved.
15 *
16 * Permission is hereby granted, free of charge, to any person obtaining a
17 * copy of this software and associated documentation files (the "Software"),
18 * to deal in the Software without restriction, including without limitation
19 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
20 * and/or sell copies of the Software, and to permit persons to whom the
21 * Software is furnished to do so, subject to the following conditions:
22 *
23 * The above copyright notice and this permission notice (including the next
24 * paragraph) shall be included in all copies or substantial portions of the
25 * Software.
26 *
27 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
28 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
29 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
30 * VA LINUX SYSTEMS AND/OR ITS SUPPLIERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
31 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
32 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
33 * OTHER DEALINGS IN THE SOFTWARE.
34 */
35
36#include "drmP.h"
37#include "drm_core.h"
38
39#include "linux/pci.h"
40
41/**
42 * Get the bus id.
Dave Airlieb5e89ed2005-09-25 14:28:13 +100043 *
Linus Torvalds1da177e2005-04-16 15:20:36 -070044 * \param inode device inode.
Eric Anholt6c340ea2007-08-25 20:23:09 +100045 * \param file_priv DRM file private.
Linus Torvalds1da177e2005-04-16 15:20:36 -070046 * \param cmd command.
47 * \param arg user argument, pointing to a drm_unique structure.
48 * \return zero on success or a negative number on failure.
49 *
50 * Copies the bus id from drm_device::unique into user space.
51 */
Eric Anholt6c340ea2007-08-25 20:23:09 +100052int drm_getunique(struct inode *inode, struct drm_file *file_priv,
Dave Airlieb5e89ed2005-09-25 14:28:13 +100053 unsigned int cmd, unsigned long arg)
Linus Torvalds1da177e2005-04-16 15:20:36 -070054{
Eric Anholt6c340ea2007-08-25 20:23:09 +100055 struct drm_device *dev = file_priv->head->dev;
Dave Airliec60ce622007-07-11 15:27:12 +100056 struct drm_unique __user *argp = (void __user *)arg;
57 struct drm_unique u;
Linus Torvalds1da177e2005-04-16 15:20:36 -070058
59 if (copy_from_user(&u, argp, sizeof(u)))
60 return -EFAULT;
61 if (u.unique_len >= dev->unique_len) {
62 if (copy_to_user(u.unique, dev->unique, dev->unique_len))
63 return -EFAULT;
64 }
65 u.unique_len = dev->unique_len;
66 if (copy_to_user(argp, &u, sizeof(u)))
67 return -EFAULT;
68 return 0;
69}
70
71/**
72 * Set the bus id.
Dave Airlieb5e89ed2005-09-25 14:28:13 +100073 *
Linus Torvalds1da177e2005-04-16 15:20:36 -070074 * \param inode device inode.
Eric Anholt6c340ea2007-08-25 20:23:09 +100075 * \param file_priv DRM file private.
Linus Torvalds1da177e2005-04-16 15:20:36 -070076 * \param cmd command.
77 * \param arg user argument, pointing to a drm_unique structure.
78 * \return zero on success or a negative number on failure.
79 *
80 * Copies the bus id from userspace into drm_device::unique, and verifies that
81 * it matches the device this DRM is attached to (EINVAL otherwise). Deprecated
82 * in interface version 1.1 and will return EBUSY when setversion has requested
83 * version 1.1 or greater.
84 */
Eric Anholt6c340ea2007-08-25 20:23:09 +100085int drm_setunique(struct inode *inode, struct drm_file *file_priv,
Dave Airlieb5e89ed2005-09-25 14:28:13 +100086 unsigned int cmd, unsigned long arg)
Linus Torvalds1da177e2005-04-16 15:20:36 -070087{
Eric Anholt6c340ea2007-08-25 20:23:09 +100088 struct drm_device *dev = file_priv->head->dev;
Dave Airliec60ce622007-07-11 15:27:12 +100089 struct drm_unique u;
Dave Airlieb5e89ed2005-09-25 14:28:13 +100090 int domain, bus, slot, func, ret;
Linus Torvalds1da177e2005-04-16 15:20:36 -070091
Dave Airlieb5e89ed2005-09-25 14:28:13 +100092 if (dev->unique_len || dev->unique)
93 return -EBUSY;
Linus Torvalds1da177e2005-04-16 15:20:36 -070094
Dave Airliec60ce622007-07-11 15:27:12 +100095 if (copy_from_user(&u, (struct drm_unique __user *) arg, sizeof(u)))
Linus Torvalds1da177e2005-04-16 15:20:36 -070096 return -EFAULT;
97
Dave Airlieb5e89ed2005-09-25 14:28:13 +100098 if (!u.unique_len || u.unique_len > 1024)
99 return -EINVAL;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700100
101 dev->unique_len = u.unique_len;
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000102 dev->unique = drm_alloc(u.unique_len + 1, DRM_MEM_DRIVER);
103 if (!dev->unique)
104 return -ENOMEM;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700105 if (copy_from_user(dev->unique, u.unique, dev->unique_len))
106 return -EFAULT;
107
108 dev->unique[dev->unique_len] = '\0';
109
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000110 dev->devname =
111 drm_alloc(strlen(dev->driver->pci_driver.name) +
112 strlen(dev->unique) + 2, DRM_MEM_DRIVER);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700113 if (!dev->devname)
114 return -ENOMEM;
115
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000116 sprintf(dev->devname, "%s@%s", dev->driver->pci_driver.name,
117 dev->unique);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700118
119 /* Return error if the busid submitted doesn't match the device's actual
120 * busid.
121 */
122 ret = sscanf(dev->unique, "PCI:%d:%d:%d", &bus, &slot, &func);
123 if (ret != 3)
Eric Anholt20caafa2007-08-25 19:22:43 +1000124 return -EINVAL;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700125 domain = bus >> 8;
126 bus &= 0xff;
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000127
Dave Airlie332296012006-08-07 20:23:42 +1000128 if ((domain != drm_get_pci_domain(dev)) ||
Dave242ef0e2006-07-18 04:01:01 +1000129 (bus != dev->pdev->bus->number) ||
130 (slot != PCI_SLOT(dev->pdev->devfn)) ||
131 (func != PCI_FUNC(dev->pdev->devfn)))
Linus Torvalds1da177e2005-04-16 15:20:36 -0700132 return -EINVAL;
133
134 return 0;
135}
136
Dave Airlie84b1fd12007-07-11 15:53:27 +1000137static int drm_set_busid(struct drm_device * dev)
Linus Torvalds1da177e2005-04-16 15:20:36 -0700138{
Dave Airliefe347652006-01-02 21:19:39 +1100139 int len;
140
Linus Torvalds1da177e2005-04-16 15:20:36 -0700141 if (dev->unique != NULL)
Dave Airlie1f27ce62006-08-27 11:11:14 +1000142 return 0;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700143
Dave Airliefe347652006-01-02 21:19:39 +1100144 dev->unique_len = 40;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700145 dev->unique = drm_alloc(dev->unique_len + 1, DRM_MEM_DRIVER);
146 if (dev->unique == NULL)
Dave Airlie1f27ce62006-08-27 11:11:14 +1000147 return -ENOMEM;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700148
Dave Airliefe347652006-01-02 21:19:39 +1100149 len = snprintf(dev->unique, dev->unique_len, "pci:%04x:%02x:%02x.%d",
Dave Airlie332296012006-08-07 20:23:42 +1000150 drm_get_pci_domain(dev), dev->pdev->bus->number,
Dave242ef0e2006-07-18 04:01:01 +1000151 PCI_SLOT(dev->pdev->devfn),
152 PCI_FUNC(dev->pdev->devfn));
Linus Torvalds1da177e2005-04-16 15:20:36 -0700153
Dave Airliefe347652006-01-02 21:19:39 +1100154 if (len > dev->unique_len)
155 DRM_ERROR("Unique buffer overflowed\n");
156
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000157 dev->devname =
158 drm_alloc(strlen(dev->driver->pci_driver.name) + dev->unique_len +
159 2, DRM_MEM_DRIVER);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700160 if (dev->devname == NULL)
Dave Airlie1f27ce62006-08-27 11:11:14 +1000161 return -ENOMEM;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700162
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000163 sprintf(dev->devname, "%s@%s", dev->driver->pci_driver.name,
164 dev->unique);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700165
166 return 0;
167}
168
Linus Torvalds1da177e2005-04-16 15:20:36 -0700169/**
170 * Get a mapping information.
171 *
172 * \param inode device inode.
Eric Anholt6c340ea2007-08-25 20:23:09 +1000173 * \param file_priv DRM file private.
Linus Torvalds1da177e2005-04-16 15:20:36 -0700174 * \param cmd command.
175 * \param arg user argument, pointing to a drm_map structure.
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000176 *
Linus Torvalds1da177e2005-04-16 15:20:36 -0700177 * \return zero on success or a negative number on failure.
178 *
179 * Searches for the mapping with the specified offset and copies its information
180 * into userspace
181 */
Eric Anholt6c340ea2007-08-25 20:23:09 +1000182int drm_getmap(struct inode *inode, struct drm_file *file_priv,
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000183 unsigned int cmd, unsigned long arg)
Linus Torvalds1da177e2005-04-16 15:20:36 -0700184{
Eric Anholt6c340ea2007-08-25 20:23:09 +1000185 struct drm_device *dev = file_priv->head->dev;
Dave Airliec60ce622007-07-11 15:27:12 +1000186 struct drm_map __user *argp = (void __user *)arg;
187 struct drm_map map;
Dave Airlie55910512007-07-11 16:53:40 +1000188 struct drm_map_list *r_list = NULL;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700189 struct list_head *list;
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000190 int idx;
191 int i;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700192
193 if (copy_from_user(&map, argp, sizeof(map)))
194 return -EFAULT;
195 idx = map.offset;
196
Dave Airlie30e2fb12006-02-02 19:37:46 +1100197 mutex_lock(&dev->struct_mutex);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700198 if (idx < 0) {
Dave Airlie30e2fb12006-02-02 19:37:46 +1100199 mutex_unlock(&dev->struct_mutex);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700200 return -EINVAL;
201 }
202
203 i = 0;
Dave Airliebd1b3312007-05-26 05:01:51 +1000204 list_for_each(list, &dev->maplist) {
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000205 if (i == idx) {
Dave Airlie55910512007-07-11 16:53:40 +1000206 r_list = list_entry(list, struct drm_map_list, head);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700207 break;
208 }
209 i++;
210 }
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000211 if (!r_list || !r_list->map) {
Dave Airlie30e2fb12006-02-02 19:37:46 +1100212 mutex_unlock(&dev->struct_mutex);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700213 return -EINVAL;
214 }
215
216 map.offset = r_list->map->offset;
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000217 map.size = r_list->map->size;
218 map.type = r_list->map->type;
219 map.flags = r_list->map->flags;
220 map.handle = (void *)(unsigned long)r_list->user_token;
221 map.mtrr = r_list->map->mtrr;
Dave Airlie30e2fb12006-02-02 19:37:46 +1100222 mutex_unlock(&dev->struct_mutex);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700223
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000224 if (copy_to_user(argp, &map, sizeof(map)))
225 return -EFAULT;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700226 return 0;
227}
228
229/**
230 * Get client information.
231 *
232 * \param inode device inode.
Eric Anholt6c340ea2007-08-25 20:23:09 +1000233 * \param file_priv DRM file private.
Linus Torvalds1da177e2005-04-16 15:20:36 -0700234 * \param cmd command.
235 * \param arg user argument, pointing to a drm_client structure.
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000236 *
Linus Torvalds1da177e2005-04-16 15:20:36 -0700237 * \return zero on success or a negative number on failure.
238 *
239 * Searches for the client with the specified index and copies its information
240 * into userspace
241 */
Eric Anholt6c340ea2007-08-25 20:23:09 +1000242int drm_getclient(struct inode *inode, struct drm_file *file_priv,
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000243 unsigned int cmd, unsigned long arg)
Linus Torvalds1da177e2005-04-16 15:20:36 -0700244{
Eric Anholt6c340ea2007-08-25 20:23:09 +1000245 struct drm_device *dev = file_priv->head->dev;
Dave Airliec60ce622007-07-11 15:27:12 +1000246 struct drm_client __user *argp = (struct drm_client __user *)arg;
247 struct drm_client client;
Dave Airlie84b1fd12007-07-11 15:53:27 +1000248 struct drm_file *pt;
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000249 int idx;
250 int i;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700251
252 if (copy_from_user(&client, argp, sizeof(client)))
253 return -EFAULT;
254 idx = client.idx;
Dave Airlie30e2fb12006-02-02 19:37:46 +1100255 mutex_lock(&dev->struct_mutex);
Dave Airliebd1b3312007-05-26 05:01:51 +1000256
257 if (list_empty(&dev->filelist)) {
Dave Airlie30e2fb12006-02-02 19:37:46 +1100258 mutex_unlock(&dev->struct_mutex);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700259 return -EINVAL;
260 }
Dave Airliebd1b3312007-05-26 05:01:51 +1000261
262 i = 0;
263 list_for_each_entry(pt, &dev->filelist, lhead) {
264 if (i++ >= idx)
265 break;
266 }
267
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000268 client.auth = pt->authenticated;
269 client.pid = pt->pid;
270 client.uid = pt->uid;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700271 client.magic = pt->magic;
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000272 client.iocs = pt->ioctl_count;
Dave Airlie30e2fb12006-02-02 19:37:46 +1100273 mutex_unlock(&dev->struct_mutex);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700274
Dave Airliefe347652006-01-02 21:19:39 +1100275 if (copy_to_user(argp, &client, sizeof(client)))
Linus Torvalds1da177e2005-04-16 15:20:36 -0700276 return -EFAULT;
277 return 0;
278}
279
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000280/**
281 * Get statistics information.
282 *
Linus Torvalds1da177e2005-04-16 15:20:36 -0700283 * \param inode device inode.
Eric Anholt6c340ea2007-08-25 20:23:09 +1000284 * \param file_priv DRM file private.
Linus Torvalds1da177e2005-04-16 15:20:36 -0700285 * \param cmd command.
286 * \param arg user argument, pointing to a drm_stats structure.
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000287 *
Linus Torvalds1da177e2005-04-16 15:20:36 -0700288 * \return zero on success or a negative number on failure.
289 */
Eric Anholt6c340ea2007-08-25 20:23:09 +1000290int drm_getstats(struct inode *inode, struct drm_file *file_priv,
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000291 unsigned int cmd, unsigned long arg)
Linus Torvalds1da177e2005-04-16 15:20:36 -0700292{
Eric Anholt6c340ea2007-08-25 20:23:09 +1000293 struct drm_device *dev = file_priv->head->dev;
Dave Airliec60ce622007-07-11 15:27:12 +1000294 struct drm_stats stats;
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000295 int i;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700296
297 memset(&stats, 0, sizeof(stats));
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000298
Dave Airlie30e2fb12006-02-02 19:37:46 +1100299 mutex_lock(&dev->struct_mutex);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700300
301 for (i = 0; i < dev->counters; i++) {
302 if (dev->types[i] == _DRM_STAT_LOCK)
303 stats.data[i].value
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000304 = (dev->lock.hw_lock ? dev->lock.hw_lock->lock : 0);
305 else
Linus Torvalds1da177e2005-04-16 15:20:36 -0700306 stats.data[i].value = atomic_read(&dev->counts[i]);
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000307 stats.data[i].type = dev->types[i];
Linus Torvalds1da177e2005-04-16 15:20:36 -0700308 }
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000309
Linus Torvalds1da177e2005-04-16 15:20:36 -0700310 stats.count = dev->counters;
311
Dave Airlie30e2fb12006-02-02 19:37:46 +1100312 mutex_unlock(&dev->struct_mutex);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700313
Dave Airliec60ce622007-07-11 15:27:12 +1000314 if (copy_to_user((struct drm_stats __user *) arg, &stats, sizeof(stats)))
Linus Torvalds1da177e2005-04-16 15:20:36 -0700315 return -EFAULT;
316 return 0;
317}
318
319/**
320 * Setversion ioctl.
321 *
322 * \param inode device inode.
Eric Anholt6c340ea2007-08-25 20:23:09 +1000323 * \param file_priv DRM file private.
Linus Torvalds1da177e2005-04-16 15:20:36 -0700324 * \param cmd command.
325 * \param arg user argument, pointing to a drm_lock structure.
326 * \return zero on success or negative number on failure.
327 *
328 * Sets the requested interface version
329 */
330int drm_setversion(DRM_IOCTL_ARGS)
331{
332 DRM_DEVICE;
Dave Airliec60ce622007-07-11 15:27:12 +1000333 struct drm_set_version sv;
334 struct drm_set_version retv;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700335 int if_version;
Dave Airliec60ce622007-07-11 15:27:12 +1000336 struct drm_set_version __user *argp = (void __user *)data;
Dave Airlie1f27ce62006-08-27 11:11:14 +1000337 int ret;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700338
Dave Airlie3d774612006-08-07 20:07:43 +1000339 if (copy_from_user(&sv, argp, sizeof(sv)))
340 return -EFAULT;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700341
Linus Torvalds1da177e2005-04-16 15:20:36 -0700342 retv.drm_di_major = DRM_IF_MAJOR;
343 retv.drm_di_minor = DRM_IF_MINOR;
Dave Airlie22eae942005-11-10 22:16:34 +1100344 retv.drm_dd_major = dev->driver->major;
345 retv.drm_dd_minor = dev->driver->minor;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700346
Dave Airlie1f27ce62006-08-27 11:11:14 +1000347 if (copy_to_user(argp, &retv, sizeof(retv)))
Dave Airlie3d774612006-08-07 20:07:43 +1000348 return -EFAULT;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700349
350 if (sv.drm_di_major != -1) {
351 if (sv.drm_di_major != DRM_IF_MAJOR ||
352 sv.drm_di_minor < 0 || sv.drm_di_minor > DRM_IF_MINOR)
Dave Airlie1f27ce62006-08-27 11:11:14 +1000353 return -EINVAL;
Dave Airliefe347652006-01-02 21:19:39 +1100354 if_version = DRM_IF_VERSION(sv.drm_di_major, sv.drm_di_minor);
Dave Airlie3d774612006-08-07 20:07:43 +1000355 dev->if_version = max(if_version, dev->if_version);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700356 if (sv.drm_di_minor >= 1) {
357 /*
358 * Version 1.1 includes tying of DRM to specific device
359 */
Dave Airlie1f27ce62006-08-27 11:11:14 +1000360 ret = drm_set_busid(dev);
361 if (ret)
362 return ret;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700363 }
364 }
365
366 if (sv.drm_dd_major != -1) {
Dave Airlie22eae942005-11-10 22:16:34 +1100367 if (sv.drm_dd_major != dev->driver->major ||
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000368 sv.drm_dd_minor < 0
Dave Airlie22eae942005-11-10 22:16:34 +1100369 || sv.drm_dd_minor > dev->driver->minor)
Dave Airlie1f27ce62006-08-27 11:11:14 +1000370 return -EINVAL;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700371
372 if (dev->driver->set_version)
373 dev->driver->set_version(dev, &sv);
374 }
375 return 0;
376}
377
378/** No-op ioctl. */
Eric Anholt6c340ea2007-08-25 20:23:09 +1000379int drm_noop(struct inode *inode, struct drm_file *file_priv, unsigned int cmd,
Dave Airlieb5e89ed2005-09-25 14:28:13 +1000380 unsigned long arg)
Linus Torvalds1da177e2005-04-16 15:20:36 -0700381{
382 DRM_DEBUG("\n");
383 return 0;
384}