Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 22446d3f authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull ACPI and power management fixes from Rafael Wysocki:
 "These include a fix for a recent ACPI hotplug regression, four
  concurrency related fixes and one PCI device removal fix for
  ACPI-based PCI hotplug (ACPIPHP), intel_pstate fix that should go into
  stable, three simple ACPI cleanups and a new entry for the ACPI video
  blacklist.

  Specifics:

   - Fix for a recent ACPI hotplug regression causing a NULL pointer
     dereference to occur while handling ACPI eject notifications for
     already ejected devices.  From Toshi Kani.

   - Four concurrency-related fixes for ACPIPHP.  Two of them add
     missing locking and the other two fix race conditions related to
     reference counting.

   - ACPIPHP fix to avoid NULL pointer dereferences during device
     removal involving Virtual Funcions.

   - intel_pstate fix to make it compute the percentage of time the CPU
     is busy properly.  From Dirk Brandewie.

   - Removal of two unnecessary NULL pointer checks in ACPI code and a
     fix for sscanf() format string from Dan Carpenter and Luis G.F.

   - New ACPI video blacklist entry for HP EliteBook Revolve 810 from
     Mika Westerberg"

* tag 'pm+acpi-3.14-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
  ACPI / hotplug: Fix panic on eject to ejected device
  ACPI / battery: Fix incorrect sscanf() string in acpi_battery_init_alarm()
  ACPI / proc: remove unneeded NULL check
  ACPI / utils: remove a pointless NULL check
  ACPI / video: Add HP EliteBook Revolve 810 to the blacklist
  intel_pstate: Take core C0 time into account for core busy calculation
  ACPI / hotplug / PCI: Fix bridge removal race vs dock events
  ACPI / hotplug / PCI: Fix bridge removal race in handle_hotplug_event()
  ACPI / hotplug / PCI: Scan root bus under the PCI rescan-remove lock
  ACPI / hotplug / PCI: Move PCI rescan-remove locking to hotplug_event()
  ACPI / hotplug / PCI: Remove entries from bus->devices in reverse order
parents 9343224b a2ff34c4
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -549,7 +549,7 @@ static ssize_t acpi_battery_alarm_store(struct device *dev,
{
	unsigned long x;
	struct acpi_battery *battery = to_acpi_battery(dev_get_drvdata(dev));
	if (sscanf(buf, "%ld\n", &x) == 1)
	if (sscanf(buf, "%lu\n", &x) == 1)
		battery->alarm = x/1000;
	if (acpi_battery_present(battery))
		acpi_battery_set_alarm(battery);
+1 −1
Original line number Diff line number Diff line
@@ -60,7 +60,7 @@ acpi_system_wakeup_device_seq_show(struct seq_file *seq, void *offset)
				seq_printf(seq, "%c%-8s  %s:%s\n",
					dev->wakeup.flags.run_wake ? '*' : ' ',
					(device_may_wakeup(&dev->dev) ||
					(ldev && device_may_wakeup(ldev))) ?
					device_may_wakeup(ldev)) ?
					"enabled" : "disabled",
					ldev->bus ? ldev->bus->name :
					"no-bus", dev_name(ldev));
+4 −2
Original line number Diff line number Diff line
@@ -484,7 +484,6 @@ static void acpi_device_hotplug(void *data, u32 src)
static void acpi_hotplug_notify_cb(acpi_handle handle, u32 type, void *data)
{
	u32 ost_code = ACPI_OST_SC_NON_SPECIFIC_FAILURE;
	struct acpi_scan_handler *handler = data;
	struct acpi_device *adev;
	acpi_status status;

@@ -500,7 +499,10 @@ static void acpi_hotplug_notify_cb(acpi_handle handle, u32 type, void *data)
		break;
	case ACPI_NOTIFY_EJECT_REQUEST:
		acpi_handle_debug(handle, "ACPI_NOTIFY_EJECT_REQUEST event\n");
		if (!handler->hotplug.enabled) {
		if (!adev->handler)
			goto err_out;

		if (!adev->handler->hotplug.enabled) {
			acpi_handle_err(handle, "Eject disabled\n");
			ost_code = ACPI_OST_SC_EJECT_NOT_SUPPORTED;
			goto err_out;
+0 −4
Original line number Diff line number Diff line
@@ -99,10 +99,6 @@ acpi_extract_package(union acpi_object *package,

		union acpi_object *element = &(package->package.elements[i]);

		if (!element) {
			return AE_BAD_DATA;
		}

		switch (element->type) {

		case ACPI_TYPE_INTEGER:
+8 −0
Original line number Diff line number Diff line
@@ -170,6 +170,14 @@ static struct dmi_system_id video_detect_dmi_table[] = {
	},
	{
	.callback = video_detect_force_vendor,
	.ident = "HP EliteBook Revolve 810",
	.matches = {
		DMI_MATCH(DMI_SYS_VENDOR, "Hewlett-Packard"),
		DMI_MATCH(DMI_PRODUCT_NAME, "HP EliteBook Revolve 810 G1"),
		},
	},
	{
	.callback = video_detect_force_vendor,
	.ident = "Lenovo Yoga 13",
	.matches = {
		DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
Loading