Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/external/bsd/drm2/dist Expose drm fb helpers for ddb ent...



details:   https://anonhg.NetBSD.org/src/rev/34bc4e69bca6
branches:  trunk
changeset: 330880:34bc4e69bca6
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Thu Jul 24 21:36:39 2014 +0000

description:
Expose drm fb helpers for ddb enter/exit.

diffstat:

 sys/external/bsd/drm2/dist/drm/drm_fb_helper.c         |  20 ++++++++++++++---
 sys/external/bsd/drm2/dist/include/drm/drm_fb_helper.h |   2 +
 2 files changed, 18 insertions(+), 4 deletions(-)

diffs (67 lines):

diff -r 0dd625b44a86 -r 34bc4e69bca6 sys/external/bsd/drm2/dist/drm/drm_fb_helper.c
--- a/sys/external/bsd/drm2/dist/drm/drm_fb_helper.c    Thu Jul 24 21:35:12 2014 +0000
+++ b/sys/external/bsd/drm2/dist/drm/drm_fb_helper.c    Thu Jul 24 21:36:39 2014 +0000
@@ -173,7 +173,6 @@
 }
 #endif
 
-#ifndef __NetBSD__             /* XXX fb info */
 static void drm_fb_helper_save_lut_atomic(struct drm_crtc *crtc, struct drm_fb_helper *helper)
 {
        uint16_t *r_base, *g_base, *b_base;
@@ -208,9 +207,16 @@
  * drm_fb_helper_debug_enter - implementation for ->fb_debug_enter
  * @info: fbdev registered by the helper
  */
+#ifndef __NetBSD__
 int drm_fb_helper_debug_enter(struct fb_info *info)
 {
-       struct drm_fb_helper *helper = info->par;
+       return drm_fb_helper_debug_enter_fb(info->par);
+}
+#endif
+
+int
+drm_fb_helper_debug_enter_fb(struct drm_fb_helper *helper)
+{
        struct drm_crtc_helper_funcs *funcs;
        int i;
 
@@ -257,9 +263,16 @@
  * drm_fb_helper_debug_leave - implementation for ->fb_debug_leave
  * @info: fbdev registered by the helper
  */
+#ifndef __NetBSD__
 int drm_fb_helper_debug_leave(struct fb_info *info)
 {
-       struct drm_fb_helper *helper = info->par;
+       return drm_fb_helper_debug_leave_fb(info->par);
+}
+#endif
+
+int
+drm_fb_helper_debug_leave_fb(struct drm_fb_helper *helper)
+{
        struct drm_crtc *crtc;
        struct drm_crtc_helper_funcs *funcs;
        struct drm_framebuffer *fb;
@@ -287,7 +300,6 @@
        return 0;
 }
 EXPORT_SYMBOL(drm_fb_helper_debug_leave);
-#endif
 
 /**
  * drm_fb_helper_restore_fbdev_mode - restore fbdev configuration
diff -r 0dd625b44a86 -r 34bc4e69bca6 sys/external/bsd/drm2/dist/include/drm/drm_fb_helper.h
--- a/sys/external/bsd/drm2/dist/include/drm/drm_fb_helper.h    Thu Jul 24 21:35:12 2014 +0000
+++ b/sys/external/bsd/drm2/dist/include/drm/drm_fb_helper.h    Thu Jul 24 21:36:39 2014 +0000
@@ -139,6 +139,8 @@
 int drm_fb_helper_debug_enter(struct fb_info *info);
 int drm_fb_helper_debug_leave(struct fb_info *info);
 #endif
+int drm_fb_helper_debug_enter_fb(struct drm_fb_helper *fb_helper);
+int drm_fb_helper_debug_leave_fb(struct drm_fb_helper *fb_helper);
 struct drm_display_mode *
 drm_has_preferred_mode(struct drm_fb_helper_connector *fb_connector,
                        int width, int height);



Home | Main Index | Thread Index | Old Index