Merge branches 'acpi-cleanup', 'acpi-thermal', 'acpi-video' and 'acpi-dock'
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Tue, 8 Apr 2014 11:29:15 +0000 (13:29 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Tue, 8 Apr 2014 11:29:15 +0000 (13:29 +0200)
* acpi-cleanup:
  ACPI: Clean up memory allocations

* acpi-thermal:
  ACPI / thermal: Fix wrong variable usage in debug statement

* acpi-video:
  ACPI / video: Favor native backlight interface for ThinkPad Helix

* acpi-dock:
  ACPI / dock: Drop dock_device_ids[] table

drivers/acpi/dock.c
drivers/acpi/osl.c
drivers/acpi/thermal.c
drivers/acpi/utils.c
drivers/acpi/video.c

index f0fc626..d9339b4 100644 (file)
@@ -51,12 +51,6 @@ MODULE_PARM_DESC(immediate_undock, "1 (default) will cause the driver to "
        " the driver to wait for userspace to write the undock sysfs file "
        " before undocking");
 
-static const struct acpi_device_id dock_device_ids[] = {
-       {"LNXDOCK", 0},
-       {"", 0},
-};
-MODULE_DEVICE_TABLE(acpi, dock_device_ids);
-
 struct dock_station {
        acpi_handle handle;
        unsigned long last_dock_time;
index f7fd72a..6776c59 100644 (file)
@@ -1219,10 +1219,9 @@ acpi_os_create_semaphore(u32 max_units, u32 initial_units, acpi_handle * handle)
 {
        struct semaphore *sem = NULL;
 
-       sem = acpi_os_allocate(sizeof(struct semaphore));
+       sem = acpi_os_allocate_zeroed(sizeof(struct semaphore));
        if (!sem)
                return AE_NO_MEMORY;
-       memset(sem, 0, sizeof(struct semaphore));
 
        sema_init(sem, initial_units);
 
index 9640685..c1e31a4 100644 (file)
@@ -344,7 +344,7 @@ static int acpi_thermal_trips_update(struct acpi_thermal *tz, int flag)
                        tz->trips.hot.flags.valid = 1;
                        ACPI_DEBUG_PRINT((ACPI_DB_INFO,
                                        "Found hot threshold [%lu]\n",
-                                       tz->trips.critical.temperature));
+                                       tz->trips.hot.temperature));
                }
        }
 
index 0f5f78f..bba5261 100644 (file)
@@ -164,11 +164,10 @@ acpi_extract_package(union acpi_object *package,
         * Validate output buffer.
         */
        if (buffer->length == ACPI_ALLOCATE_BUFFER) {
-               buffer->pointer = ACPI_ALLOCATE(size_required);
+               buffer->pointer = ACPI_ALLOCATE_ZEROED(size_required);
                if (!buffer->pointer)
                        return AE_NO_MEMORY;
                buffer->length = size_required;
-               memset(buffer->pointer, 0, size_required);
        } else {
                if (buffer->length < size_required) {
                        buffer->length = size_required;
index 48c7e8a..8b6990e 100644 (file)
@@ -487,6 +487,14 @@ static struct dmi_system_id video_dmi_table[] __initdata = {
                DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo IdeaPad Yoga 13"),
                },
        },
+       {
+       .callback = video_set_use_native_backlight,
+       .ident = "Thinkpad Helix",
+       .matches = {
+               DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+               DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad Helix"),
+               },
+       },
        {
         .callback = video_set_use_native_backlight,
         .ident = "Dell Inspiron 7520",