PCI: Omit PCI ID macro strings to shorten quirk names
authorMichal Marek <mmarek@suse.cz>
Mon, 11 Nov 2013 13:40:35 +0000 (14:40 +0100)
committerBjorn Helgaas <bhelgaas@google.com>
Mon, 25 Nov 2013 22:10:54 +0000 (15:10 -0700)
commitecf61c78bd787b9dfb4a6b1dfb7561c2a95c5c17
tree87a8bb938cb53c314cd1e208f2ff41cb0c4796bf
parent4bff6749905d3abe7436d3b2d20b626886a04475
PCI: Omit PCI ID macro strings to shorten quirk names

Pasting the verbatim PCI_(VENDOR|DEVICE)_* macros in the __pci_fixup_*
symbol names results in insanely long names such as

__pci_fixup_resumePCI_VENDOR_ID_SERVERWORKSPCI_DEVICE_ID_SERVERWORKS_HT1000SBquirk_disable_broadcom_boot_interrupt

When Link-Time Optimization adds its numeric suffix to such symbol, it
overflows the namebuf[KSYM_NAME_LEN] array in kernel/kallsyms.c.  Use the
line number instead to create (nearly) unique symbol names.

Reported-by: Joe Mario <jmario@redhat.com>
Signed-off-by: Michal Marek <mmarek@suse.cz>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Cc: Andi Kleen <ak@linux.intel.com>
include/linux/pci.h