ACPI / scan: Follow priorities of IDs when matching scan handlers

The IDs of ACPI device nodes stored in their pnp.ids member arrays
are sorted by decreasing priority (i.e. the highest-priority ID is
the first entry).  This means that when matching scan handlers to
device nodes, the namespace scanning code should walk the list of
scan handlers for each device node ID instead of walking the list
of device node IDs for each handler (the latter causes the first
handler matching any of the device node IDs to be chosen, although
there may be another handler matching an ID of a higher priority
which should be preferred).  Make the code follow this observation.

This change has been suggested and justified by Toshi Kani.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPI / PCI: avoid building pci_slot as module

As discussed in thread at https://patchwork.kernel.org/patch/1946851/,
there's no value in supporting CONFIG_ACPI_PCI_SLOT=m any more.
So change Kconfig and code to only support building pci_slot as
built-in driver.

References: https://patchwork.kernel.org/patch/1946851/
Signed-off-by: Jiang Liu <jiang.liu@huawei.com>
Acked-by: Bjorn Helgaas <bhelgaas@google.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPI / PCI: pci_slot: replace printk(KERN_xxx) with pr_xxx()

Trivial changes to replace printk(KERN_xxx) with pr_xxx().

Signed-off-by: Jiang Liu <jiang.liu@huawei.com>
Acked-by: Bjorn Helgaas <bhelgaas@google.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPI / PM: Handle missing _PSC in acpi_bus_update_power()

If _PS0 is defined for an ACPI device node, but _PSC isn't and
the device node doesn't use power resources for power management,
acpi_bus_update_power() will fail to update the power state of it,
because acpi_device_get_power() returns ACPI_STATE_UNKNOWN in that
case.

To handle that situation make acpi_bus_update_power() follow
acpi_bus_init_power() and try to force the given device node into
power state D0.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Merge branch 'acpi-pm-next' into linux-next

* acpi-pm-next:
  ACPI / PM: Handle missing _PSC in acpi_bus_update_power()
Merge branch 'acpi-cleanup-next' into linux-next

* acpi-cleanup-next:
  ACPI / PCI: pci_slot: replace printk(KERN_xxx) with pr_xxx()
  ACPI / PCI: avoid building pci_slot as module
  ACPI / scan: Follow priorities of IDs when matching scan handlers