MIPS: ath79: add a common PCI registration function
The current code unconditionally registers the AR724X specific PCI controller, even if the kernel is running on a different SoC. Add a common function for PCI controller registration, and only register the AR724X PCI controller if the kernel is running on an AR724X SoC. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/3488/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
This commit is contained in:

committed by
Ralf Baechle

parent
659243ccaf
commit
6335aef59c
@@ -18,4 +18,10 @@ struct ath724x_pci_data {
|
||||
|
||||
void ath724x_pci_add_data(struct ath724x_pci_data *data, int size);
|
||||
|
||||
#ifdef CONFIG_PCI
|
||||
int ath79_register_pci(void);
|
||||
#else
|
||||
static inline int ath79_register_pci(void) { return 0; }
|
||||
#endif
|
||||
|
||||
#endif /* __ASM_MACH_ATH79_PCI_ATH724X_H */
|
||||
|
Reference in New Issue
Block a user