Lines Matching refs:priv
52 drm_file_t *priv;
54 TAILQ_FOREACH(priv, &dev->files, link)
55 if (priv->pid == pid)
56 return (priv);
79 drm_file_t *priv;
91 priv = drm_find_file_by_proc(dev, credp);
92 if (priv) {
93 priv->refs++;
95 priv = drm_alloc(sizeof (*priv), DRM_MEM_FILES);
96 if (priv == NULL) {
100 bzero(priv, sizeof (*priv));
102 priv->uid = crgetsuid(credp);
103 priv->pid = pid;
105 priv->refs = 1;
106 priv->minor = 5; /* just for hack */
107 priv->ioctl_count = 0;
110 priv->authenticated = DRM_SUSER(credp);
113 drm_gem_open(priv);
116 retcode = dev->driver->open(dev, priv);
118 drm_free(priv, sizeof (*priv), DRM_MEM_FILES);
125 priv->master = TAILQ_EMPTY(&dev->files);
126 TAILQ_INSERT_TAIL(&dev->files, priv, link);
128 mp->fpriv = priv;