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/drm/i915 Unifdef the dmi hacks he...



details:   https://anonhg.NetBSD.org/src/rev/9e19fec12232
branches:  trunk
changeset: 329374:9e19fec12232
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Wed May 21 15:40:52 2014 +0000

description:
Unifdef the dmi hacks here too, now that we have dmi_check_system.

diffstat:

 sys/external/bsd/drm2/dist/drm/i915/intel_crt.c  |   6 +-----
 sys/external/bsd/drm2/dist/drm/i915/intel_lvds.c |  12 ++----------
 2 files changed, 3 insertions(+), 15 deletions(-)

diffs (99 lines):

diff -r 4c9f3533d7e9 -r 9e19fec12232 sys/external/bsd/drm2/dist/drm/i915/intel_crt.c
--- a/sys/external/bsd/drm2/dist/drm/i915/intel_crt.c   Wed May 21 14:21:35 2014 +0000
+++ b/sys/external/bsd/drm2/dist/drm/i915/intel_crt.c   Wed May 21 15:40:52 2014 +0000
@@ -706,7 +706,6 @@
        .destroy = intel_encoder_destroy,
 };
 
-#ifndef __NetBSD__             /* XXX dmi hack */
 static int __init intel_no_crt_dmi_callback(const struct dmi_system_id *id)
 {
        DRM_INFO("Skipping CRT initialization for %s\n", id->ident);
@@ -722,9 +721,8 @@
                        DMI_MATCH(DMI_PRODUCT_NAME, "ZGB"),
                },
        },
-       { }
+       { .callback = NULL }
 };
-#endif
 
 void intel_crt_init(struct drm_device *dev)
 {
@@ -733,11 +731,9 @@
        struct intel_connector *intel_connector;
        struct drm_i915_private *dev_priv = dev->dev_private;
 
-#ifndef __NetBSD__             /* XXX dmi hack */
        /* Skip machines without VGA that falsely report hotplug events */
        if (dmi_check_system(intel_no_crt))
                return;
-#endif
 
        crt = kzalloc(sizeof(struct intel_crt), GFP_KERNEL);
        if (!crt)
diff -r 4c9f3533d7e9 -r 9e19fec12232 sys/external/bsd/drm2/dist/drm/i915/intel_lvds.c
--- a/sys/external/bsd/drm2/dist/drm/i915/intel_lvds.c  Wed May 21 14:21:35 2014 +0000
+++ b/sys/external/bsd/drm2/dist/drm/i915/intel_lvds.c  Wed May 21 15:40:52 2014 +0000
@@ -473,7 +473,6 @@
        return 1;
 }
 
-#ifndef __NetBSD__             /* XXX dmi hack */
 static int intel_no_modeset_on_lid_dmi_callback(const struct dmi_system_id *id)
 {
        DRM_INFO("Skipping forced modeset for %s\n", id->ident);
@@ -491,9 +490,8 @@
                },
        },
 
-       { }     /* terminating entry */
+       { .callback = NULL }    /* terminating entry */
 };
-#endif
 
 /*
  * Lid events. Note the use of 'modeset_on_lid':
@@ -522,11 +520,9 @@
         */
        connector->status = connector->funcs->detect(connector, false);
 
-#ifndef __NetBSD__             /* XXX dmi hack */
        /* Don't force modeset on machines where it causes a GPU lockup */
        if (dmi_check_system(intel_no_modeset_on_lid))
                return NOTIFY_OK;
-#endif
        if (!acpi_lid_open()) {
                dev_priv->modeset_on_lid = 1;
                return NOTIFY_OK;
@@ -629,7 +625,6 @@
        .destroy = intel_encoder_destroy,
 };
 
-#ifndef __NetBSD__             /* XXX dmi hack */
 static int __init intel_no_lvds_dmi_callback(const struct dmi_system_id *id)
 {
        DRM_INFO("Skipping LVDS initialization for %s\n", id->ident);
@@ -798,9 +793,8 @@
                },
        },
 
-       { }     /* terminating entry */
+       { .callback = NULL }    /* terminating entry */
 };
-#endif
 
 /**
  * intel_find_lvds_downclock - find the reduced downclock for LVDS in EDID
@@ -942,11 +936,9 @@
        if (!intel_lvds_supported(dev))
                return false;
 
-#ifndef __NetBSD__             /* XXX dmi hack */
        /* Skip init on machines we know falsely report LVDS */
        if (dmi_check_system(intel_no_lvds))
                return false;
-#endif
 
        pin = GMBUS_PORT_PANEL;
        if (!lvds_is_present_in_vbt(dev, &pin)) {



Home | Main Index | Thread Index | Old Index