diff options
author | Bjorn Helgaas <bhelgaas@google.com> | 2012-02-23 22:18:56 -0500 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2012-02-23 22:18:56 -0500 |
commit | dcce6dc486816d5e1a14e066f611100624421e3a (patch) | |
tree | 2fbe70a5483c0977da4a11cdea13a053fe88fc98 /include/asm-generic | |
parent | 47087700ce3ccb2bf69f4dcb6ad7f59764e51308 (diff) |
PCI: add pci_clear_flags()
Add a pci_clear_flags() for cases when we statically initialize
pci_flags, then decide to clear things out later.
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'include/asm-generic')
-rw-r--r-- | include/asm-generic/pci-bridge.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/asm-generic/pci-bridge.h b/include/asm-generic/pci-bridge.h index 4a5aca2a2c94..a5b5d5a89a4f 100644 --- a/include/asm-generic/pci-bridge.h +++ b/include/asm-generic/pci-bridge.h | |||
@@ -45,6 +45,11 @@ static inline void pci_add_flags(int flags) | |||
45 | pci_flags |= flags; | 45 | pci_flags |= flags; |
46 | } | 46 | } |
47 | 47 | ||
48 | static inline void pci_clear_flags(int flags) | ||
49 | { | ||
50 | pci_flags &= ~flags; | ||
51 | } | ||
52 | |||
48 | static inline int pci_has_flag(int flag) | 53 | static inline int pci_has_flag(int flag) |
49 | { | 54 | { |
50 | return pci_flags & flag; | 55 | return pci_flags & flag; |
@@ -52,6 +57,7 @@ static inline int pci_has_flag(int flag) | |||
52 | #else | 57 | #else |
53 | static inline void pci_set_flags(int flags) { } | 58 | static inline void pci_set_flags(int flags) { } |
54 | static inline void pci_add_flags(int flags) { } | 59 | static inline void pci_add_flags(int flags) { } |
60 | static inline void pci_clear_flags(int flags) { } | ||
55 | static inline int pci_has_flag(int flag) | 61 | static inline int pci_has_flag(int flag) |
56 | { | 62 | { |
57 | return 0; | 63 | return 0; |