Lines Matching +full:mipi +full:- +full:to +full:- +full:edp

4  * Permission to use, copy, modify, distribute, and sell this software and its
9 * publicity pertaining to distribution of the software without specific,
14 * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
44 * Frame buffers are abstract memory objects that provide a source of pixels to
45 * scanout to a CRTC. Applications explicitly request the creation of frame
47 * handle that can be passed to the KMS CRTC control, plane configuration and
52 * (or a list of memory handles for multi-planar formats) through the
55 * free to use their own backing storage object handles, e.g. vmwgfx directly
56 * exposes special TTM handles to userspace and so expects TTM handles in the
60 * using drm_framebuffer_init() - after calling that function userspace can use
62 * drm_helper_mode_fill_fb_struct() can be used to pre-fill the required
67 * them again with drm_framebuffer_put(). For driver-private framebuffers for
72 * recommended, and it's better to have a normal free-standing &struct
82 fb_width = fb->width << 16; in drm_framebuffer_check_src_coords()
83 fb_height = fb->height << 16; in drm_framebuffer_check_src_coords()
87 src_x > fb_width - src_w || in drm_framebuffer_check_src_coords()
89 src_y > fb_height - src_h) { in drm_framebuffer_check_src_coords()
96 fb->width, fb->height); in drm_framebuffer_check_src_coords()
97 return -ENOSPC; in drm_framebuffer_check_src_coords()
104 * drm_mode_addfb - add an FB to the graphics configuration
106 * @or: pointer to request structure
109 * Add a new FB to the specified CRTC, given a user request. This is the
112 * Called by the user via ioctl, or by an in-kernel client.
124 return -EOPNOTSUPP; in drm_mode_addfb()
126 r.pixel_format = drm_driver_legacy_fb_format(dev, or->bpp, or->depth); in drm_mode_addfb()
128 DRM_DEBUG("bad {bpp:%d, depth:%d}\n", or->bpp, or->depth); in drm_mode_addfb()
129 return -EINVAL; in drm_mode_addfb()
132 /* convert to new format and call new ioctl */ in drm_mode_addfb()
133 r.fb_id = or->fb_id; in drm_mode_addfb()
134 r.width = or->width; in drm_mode_addfb()
135 r.height = or->height; in drm_mode_addfb()
136 r.pitches[0] = or->pitch; in drm_mode_addfb()
137 r.handles[0] = or->handle; in drm_mode_addfb()
143 or->fb_id = r.fb_id; in drm_mode_addfb()
160 return DIV_ROUND_UP(width, format->hsub); in fb_plane_width()
169 return DIV_ROUND_UP(height, format->vsub); in fb_plane_height()
179 if (!__drm_format_info(r->pixel_format)) { in framebuffer_check()
183 drm_get_format_name(r->pixel_format, in framebuffer_check()
185 return -EINVAL; in framebuffer_check()
188 if (r->width == 0) { in framebuffer_check()
189 DRM_DEBUG_KMS("bad framebuffer width %u\n", r->width); in framebuffer_check()
190 return -EINVAL; in framebuffer_check()
193 if (r->height == 0) { in framebuffer_check()
194 DRM_DEBUG_KMS("bad framebuffer height %u\n", r->height); in framebuffer_check()
195 return -EINVAL; in framebuffer_check()
201 for (i = 0; i < info->num_planes; i++) { in framebuffer_check()
202 unsigned int width = fb_plane_width(r->width, info, i); in framebuffer_check()
203 unsigned int height = fb_plane_height(r->height, info, i); in framebuffer_check()
204 unsigned int block_size = info->char_per_block[i]; in framebuffer_check()
207 if (!block_size && (r->modifier[i] == DRM_FORMAT_MOD_LINEAR)) { in framebuffer_check()
208 DRM_DEBUG_KMS("Format requires non-linear modifier for plane %d\n", i); in framebuffer_check()
209 return -EINVAL; in framebuffer_check()
212 if (!r->handles[i]) { in framebuffer_check()
214 return -EINVAL; in framebuffer_check()
218 return -ERANGE; in framebuffer_check()
220 if ((uint64_t) height * r->pitches[i] + r->offsets[i] > UINT_MAX) in framebuffer_check()
221 return -ERANGE; in framebuffer_check()
223 if (block_size && r->pitches[i] < min_pitch) { in framebuffer_check()
224 DRM_DEBUG_KMS("bad pitch %u for plane %d\n", r->pitches[i], i); in framebuffer_check()
225 return -EINVAL; in framebuffer_check()
228 if (r->modifier[i] && !(r->flags & DRM_MODE_FB_MODIFIERS)) { in framebuffer_check()
230 r->modifier[i], i); in framebuffer_check()
231 return -EINVAL; in framebuffer_check()
234 if (r->flags & DRM_MODE_FB_MODIFIERS && in framebuffer_check()
235 r->modifier[i] != r->modifier[0]) { in framebuffer_check()
237 r->modifier[i], i); in framebuffer_check()
238 return -EINVAL; in framebuffer_check()
242 switch (r->modifier[i]) { in framebuffer_check()
247 if (r->pixel_format != DRM_FORMAT_NV12 || in framebuffer_check()
249 r->pitches[i] % 128) { in framebuffer_check()
251 return -EINVAL; in framebuffer_check()
260 for (i = info->num_planes; i < 4; i++) { in framebuffer_check()
261 if (r->modifier[i]) { in framebuffer_check()
262 DRM_DEBUG_KMS("non-zero modifier for unused plane %d\n", i); in framebuffer_check()
263 return -EINVAL; in framebuffer_check()
266 /* Pre-FB_MODIFIERS userspace didn't clear the structs properly. */ in framebuffer_check()
267 if (!(r->flags & DRM_MODE_FB_MODIFIERS)) in framebuffer_check()
270 if (r->handles[i]) { in framebuffer_check()
272 return -EINVAL; in framebuffer_check()
275 if (r->pitches[i]) { in framebuffer_check()
276 DRM_DEBUG_KMS("non-zero pitch for unused plane %d\n", i); in framebuffer_check()
277 return -EINVAL; in framebuffer_check()
280 if (r->offsets[i]) { in framebuffer_check()
281 DRM_DEBUG_KMS("non-zero offset for unused plane %d\n", i); in framebuffer_check()
282 return -EINVAL; in framebuffer_check()
294 struct drm_mode_config *config = &dev->mode_config; in drm_internal_framebuffer_create()
298 if (r->flags & ~(DRM_MODE_FB_INTERLACED | DRM_MODE_FB_MODIFIERS)) { in drm_internal_framebuffer_create()
299 DRM_DEBUG_KMS("bad framebuffer flags 0x%08x\n", r->flags); in drm_internal_framebuffer_create()
300 return ERR_PTR(-EINVAL); in drm_internal_framebuffer_create()
303 if ((config->min_width > r->width) || (r->width > config->max_width)) { in drm_internal_framebuffer_create()
305 r->width, config->min_width, config->max_width); in drm_internal_framebuffer_create()
306 return ERR_PTR(-EINVAL); in drm_internal_framebuffer_create()
308 if ((config->min_height > r->height) || (r->height > config->max_height)) { in drm_internal_framebuffer_create()
310 r->height, config->min_height, config->max_height); in drm_internal_framebuffer_create()
311 return ERR_PTR(-EINVAL); in drm_internal_framebuffer_create()
314 if (r->flags & DRM_MODE_FB_MODIFIERS && in drm_internal_framebuffer_create()
315 !dev->mode_config.allow_fb_modifiers) { in drm_internal_framebuffer_create()
317 return ERR_PTR(-EINVAL); in drm_internal_framebuffer_create()
324 fb = dev->mode_config.funcs->fb_create(dev, file_priv, r); in drm_internal_framebuffer_create()
335 * drm_mode_addfb2 - add an FB to the graphics configuration
340 * Add a new FB to the specified CRTC, given a user request with format. This is
341 * the 2nd version of the addfb ioctl, which supports multi-planar framebuffers
356 return -EOPNOTSUPP; in drm_mode_addfb2()
362 DRM_DEBUG_KMS("[FB:%d]\n", fb->base.id); in drm_mode_addfb2()
363 r->fb_id = fb->base.id; in drm_mode_addfb2()
365 /* Transfer ownership to the filp for reaping on close */ in drm_mode_addfb2()
366 mutex_lock(&file_priv->fbs_lock); in drm_mode_addfb2()
367 list_add(&fb->filp_head, &file_priv->fbs); in drm_mode_addfb2()
368 mutex_unlock(&file_priv->fbs_lock); in drm_mode_addfb2()
377 if (!dev->mode_config.quirk_addfb_prefer_host_byte_order) { in drm_mode_addfb2_ioctl()
380 * quirk_addfb_prefer_host_byte_order quirk to make in drm_mode_addfb2_ioctl()
387 * then. So block it to make userspace fallback to in drm_mode_addfb2_ioctl()
391 return -EOPNOTSUPP; in drm_mode_addfb2_ioctl()
406 while (!list_empty(&arg->fbs)) { in drm_mode_rmfb_work_fn()
408 list_first_entry(&arg->fbs, typeof(*fb), filp_head); in drm_mode_rmfb_work_fn()
410 list_del_init(&fb->filp_head); in drm_mode_rmfb_work_fn()
416 * drm_mode_rmfb - remove an FB from the configuration
418 * @fb_id: id of framebuffer to remove
423 * Called by the user via ioctl, or by an in-kernel client.
436 return -EOPNOTSUPP; in drm_mode_rmfb()
440 return -ENOENT; in drm_mode_rmfb()
442 mutex_lock(&file_priv->fbs_lock); in drm_mode_rmfb()
443 list_for_each_entry(fbl, &file_priv->fbs, filp_head) in drm_mode_rmfb()
447 mutex_unlock(&file_priv->fbs_lock); in drm_mode_rmfb()
451 list_del_init(&fb->filp_head); in drm_mode_rmfb()
452 mutex_unlock(&file_priv->fbs_lock); in drm_mode_rmfb()
460 * drm_framebuffer_remove may fail with -EINTR on pending signals, in drm_mode_rmfb()
461 * so run this in a separate stack as there's no way to correctly in drm_mode_rmfb()
469 list_add_tail(&fb->filp_head, &arg.fbs); in drm_mode_rmfb()
481 return -ENOENT; in drm_mode_rmfb()
493 * drm_mode_getfb - get FB info
513 return -EOPNOTSUPP; in drm_mode_getfb()
515 fb = drm_framebuffer_lookup(dev, file_priv, r->fb_id); in drm_mode_getfb()
517 return -ENOENT; in drm_mode_getfb()
519 /* Multi-planar framebuffers need getfb2. */ in drm_mode_getfb()
520 if (fb->format->num_planes > 1) { in drm_mode_getfb()
521 ret = -EINVAL; in drm_mode_getfb()
525 if (!fb->funcs->create_handle) { in drm_mode_getfb()
526 ret = -ENODEV; in drm_mode_getfb()
530 r->height = fb->height; in drm_mode_getfb()
531 r->width = fb->width; in drm_mode_getfb()
532 r->depth = fb->format->depth; in drm_mode_getfb()
533 r->bpp = fb->format->cpp[0] * 8; in drm_mode_getfb()
534 r->pitch = fb->pitches[0]; in drm_mode_getfb()
537 * buffer-handle to non-master processes! For in drm_mode_getfb()
538 * backwards-compatibility reasons, we cannot make GET_FB() privileged, in drm_mode_getfb()
539 * so just return an invalid handle for non-masters. in drm_mode_getfb()
542 r->handle = 0; in drm_mode_getfb()
547 ret = fb->funcs->create_handle(fb, file_priv, &r->handle); in drm_mode_getfb()
555 * drm_mode_getfb2 - get extended FB info
576 return -EINVAL; in drm_mode_getfb2_ioctl()
578 fb = drm_framebuffer_lookup(dev, file_priv, r->fb_id); in drm_mode_getfb2_ioctl()
580 return -ENOENT; in drm_mode_getfb2_ioctl()
582 /* For multi-plane framebuffers, we require the driver to place the in drm_mode_getfb2_ioctl()
583 * GEM objects directly in the drm_framebuffer. For single-plane in drm_mode_getfb2_ioctl()
584 * framebuffers, we can fall back to create_handle. in drm_mode_getfb2_ioctl()
586 if (!fb->obj[0] && in drm_mode_getfb2_ioctl()
587 (fb->format->num_planes > 1 || !fb->funcs->create_handle)) { in drm_mode_getfb2_ioctl()
588 ret = -ENODEV; in drm_mode_getfb2_ioctl()
592 r->height = fb->height; in drm_mode_getfb2_ioctl()
593 r->width = fb->width; in drm_mode_getfb2_ioctl()
594 r->pixel_format = fb->format->format; in drm_mode_getfb2_ioctl()
596 r->flags = 0; in drm_mode_getfb2_ioctl()
597 if (dev->mode_config.allow_fb_modifiers) in drm_mode_getfb2_ioctl()
598 r->flags |= DRM_MODE_FB_MODIFIERS; in drm_mode_getfb2_ioctl()
600 for (i = 0; i < ARRAY_SIZE(r->handles); i++) { in drm_mode_getfb2_ioctl()
601 r->handles[i] = 0; in drm_mode_getfb2_ioctl()
602 r->pitches[i] = 0; in drm_mode_getfb2_ioctl()
603 r->offsets[i] = 0; in drm_mode_getfb2_ioctl()
604 r->modifier[i] = 0; in drm_mode_getfb2_ioctl()
607 for (i = 0; i < fb->format->num_planes; i++) { in drm_mode_getfb2_ioctl()
608 r->pitches[i] = fb->pitches[i]; in drm_mode_getfb2_ioctl()
609 r->offsets[i] = fb->offsets[i]; in drm_mode_getfb2_ioctl()
610 if (dev->mode_config.allow_fb_modifiers) in drm_mode_getfb2_ioctl()
611 r->modifier[i] = fb->modifier; in drm_mode_getfb2_ioctl()
615 * buffer-handle to non master/root processes! To match GET_FB() in drm_mode_getfb2_ioctl()
624 for (i = 0; i < fb->format->num_planes; i++) { in drm_mode_getfb2_ioctl()
631 if (fb->obj[i] == fb->obj[j]) { in drm_mode_getfb2_ioctl()
632 r->handles[i] = r->handles[j]; in drm_mode_getfb2_ioctl()
637 if (r->handles[i]) in drm_mode_getfb2_ioctl()
640 if (fb->obj[i]) { in drm_mode_getfb2_ioctl()
641 ret = drm_gem_handle_create(file_priv, fb->obj[i], in drm_mode_getfb2_ioctl()
642 &r->handles[i]); in drm_mode_getfb2_ioctl()
645 ret = fb->funcs->create_handle(fb, file_priv, in drm_mode_getfb2_ioctl()
646 &r->handles[i]); in drm_mode_getfb2_ioctl()
655 /* Delete any previously-created handles on failure. */ in drm_mode_getfb2_ioctl()
656 for (i = 0; i < ARRAY_SIZE(r->handles); i++) { in drm_mode_getfb2_ioctl()
659 if (r->handles[i]) in drm_mode_getfb2_ioctl()
660 drm_gem_handle_delete(file_priv, r->handles[i]); in drm_mode_getfb2_ioctl()
662 /* Zero out any handles identical to the one we just in drm_mode_getfb2_ioctl()
665 for (j = i + 1; j < ARRAY_SIZE(r->handles); j++) { in drm_mode_getfb2_ioctl()
666 if (r->handles[j] == r->handles[i]) in drm_mode_getfb2_ioctl()
667 r->handles[j] = 0; in drm_mode_getfb2_ioctl()
677 * drm_mode_dirtyfb_ioctl - flush frontbuffer rendering on an FB
684 * this ioctl to flush out the changes on manual-update display outputs, e.g.
685 * usb display-link, mipi manual update panels or edp panel self refresh modes.
687 * Modesetting drivers which always update the frontbuffer do not need to
707 return -EOPNOTSUPP; in drm_mode_dirtyfb_ioctl()
709 fb = drm_framebuffer_lookup(dev, file_priv, r->fb_id); in drm_mode_dirtyfb_ioctl()
711 return -ENOENT; in drm_mode_dirtyfb_ioctl()
713 num_clips = r->num_clips; in drm_mode_dirtyfb_ioctl()
714 clips_ptr = (struct drm_clip_rect __user *)(unsigned long)r->clips_ptr; in drm_mode_dirtyfb_ioctl()
717 ret = -EINVAL; in drm_mode_dirtyfb_ioctl()
721 flags = DRM_MODE_FB_DIRTY_FLAGS & r->flags; in drm_mode_dirtyfb_ioctl()
725 ret = -EINVAL; in drm_mode_dirtyfb_ioctl()
731 ret = -EINVAL; in drm_mode_dirtyfb_ioctl()
736 ret = -ENOMEM; in drm_mode_dirtyfb_ioctl()
743 ret = -EFAULT; in drm_mode_dirtyfb_ioctl()
748 if (fb->funcs->dirty) { in drm_mode_dirtyfb_ioctl()
749 ret = fb->funcs->dirty(fb, file_priv, flags, r->color, in drm_mode_dirtyfb_ioctl()
752 ret = -ENOSYS; in drm_mode_dirtyfb_ioctl()
764 * drm_fb_release - remove and free the FBs on this file
783 * list any more, so no need to grab fpriv->fbs_lock. And we need to in drm_fb_release()
787 * Note that a real deadlock between fpriv->fbs_lock and the modeset in drm_fb_release()
791 list_for_each_entry_safe(fb, tfb, &priv->fbs, filp_head) { in drm_fb_release()
793 list_move_tail(&fb->filp_head, &arg.fbs); in drm_fb_release()
795 list_del_init(&fb->filp_head); in drm_fb_release()
797 /* This drops the fpriv->fbs reference. */ in drm_fb_release()
815 struct drm_device *dev = fb->dev; in drm_framebuffer_free()
821 drm_mode_object_unregister(dev, &fb->base); in drm_framebuffer_free()
823 fb->funcs->destroy(fb); in drm_framebuffer_free()
827 * drm_framebuffer_init - initialize a framebuffer
829 * @fb: framebuffer to be initialized
833 * functions & device file and adds it to the master fd list.
837 * by other users. Which means by this point the fb _must_ be fully set up -
849 if (WARN_ON_ONCE(fb->dev != dev || !fb->format)) in drm_framebuffer_init()
850 return -EINVAL; in drm_framebuffer_init()
852 INIT_LIST_HEAD(&fb->filp_head); in drm_framebuffer_init()
854 fb->funcs = funcs; in drm_framebuffer_init()
855 strcpy(fb->comm, current->comm); in drm_framebuffer_init()
857 ret = __drm_mode_object_add(dev, &fb->base, DRM_MODE_OBJECT_FB, in drm_framebuffer_init()
862 mutex_lock(&dev->mode_config.fb_lock); in drm_framebuffer_init()
863 dev->mode_config.num_fb++; in drm_framebuffer_init()
864 list_add(&fb->head, &dev->mode_config.fb_list); in drm_framebuffer_init()
865 mutex_unlock(&dev->mode_config.fb_lock); in drm_framebuffer_init()
867 drm_mode_object_register(dev, &fb->base); in drm_framebuffer_init()
874 * drm_framebuffer_lookup - look up a drm framebuffer and grab a reference
876 * @file_priv: drm file to check for lease against.
879 * If successful, this grabs an additional reference to the framebuffer -
880 * callers need to make sure to eventually unreference the returned framebuffer
898 * drm_framebuffer_unregister_private - unregister a private fb from the lookup idr
899 * @fb: fb to unregister
901 * Drivers need to call this when cleaning up driver-private framebuffers, e.g.
903 * i.e. the object may not be destroyed through this call (since it'll lead to a
906 * NOTE: This function is deprecated. For driver-private framebuffers it is not
907 * recommended to embed a framebuffer struct info fbdev struct, instead, a
909 * when the framebuffer is to be cleaned up.
918 dev = fb->dev; in drm_framebuffer_unregister_private()
921 drm_mode_object_unregister(dev, &fb->base); in drm_framebuffer_unregister_private()
926 * drm_framebuffer_cleanup - remove a framebuffer object
927 * @fb: framebuffer to remove
929 * Cleanup framebuffer. This function is intended to be used from the drivers
930 * &drm_framebuffer_funcs.destroy callback. It can also be used to clean up
933 * Note that this function does not remove the fb from active usage - if it is
935 * the id and get back -EINVAL. Obviously no concern at driver unload time.
937 * Also, the framebuffer will not be removed from the lookup idr - for
938 * user-created framebuffers this will happen in in the rmfb ioctl. For
939 * driver-private objects (e.g. for fbdev) drivers need to explicitly call
944 struct drm_device *dev = fb->dev; in drm_framebuffer_cleanup()
946 mutex_lock(&dev->mode_config.fb_lock); in drm_framebuffer_cleanup()
947 list_del(&fb->head); in drm_framebuffer_cleanup()
948 dev->mode_config.num_fb--; in drm_framebuffer_cleanup()
949 mutex_unlock(&dev->mode_config.fb_lock); in drm_framebuffer_cleanup()
956 struct drm_device *dev = fb->dev; in atomic_remove_fb()
970 ret = -ENOMEM; in atomic_remove_fb()
973 state->acquire_ctx = &ctx; in atomic_remove_fb()
984 if (plane->state->fb != fb) in atomic_remove_fb()
993 if (disable_crtcs && plane_state->crtc->primary == plane) { in atomic_remove_fb()
996 crtc_state = drm_atomic_get_existing_crtc_state(state, plane_state->crtc); in atomic_remove_fb()
998 ret = drm_atomic_add_affected_connectors(state, plane_state->crtc); in atomic_remove_fb()
1002 crtc_state->active = false; in atomic_remove_fb()
1028 if (ret == -EDEADLK) { in atomic_remove_fb()
1040 if (ret == -EINVAL && !disable_crtcs) { in atomic_remove_fb()
1050 struct drm_device *dev = fb->dev; in legacy_remove_fb()
1057 if (crtc->primary->fb == fb) { in legacy_remove_fb()
1060 DRM_ERROR("failed to reset crtc %p when fb was deleted\n", crtc); in legacy_remove_fb()
1065 if (plane->fb == fb) in legacy_remove_fb()
1072 * drm_framebuffer_remove - remove and unreference a framebuffer object
1073 * @fb: framebuffer to remove
1076 * using @fb, removes it, setting it to NULL. Then drops the reference to the
1077 * passed-in framebuffer. Might take the modeset locks.
1080 * last reference to the framebuffer. It is also guaranteed to not take the
1090 dev = fb->dev; in drm_framebuffer_remove()
1092 WARN_ON(!list_empty(&fb->filp_head)); in drm_framebuffer_remove()
1097 * longer need, try to optimize this away. in drm_framebuffer_remove()
1104 * Note that userspace could try to race with use and instate a new in drm_framebuffer_remove()
1106 * in-use fb with fb-id == 0. Userspace is allowed to shoot its own foot in drm_framebuffer_remove()
1123 * drm_framebuffer_plane_width - width of the plane given the first plane
1134 if (plane >= fb->format->num_planes) in drm_framebuffer_plane_width()
1137 return fb_plane_width(width, fb->format, plane); in drm_framebuffer_plane_width()
1142 * drm_framebuffer_plane_height - height of the plane given the first plane
1153 if (plane >= fb->format->num_planes) in drm_framebuffer_plane_height()
1156 return fb_plane_height(height, fb->format, plane); in drm_framebuffer_plane_height()
1166 drm_printf_indent(p, indent, "allocated by = %s\n", fb->comm); in drm_framebuffer_print_info()
1170 drm_get_format_name(fb->format->format, &format_name)); in drm_framebuffer_print_info()
1171 drm_printf_indent(p, indent, "modifier=0x%llx\n", fb->modifier); in drm_framebuffer_print_info()
1172 drm_printf_indent(p, indent, "size=%ux%u\n", fb->width, fb->height); in drm_framebuffer_print_info()
1175 for (i = 0; i < fb->format->num_planes; i++) { in drm_framebuffer_print_info()
1177 drm_framebuffer_plane_width(fb->width, fb, i), in drm_framebuffer_print_info()
1178 drm_framebuffer_plane_height(fb->height, fb, i)); in drm_framebuffer_print_info()
1179 drm_printf_indent(p, indent + 1, "pitch[%u]=%u\n", i, fb->pitches[i]); in drm_framebuffer_print_info()
1180 drm_printf_indent(p, indent + 1, "offset[%u]=%u\n", i, fb->offsets[i]); in drm_framebuffer_print_info()
1182 fb->obj[i] ? "" : "(null)"); in drm_framebuffer_print_info()
1183 if (fb->obj[i]) in drm_framebuffer_print_info()
1184 drm_gem_print_info(p, indent + 2, fb->obj[i]); in drm_framebuffer_print_info()
1191 struct drm_info_node *node = m->private; in drm_framebuffer_info()
1192 struct drm_device *dev = node->minor->dev; in drm_framebuffer_info()
1196 mutex_lock(&dev->mode_config.fb_lock); in drm_framebuffer_info()
1198 drm_printf(&p, "framebuffer[%u]:\n", fb->base.id); in drm_framebuffer_info()
1201 mutex_unlock(&dev->mode_config.fb_lock); in drm_framebuffer_info()
1214 minor->debugfs_root, minor); in drm_framebuffer_debugfs_init()