]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
ACPI / hotplug / PCI: Hotplug context objects for bridges and functions
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Sat, 13 Jul 2013 21:27:24 +0000 (23:27 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Tue, 23 Jul 2013 02:00:20 +0000 (04:00 +0200)
commitcb7b8cedf6c88b9d1d08e0565e8da52180921071
tree8be6732fd4b1bc84a2bf1f4f3f24bad5d6486025
parent2e862c51904ddd12be2d256513160e1f87beafee
ACPI / hotplug / PCI: Hotplug context objects for bridges and functions

When either a new hotplug bridge or a new hotplug function is added
by the ACPI-based PCI hotplug (ACPIPHP) code, attach a context object
to its ACPI handle to store hotplug-related information in it.  To
start with, put the handle's bridge and function pointers into that
object.  Count references to the context objects and drop them when
they are not needed any more.

First of all, this makes it possible to find out if the given bridge
has been registered as a function already in a much more
straightforward way and acpiphp_bridge_handle_to_function() can be
dropped (Yay!).

This also will allow some more simplifications to be made going
forward.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Tested-by: Mika Westerberg <mika.westerberg@linux.intel.com>
drivers/pci/hotplug/acpiphp.h
drivers/pci/hotplug/acpiphp_glue.c