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/include/drm drm_can_sleep now liv...



details:   https://anonhg.NetBSD.org/src/rev/f04528ca332a
branches:  trunk
changeset: 1028125:f04528ca332a
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Sun Dec 19 01:56:00 2021 +0000

description:
drm_can_sleep now lives in drm_util.h, move ifdef goo there.


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

diffstat:

 sys/external/bsd/drm2/dist/include/drm/drmP.h     |  14 +-------------
 sys/external/bsd/drm2/dist/include/drm/drm_util.h |   6 +++++-
 2 files changed, 6 insertions(+), 14 deletions(-)

diffs (51 lines):

diff -r 0f463d264994 -r f04528ca332a sys/external/bsd/drm2/dist/include/drm/drmP.h
--- a/sys/external/bsd/drm2/dist/include/drm/drmP.h     Sun Dec 19 01:55:52 2021 +0000
+++ b/sys/external/bsd/drm2/dist/include/drm/drmP.h     Sun Dec 19 01:56:00 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: drmP.h,v 1.48 2021/12/19 01:55:45 riastradh Exp $      */
+/*     $NetBSD: drmP.h,v 1.49 2021/12/19 01:56:00 riastradh Exp $      */
 
 /*
  * Internal Header for the Direct Rendering Manager
@@ -955,18 +955,6 @@
 extern int drm_platform_init(struct drm_driver *driver, struct platform_device *platform_device);
 extern int drm_platform_set_busid(struct drm_device *d, struct drm_master *m);
 
-/* returns true if currently okay to sleep */
-static __inline__ bool drm_can_sleep(void)
-{
-#ifdef __NetBSD__
-       return false;           /* XXX */
-#else
-       if (in_atomic() || in_dbg_master() || irqs_disabled())
-               return false;
-       return true;
-#endif
-}
-
 #ifdef __NetBSD__
 
 /* XXX This is pretty kludgerific.  */
diff -r 0f463d264994 -r f04528ca332a sys/external/bsd/drm2/dist/include/drm/drm_util.h
--- a/sys/external/bsd/drm2/dist/include/drm/drm_util.h Sun Dec 19 01:55:52 2021 +0000
+++ b/sys/external/bsd/drm2/dist/include/drm/drm_util.h Sun Dec 19 01:56:00 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: drm_util.h,v 1.2 2021/12/18 23:45:46 riastradh Exp $   */
+/*     $NetBSD: drm_util.h,v 1.3 2021/12/19 01:56:00 riastradh Exp $   */
 
 /*
  * Internal Header for the Direct Rendering Manager
@@ -77,9 +77,13 @@
  */
 static inline bool drm_can_sleep(void)
 {
+#ifdef __NetBSD__
+       return false;           /* XXX */
+#else
        if (in_atomic() || in_dbg_master() || irqs_disabled())
                return false;
        return true;
+#endif
 }
 
 #endif



Home | Main Index | Thread Index | Old Index