Commit 21c806d9 authored by Rafael J. Wysocki's avatar Rafael J. Wysocki

Merge branches 'acpi-processor', 'acpi-hotplug' and 'acpi-battery'

* acpi-processor:
  ACPI / processor: Make acpi_cpu_soft_notify() process CPU FROZEN events

* acpi-hotplug:
  ACPI / hotplug: Check scan handlers in acpi_scan_hot_remove()

* acpi-battery:
  ACPI / battery: Fix warning message in acpi_battery_get_state()
...@@ -540,12 +540,12 @@ static int acpi_battery_get_state(struct acpi_battery *battery) ...@@ -540,12 +540,12 @@ static int acpi_battery_get_state(struct acpi_battery *battery)
*/ */
if (battery->capacity_now > battery->full_charge_capacity if (battery->capacity_now > battery->full_charge_capacity
&& battery->full_charge_capacity != ACPI_BATTERY_VALUE_UNKNOWN) { && battery->full_charge_capacity != ACPI_BATTERY_VALUE_UNKNOWN) {
battery->capacity_now = battery->full_charge_capacity;
if (battery->capacity_now != battery->design_capacity) if (battery->capacity_now != battery->design_capacity)
printk_once(KERN_WARNING FW_BUG printk_once(KERN_WARNING FW_BUG
"battery: reported current charge level (%d) " "battery: reported current charge level (%d) "
"is higher than reported maximum charge level (%d).\n", "is higher than reported maximum charge level (%d).\n",
battery->capacity_now, battery->full_charge_capacity); battery->capacity_now, battery->full_charge_capacity);
battery->capacity_now = battery->full_charge_capacity;
} }
if (test_bit(ACPI_BATTERY_QUIRK_PERCENTAGE_CAPACITY, &battery->flags) if (test_bit(ACPI_BATTERY_QUIRK_PERCENTAGE_CAPACITY, &battery->flags)
......
...@@ -120,6 +120,7 @@ static int acpi_cpu_soft_notify(struct notifier_block *nfb, ...@@ -120,6 +120,7 @@ static int acpi_cpu_soft_notify(struct notifier_block *nfb,
unsigned int cpu = (unsigned long)hcpu; unsigned int cpu = (unsigned long)hcpu;
struct acpi_processor *pr = per_cpu(processors, cpu); struct acpi_processor *pr = per_cpu(processors, cpu);
struct acpi_device *device; struct acpi_device *device;
action &= ~CPU_TASKS_FROZEN;
/* /*
* CPU_STARTING and CPU_DYING must not sleep. Return here since * CPU_STARTING and CPU_DYING must not sleep. Return here since
......
...@@ -353,7 +353,8 @@ static int acpi_scan_hot_remove(struct acpi_device *device) ...@@ -353,7 +353,8 @@ static int acpi_scan_hot_remove(struct acpi_device *device)
unsigned long long sta; unsigned long long sta;
acpi_status status; acpi_status status;
if (device->handler->hotplug.demand_offline && !acpi_force_hot_remove) { if (device->handler && device->handler->hotplug.demand_offline
&& !acpi_force_hot_remove) {
if (!acpi_scan_is_offline(device, true)) if (!acpi_scan_is_offline(device, true))
return -EBUSY; return -EBUSY;
} else { } else {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment