Source-Changes-HG archive

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

[src/trunk]: src/sys/external/bsd Tweak IS_ENABLED to allow CONFIG_FOO values.



details:   https://anonhg.NetBSD.org/src/rev/63ac4d61b1ea
branches:  trunk
changeset: 340041:63ac4d61b1ea
user:      skrll <skrll%NetBSD.org@localhost>
date:      Thu Aug 20 21:41:12 2015 +0000

description:
Tweak IS_ENABLED to allow CONFIG_FOO values.

No functional change to drm2.

LGTM from riastradh@

diffstat:

 sys/external/bsd/common/include/linux/kernel.h                 |  4 ++--
 sys/external/bsd/drm2/dist/drm/radeon/atombios_encoders.c      |  2 +-
 sys/external/bsd/drm2/dist/drm/radeon/radeon_legacy_encoders.c |  2 +-
 sys/external/bsd/drm2/drm/files.drmkms                         |  6 +++++-
 sys/external/bsd/drm2/i915drm/files.i915drmkms                 |  5 +++--
 5 files changed, 12 insertions(+), 7 deletions(-)

diffs (81 lines):

diff -r 46066bd3195d -r 63ac4d61b1ea sys/external/bsd/common/include/linux/kernel.h
--- a/sys/external/bsd/common/include/linux/kernel.h    Thu Aug 20 20:08:04 2015 +0000
+++ b/sys/external/bsd/common/include/linux/kernel.h    Thu Aug 20 21:41:12 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: kernel.h,v 1.7 2015/04/20 15:22:18 riastradh Exp $     */
+/*     $NetBSD: kernel.h,v 1.8 2015/08/20 21:41:12 skrll Exp $ */
 
 /*-
  * Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -41,7 +41,7 @@
 
 #define        oops_in_progress        (panicstr != NULL)
 
-#define        IS_ENABLED(option)      0 /* XXX Hmm...  */
+#define        IS_ENABLED(option)      (option)
 
 #define        __printf        __printflike
 #define        __user
diff -r 46066bd3195d -r 63ac4d61b1ea sys/external/bsd/drm2/dist/drm/radeon/atombios_encoders.c
--- a/sys/external/bsd/drm2/dist/drm/radeon/atombios_encoders.c Thu Aug 20 20:08:04 2015 +0000
+++ b/sys/external/bsd/drm2/dist/drm/radeon/atombios_encoders.c Thu Aug 20 21:41:12 2015 +0000
@@ -133,7 +133,7 @@
        }
 }
 
-#if defined(CONFIG_BACKLIGHT_CLASS_DEVICE) || defined(CONFIG_BACKLIGHT_CLASS_DEVICE_MODULE)
+#if IS_ENABLED(CONFIG_BACKLIGHT_CLASS_DEVICE) || IS_ENABLED(CONFIG_BACKLIGHT_CLASS_DEVICE_MODULE)
 
 static u8 radeon_atom_bl_level(struct backlight_device *bd)
 {
diff -r 46066bd3195d -r 63ac4d61b1ea sys/external/bsd/drm2/dist/drm/radeon/radeon_legacy_encoders.c
--- a/sys/external/bsd/drm2/dist/drm/radeon/radeon_legacy_encoders.c    Thu Aug 20 20:08:04 2015 +0000
+++ b/sys/external/bsd/drm2/dist/drm/radeon/radeon_legacy_encoders.c    Thu Aug 20 21:41:12 2015 +0000
@@ -310,7 +310,7 @@
        radeon_legacy_lvds_update(&radeon_encoder->base, dpms_mode);
 }
 
-#if defined(CONFIG_BACKLIGHT_CLASS_DEVICE) || defined(CONFIG_BACKLIGHT_CLASS_DEVICE_MODULE)
+#if IS_ENABLED(CONFIG_BACKLIGHT_CLASS_DEVICE) || IS_ENABLED(CONFIG_BACKLIGHT_CLASS_DEVICE_MODULE)
 
 static uint8_t radeon_legacy_lvds_level(struct backlight_device *bd)
 {
diff -r 46066bd3195d -r 63ac4d61b1ea sys/external/bsd/drm2/drm/files.drmkms
--- a/sys/external/bsd/drm2/drm/files.drmkms    Thu Aug 20 20:08:04 2015 +0000
+++ b/sys/external/bsd/drm2/drm/files.drmkms    Thu Aug 20 21:41:12 2015 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: files.drmkms,v 1.11 2015/03/05 17:50:41 riastradh Exp $
+#      $NetBSD: files.drmkms,v 1.12 2015/08/20 21:41:12 skrll Exp $
 
 include "external/bsd/drm2/linux/files.drmkms_linux"
 
@@ -26,6 +26,10 @@
 # XXX Should probably be in a header file.  opt_drmkms.h?
 makeoptions    drmkms  CPPFLAGS+="-D__KERNEL__"
 
+makeoptions    drmkms  CPPFLAGS+="-DCONFIG_FB=0"
+makeoptions    drmkms  CPPFLAGS+="-DCONFIG_BACKLIGHT_CLASS_DEVICE=0"
+makeoptions    drmkms  CPPFLAGS+="-DCONFIG_BACKLIGHT_CLASS_DEVICE_MODULE=0"
+
 file   external/bsd/drm2/dist/drm/drm_auth.c           drmkms
 file   external/bsd/drm2/dist/drm/drm_buffer.c         drmkms
 file   external/bsd/drm2/dist/drm/drm_bufs.c           drmkms
diff -r 46066bd3195d -r 63ac4d61b1ea sys/external/bsd/drm2/i915drm/files.i915drmkms
--- a/sys/external/bsd/drm2/i915drm/files.i915drmkms    Thu Aug 20 20:08:04 2015 +0000
+++ b/sys/external/bsd/drm2/i915drm/files.i915drmkms    Thu Aug 20 21:41:12 2015 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: files.i915drmkms,v 1.10 2015/03/05 17:50:41 riastradh Exp $
+#      $NetBSD: files.i915drmkms,v 1.11 2015/08/20 21:41:12 skrll Exp $
 
 define intelfbbus      { }
 device i915drmkms: drmkms, drmkms_pci, intelfbbus, agp_i810
@@ -17,7 +17,8 @@
 makeoptions    i915drmkms      "CWARNFLAGS.intel_pm.c"+="-Wno-shadow"
 
 # XXX x86 kludge.
-makeoptions    i915drmkms      CPPFLAGS+="-DCONFIG_DRM_I915_FBDEV"
+makeoptions    i915drmkms      CPPFLAGS+="-DCONFIG_DRM_I915_FBDEV=1"
+makeoptions    i915drmkms      CPPFLAGS+="-DCONFIG_DRM_I915_PRELIMINARY_HW_SUPPORT=0"
 
 file   external/bsd/drm2/dist/drm/i915/dvo_ch7017.c    i915drmkms
 file   external/bsd/drm2/dist/drm/i915/dvo_ch7xxx.c    i915drmkms



Home | Main Index | Thread Index | Old Index