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/drm Make our code follow CONFIG_DRM_LE...



details:   https://anonhg.NetBSD.org/src/rev/6f6bc8a6c553
branches:  trunk
changeset: 1028205:6f6bc8a6c553
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Sun Dec 19 09:49:24 2021 +0000

description:
Make our code follow CONFIG_DRM_LEGACY.

We might want to delete all this code later, but no rush.


Author: Maya Rashish <maya%NetBSD.org@localhost>

diffstat:

 sys/external/bsd/drm2/drm/drm_lock.c |  11 +++++++++--
 1 files changed, 9 insertions(+), 2 deletions(-)

diffs (64 lines):

diff -r fca08cfe8e3a -r 6f6bc8a6c553 sys/external/bsd/drm2/drm/drm_lock.c
--- a/sys/external/bsd/drm2/drm/drm_lock.c      Sun Dec 19 09:49:17 2021 +0000
+++ b/sys/external/bsd/drm2/drm/drm_lock.c      Sun Dec 19 09:49:24 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: drm_lock.c,v 1.10 2021/12/19 00:57:29 riastradh Exp $  */
+/*     $NetBSD: drm_lock.c,v 1.11 2021/12/19 09:49:24 riastradh Exp $  */
 
 /*-
  * Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -46,7 +46,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: drm_lock.c,v 1.10 2021/12/19 00:57:29 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: drm_lock.c,v 1.11 2021/12/19 09:49:24 riastradh Exp $");
 
 #include <sys/types.h>
 #include <sys/errno.h>
@@ -60,6 +60,8 @@
 
 static bool    drm_lock_acquire(struct drm_lock_data *, int);
 static void    drm_lock_release(struct drm_lock_data *, int);
+
+#if IS_ENABLED(CONFIG_DRM_LEGACY)
 static int     drm_lock_block_signals(struct drm_device *, struct drm_lock *,
                    struct drm_file *);
 static void    drm_lock_unblock_signals(struct drm_device *,
@@ -215,6 +217,7 @@
 out0:  mutex_lock(&drm_global_mutex);
        return error;
 }
+#endif
 
 /*
  * Try to acquire the lock.  Whether or not we acquire it, guarantee
@@ -260,6 +263,7 @@
        spin_unlock(&lock_data->spinlock);
 }
 
+#if IS_ENABLED(CONFIG_DRM_LEGACY)
 /*
  * Release the lock and free it on closing of a drm file.
  */
@@ -296,6 +300,7 @@
 
 out:   spin_unlock(&lock_data->spinlock);
 }
+#endif
 
 /*
  * Try to acquire the lock.  Return true if successful, false if not.
@@ -353,6 +358,7 @@
        DRM_SPIN_WAKEUP_ONE(&lock_data->lock_queue, &lock_data->spinlock);
 }
 
+#if IS_ENABLED(CONFIG_DRM_LEGACY)
 /*
  * Block signals for a process that holds a drm lock.
  *
@@ -375,3 +381,4 @@
     struct drm_lock *lock_request __unused, struct drm_file *file __unused)
 {
 }
+#endif



Home | Main Index | Thread Index | Old Index