From f37c30ef40f248fe88fc995a4571ddfbffd17b09 Mon Sep 17 00:00:00 2001 From: Dan Duval Date: Sun, 22 May 2016 11:35:04 -0400 Subject: [PATCH] fix kABI breakage from pci_dev changes Orabug: 23331203 Orabug: 23331203 Commit bb44fa317be6c1dd0650feaae3326ac11f2d37a4 ("PCI: Add dev->has_secondary_link to track downstream PCIe links") and commit 0af1534fb7b3dba6e11d6c2670912725a2087217 ("PCI: Disable IO/MEM decoding for devices with non-compliant BARs") added one-bit flags to the pci_dev structure. Technically, this broke kABI (according to the checker, anyway). In reality, these bits were added after a bunch of other one-bit fields, the result being that their addition didn't extend the size of the structure, nor did it change the offsets of any existing fields of the structure. This commit simply wraps these two fields in "#ifndef __GENKSYMS__" to hide them from the checker. Signed-off-by: Dan Duval (cherry picked from commit 32594c00fba3c410b5a339f2ddd0e4c583170186) Signed-off-by: Dan Duval --- include/linux/pci.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/linux/pci.h b/include/linux/pci.h index 109ccee9e3e6..518f0888f917 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -357,8 +357,10 @@ struct pci_dev { unsigned int broken_intx_masking:1; unsigned int io_window_1k:1; /* Intel P2P bridge 1K I/O windows */ unsigned int irq_managed:1; +#ifndef __GENKSYMS__ unsigned int has_secondary_link:1; unsigned int non_compliant_bars:1; /* broken BARs; ignore them */ +#endif pci_dev_flags_t dev_flags; atomic_t enable_cnt; /* pci_enable_device has been called */ -- 2.50.1