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

Commit 1248d636 authored by Kristen Accardi's avatar Kristen Accardi Committed by Greg Kroah-Hartman
Browse files

[PATCH] PCI Hotplug: use bus_slot number for name



For systems with multiple hotplug controllers, you need to use more than
just the slot number to uniquely name the slot.  Without a unique slot
name, the pci_hp_register() will fail.  This patch adds the bus number
to the name.

Signed-off-by: default avatarKristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 346d3882
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -302,7 +302,7 @@ static inline void return_resource(struct pci_resource **head, struct pci_resour

static inline void make_slot_name(char *buffer, int buffer_size, struct slot *slot)
{
	snprintf(buffer, buffer_size, "%d", slot->number);
	snprintf(buffer, buffer_size, "%04d_%04d", slot->bus, slot->number);
}

enum php_ctlr_type {
+1 −1
Original line number Diff line number Diff line
@@ -411,7 +411,7 @@ static inline void return_resource(struct pci_resource **head, struct pci_resour

static inline void make_slot_name(char *buffer, int buffer_size, struct slot *slot)
{
	snprintf(buffer, buffer_size, "%d", slot->number);
	snprintf(buffer, buffer_size, "%04d_%04d", slot->bus, slot->number);
}

enum php_ctlr_type {