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 fix debugging compilation (ALL ke...



details:   https://anonhg.NetBSD.org/src/rev/7bd0c342c0df
branches:  trunk
changeset: 334710:7bd0c342c0df
user:      christos <christos%NetBSD.org@localhost>
date:      Tue Dec 02 21:49:36 2014 +0000

description:
fix debugging compilation (ALL kernel)

diffstat:

 sys/external/bsd/drm2/dist/drm/drm_stub.c     |  7 ++++++-
 sys/external/bsd/drm2/dist/include/drm/drmP.h |  3 ++-
 2 files changed, 8 insertions(+), 2 deletions(-)

diffs (61 lines):

diff -r 7bbc3d8b43c2 -r 7bd0c342c0df sys/external/bsd/drm2/dist/drm/drm_stub.c
--- a/sys/external/bsd/drm2/dist/drm/drm_stub.c Tue Dec 02 21:28:31 2014 +0000
+++ b/sys/external/bsd/drm2/dist/drm/drm_stub.c Tue Dec 02 21:49:36 2014 +0000
@@ -341,7 +341,9 @@
 {
        struct drm_minor *new_minor;
        unsigned long flags;
+#ifndef __NetBSD__
        int ret;
+#endif
        int minor_id;
 
        DRM_DEBUG("\n");
@@ -365,6 +367,7 @@
 
        new_minor->index = minor_id;
 
+#ifndef __NetBSD__
        ret = drm_debugfs_init(new_minor, minor_id, drm_debugfs_root);
        if (ret) {
                DRM_ERROR("DRM: Failed to initialize /sys/kernel/debug/dri.\n");
@@ -376,7 +379,7 @@
                DRM_ERROR("DRM: Error sysfs_device_add.\n");
                goto err_debugfs;
        }
-
+#endif
        /* replace NULL with @minor so lookups will succeed from now on */
        spin_lock_irqsave(&drm_minor_lock, flags);
        idr_replace(&drm_minors_idr, new_minor, new_minor->index);
@@ -385,6 +388,7 @@
        DRM_DEBUG("new minor assigned %d\n", minor_id);
        return 0;
 
+#ifndef __NetBSD__
 err_debugfs:
        drm_debugfs_cleanup(new_minor);
 err_id:
@@ -393,6 +397,7 @@
        spin_unlock_irqrestore(&drm_minor_lock, flags);
        new_minor->index = 0;
        return ret;
+#endif
 }
 
 static void drm_minor_unregister(struct drm_device *dev, unsigned int type)
diff -r 7bbc3d8b43c2 -r 7bd0c342c0df sys/external/bsd/drm2/dist/include/drm/drmP.h
--- a/sys/external/bsd/drm2/dist/include/drm/drmP.h     Tue Dec 02 21:28:31 2014 +0000
+++ b/sys/external/bsd/drm2/dist/include/drm/drmP.h     Tue Dec 02 21:49:36 2014 +0000
@@ -1637,9 +1637,10 @@
 extern unsigned int drm_timestamp_monotonic;
 
 extern struct class *drm_class;
+#ifndef __NetBSD__
 extern struct dentry *drm_debugfs_root;
 
-#ifdef __NetBSD__
+#else
 extern spinlock_t drm_minor_lock;
 #endif
 extern struct idr drm_minors_idr;



Home | Main Index | Thread Index | Old Index