Lines Matching refs:dp
79 drm_supp_register(dev_info_t *dip, drm_device_t *dp)
122 mstate->mis_devp = dp;
168 drm_device_t *dp;
209 dp = mstate->mis_devp;
211 if (!dp)
250 mutex_enter(&dp->dev_lock);
253 TAILQ_FOREACH(mp, &dp->minordevs, link) {
261 mutex_exit(&dp->dev_lock);
265 TAILQ_INSERT_TAIL(&dp->minordevs, newp, link);
267 mutex_exit(&dp->dev_lock);
268 err = drm_open(dp, newp, flag, otyp, credp);
270 mutex_enter(&dp->dev_lock);
271 TAILQ_REMOVE(&dp->minordevs, newp, link);
273 mutex_exit(&dp->dev_lock);
288 drm_device_t *dp;
301 dp = mstate->mis_devp;
302 if (dp == NULL) {
307 ret = drm_close(dp, minor, flag, otyp, credp);
321 drm_device_t *dp;
363 dp = mstate->mis_devp;
364 ASSERT(dp != NULL);
368 atomic_inc_32(&dp->counts[_DRM_STAT_IOCTLS]);
374 if (nr > dp->driver->max_driver_ioctl) {
376 nr, dp->driver->max_driver_ioctl);
379 ioctl = &dp->driver->driver_ioctls[nr];
387 mutex_enter(&dp->dev_lock);
388 fpriv = drm_find_file_by_proc(dp, credp);
389 mutex_exit(&dp->dev_lock);
400 retval = func(dp, arg, fpriv, mode);
414 drm_device_t *dp;
470 dp = mstate->mis_devp;
471 if (dp == NULL) {
482 mutex_enter(&dp->dev_lock);
483 TAILQ_FOREACH(map, &dp->maplist, link) {
495 TAILQ_FOREACH(map, &dp->maplist, link) {
504 mutex_exit(&dp->dev_lock);
508 TAILQ_FOREACH(map, &dp->maplist, link) {
518 mutex_exit(&dp->dev_lock);
523 mutex_exit(&dp->dev_lock);
533 if (dp->driver->set_devmap_callbacks) {
534 cb = (dp->driver->set_devmap_callbacks)
544 regno = drm_get_pci_index_reg(dp->dip,
557 ret = devmap_devmem_setup(dhp, dp->dip, cb,
577 ret = devmap_umem_setup(dhp, dp->dip, NULL,
590 if (dp->agp == NULL) {
596 aperbase = dp->agp->base;
607 if ((ret = devmap_umem_setup(dhp, dp->dip,
618 koff = map->offset - (unsigned long)(caddr_t)dp->sg->virtual;
624 dp->sg->virtual, map->size, len);
634 ret = devmap_umem_setup(dhp, dp->dip,
915 drm_device_t *dp;
920 dp = mstate->mis_devp;
926 mutex_enter(&dp->dev_lock);
927 TAILQ_FOREACH(mp, &dp->minordevs, link) {
931 mutex_exit(&dp->dev_lock);