VisionFive2 Linux kernel

StarFive Tech Linux Kernel for VisionFive (JH7110) boards (mirror)

More than 9999 Commits   33 Branches   57 Tags
b24413180f560 (Greg Kroah-Hartman 2017-11-01 15:07:57 +0100   1) /* SPDX-License-Identifier: GPL-2.0 */
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200   2) #ifndef LINUX_BCMA_PRIVATE_H_
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200   3) #define LINUX_BCMA_PRIVATE_H_
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200   4) 
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200   5) #ifndef pr_fmt
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200   6) #define pr_fmt(fmt)		KBUILD_MODNAME ": " fmt
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200   7) #endif
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200   8) 
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200   9) #include <linux/bcma/bcma.h>
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200  10) #include <linux/delay.h>
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200  11) 
3d9d8af330a89 (Rafał Miłecki      2012-07-05 22:07:32 +0200  12) #define bcma_err(bus, fmt, ...) \
777bc4801a686 (Rafał Miłecki      2019-01-02 00:00:02 +0100  13) 	dev_err((bus)->dev, "bus%d: " fmt, (bus)->num, ##__VA_ARGS__)
3d9d8af330a89 (Rafał Miłecki      2012-07-05 22:07:32 +0200  14) #define bcma_warn(bus, fmt, ...) \
777bc4801a686 (Rafał Miłecki      2019-01-02 00:00:02 +0100  15) 	dev_warn((bus)->dev, "bus%d: " fmt, (bus)->num, ##__VA_ARGS__)
3d9d8af330a89 (Rafał Miłecki      2012-07-05 22:07:32 +0200  16) #define bcma_info(bus, fmt, ...) \
777bc4801a686 (Rafał Miłecki      2019-01-02 00:00:02 +0100  17) 	dev_info((bus)->dev, "bus%d: " fmt, (bus)->num, ##__VA_ARGS__)
3d9d8af330a89 (Rafał Miłecki      2012-07-05 22:07:32 +0200  18) #define bcma_debug(bus, fmt, ...) \
777bc4801a686 (Rafał Miłecki      2019-01-02 00:00:02 +0100  19) 	dev_dbg((bus)->dev, "bus%d: " fmt, (bus)->num, ##__VA_ARGS__)
3d9d8af330a89 (Rafał Miłecki      2012-07-05 22:07:32 +0200  20) 
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200  21) struct bcma_bus;
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200  22) 
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200  23) /* main.c */
88f9b65d44479 (Rafał Miłecki      2013-06-26 10:02:11 +0200  24) bool bcma_wait_value(struct bcma_device *core, u16 reg, u32 mask, u32 value,
88f9b65d44479 (Rafał Miłecki      2013-06-26 10:02:11 +0200  25) 		     int timeout);
ab54bc8460b57 (Rafał Miłecki      2014-10-03 17:00:24 +0200  26) void bcma_prepare_core(struct bcma_bus *bus, struct bcma_device *core);
799038ea9bbbf (Rafał Miłecki      2015-01-16 20:59:39 +0100  27) void bcma_init_bus(struct bcma_bus *bus);
9b6cc9a807c79 (Rafał Miłecki      2015-02-08 17:11:50 +0100  28) void bcma_unregister_cores(struct bcma_bus *bus);
0f58a01ddd5e8 (Greg Kroah-Hartman 2012-12-21 15:12:59 -0800  29) int bcma_bus_register(struct bcma_bus *bus);
440ca98fe8407 (Rafał Miłecki      2011-06-18 01:01:59 +0200  30) void bcma_bus_unregister(struct bcma_bus *bus);
c5ed1df781cb5 (Rafał Miłecki      2015-01-19 08:30:30 +0100  31) int __init bcma_bus_early_register(struct bcma_bus *bus);
775ab52142b02 (Rafał Miłecki      2011-12-09 22:16:07 +0100  32) #ifdef CONFIG_PM
685a4ef0df23b (Linus Torvalds     2012-01-13 23:58:40 +0100  33) int bcma_bus_suspend(struct bcma_bus *bus);
775ab52142b02 (Rafał Miłecki      2011-12-09 22:16:07 +0100  34) int bcma_bus_resume(struct bcma_bus *bus);
775ab52142b02 (Rafał Miłecki      2011-12-09 22:16:07 +0100  35) #endif
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200  36) 
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200  37) /* scan.c */
799038ea9bbbf (Rafał Miłecki      2015-01-16 20:59:39 +0100  38) void bcma_detect_chip(struct bcma_bus *bus);
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200  39) int bcma_bus_scan(struct bcma_bus *bus);
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200  40) 
27f18dc2dafe6 (Rafał Miłecki      2011-06-02 02:08:51 +0200  41) /* sprom.c */
27f18dc2dafe6 (Rafał Miłecki      2011-06-02 02:08:51 +0200  42) int bcma_sprom_get(struct bcma_bus *bus);
27f18dc2dafe6 (Rafał Miłecki      2011-06-02 02:08:51 +0200  43) 
e3afe0e5be757 (Hauke Mehrtens     2011-07-23 01:20:10 +0200  44) /* driver_chipcommon.c */
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100  45) void bcma_core_chipcommon_early_init(struct bcma_drv_cc *cc);
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100  46) void bcma_core_chipcommon_init(struct bcma_drv_cc *cc);
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100  47) void bcma_chipco_bcm4331_ext_pa_lines_ctl(struct bcma_drv_cc *cc, bool enable);
7195439d1d71b (Rafał Miłecki      2017-01-13 12:23:35 +0100  48) #ifdef CONFIG_BCMA_DRIVER_MIPS
7195439d1d71b (Rafał Miłecki      2017-01-13 12:23:35 +0100  49) void bcma_chipco_serial_init(struct bcma_drv_cc *cc);
7195439d1d71b (Rafał Miłecki      2017-01-13 12:23:35 +0100  50) #endif /* CONFIG_BCMA_DRIVER_MIPS */
e3afe0e5be757 (Hauke Mehrtens     2011-07-23 01:20:10 +0200  51) 
1716bcf3f76fe (Hauke Mehrtens     2014-09-08 22:53:36 +0200  52) /* driver_chipcommon_b.c */
1716bcf3f76fe (Hauke Mehrtens     2014-09-08 22:53:36 +0200  53) int bcma_core_chipcommon_b_init(struct bcma_drv_cc_b *ccb);
1716bcf3f76fe (Hauke Mehrtens     2014-09-08 22:53:36 +0200  54) void bcma_core_chipcommon_b_free(struct bcma_drv_cc_b *ccb);
1716bcf3f76fe (Hauke Mehrtens     2014-09-08 22:53:36 +0200  55) 
e3afe0e5be757 (Hauke Mehrtens     2011-07-23 01:20:10 +0200  56) /* driver_chipcommon_pmu.c */
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100  57) void bcma_pmu_early_init(struct bcma_drv_cc *cc);
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100  58) void bcma_pmu_init(struct bcma_drv_cc *cc);
5b5ac41447de3 (Rafał Miłecki      2012-12-07 12:56:56 +0100  59) u32 bcma_pmu_get_alp_clock(struct bcma_drv_cc *cc);
5b5ac41447de3 (Rafał Miłecki      2012-12-07 12:56:56 +0100  60) u32 bcma_pmu_get_cpu_clock(struct bcma_drv_cc *cc);
e3afe0e5be757 (Hauke Mehrtens     2011-07-23 01:20:10 +0200  61) 
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  62) /**************************************************
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  63)  * driver_chipcommon_sflash.c
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  64)  **************************************************/
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  65) 
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  66) #ifdef CONFIG_BCMA_PFLASH
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  67) extern struct platform_device bcma_pflash_dev;
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  68) int bcma_pflash_init(struct bcma_drv_cc *cc);
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  69) #else
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  70) static inline int bcma_pflash_init(struct bcma_drv_cc *cc)
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  71) {
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  72) 	bcma_err(cc->core->bus, "Parallel flash not supported\n");
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  73) 	return 0;
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  74) }
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  75) #endif /* CONFIG_BCMA_PFLASH */
d6a3b51ada68c (Rafał Miłecki      2016-02-12 10:15:44 +0100  76) 
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  77) #ifdef CONFIG_BCMA_SFLASH
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  78) /* driver_chipcommon_sflash.c */
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  79) int bcma_sflash_init(struct bcma_drv_cc *cc);
d57ef3a6a2eeb (Rafał Miłecki      2012-08-10 21:23:53 +0200  80) extern struct platform_device bcma_sflash_dev;
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  81) #else
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  82) static inline int bcma_sflash_init(struct bcma_drv_cc *cc)
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  83) {
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  84) 	bcma_err(cc->core->bus, "Serial flash not supported\n");
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  85) 	return 0;
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  86) }
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  87) #endif /* CONFIG_BCMA_SFLASH */
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  88) 
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  89) #ifdef CONFIG_BCMA_NFLASH
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  90) /* driver_chipcommon_nflash.c */
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  91) int bcma_nflash_init(struct bcma_drv_cc *cc);
371a00448f95a (Rafał Miłecki      2012-08-12 13:08:05 +0200  92) extern struct platform_device bcma_nflash_dev;
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  93) #else
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  94) static inline int bcma_nflash_init(struct bcma_drv_cc *cc)
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  95) {
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  96) 	bcma_err(cc->core->bus, "NAND flash not supported\n");
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  97) 	return 0;
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  98) }
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200  99) #endif /* CONFIG_BCMA_NFLASH */
23cb3b2121323 (Rafał Miłecki      2012-07-17 16:26:41 +0200 100) 
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200 101) #ifdef CONFIG_BCMA_HOST_PCI
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200 102) /* host_pci.c */
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200 103) extern int __init bcma_host_pci_init(void);
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200 104) extern void __exit bcma_host_pci_exit(void);
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200 105) #endif /* CONFIG_BCMA_HOST_PCI */
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200 106) 
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 107) /* host_soc.c */
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 108) #if defined(CONFIG_BCMA_HOST_SOC) && defined(CONFIG_OF)
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 109) extern int __init bcma_host_soc_register_driver(void);
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 110) extern void __exit bcma_host_soc_unregister_driver(void);
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 111) #else
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 112) static inline int __init bcma_host_soc_register_driver(void)
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 113) {
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 114) 	return 0;
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 115) }
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 116) static inline void __exit bcma_host_soc_unregister_driver(void)
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 117) {
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 118) }
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 119) #endif /* CONFIG_BCMA_HOST_SOC && CONFIG_OF */
2101e533f41a9 (Hauke Mehrtens     2014-09-26 00:09:19 +0200 120) 
4b259a5cc5ea9 (Hauke Mehrtens     2012-01-31 00:03:33 +0100 121) /* driver_pci.c */
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 122) #ifdef CONFIG_BCMA_DRIVER_PCI
4b259a5cc5ea9 (Hauke Mehrtens     2012-01-31 00:03:33 +0100 123) u32 bcma_pcie_read(struct bcma_drv_pci *pc, u32 address);
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 124) void bcma_core_pci_early_init(struct bcma_drv_pci *pc);
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 125) void bcma_core_pci_init(struct bcma_drv_pci *pc);
4186721d02b71 (Rafał Miłecki      2015-02-08 17:11:47 +0100 126) void bcma_core_pci_up(struct bcma_drv_pci *pc);
4186721d02b71 (Rafał Miłecki      2015-02-08 17:11:47 +0100 127) void bcma_core_pci_down(struct bcma_drv_pci *pc);
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 128) #else
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 129) static inline void bcma_core_pci_early_init(struct bcma_drv_pci *pc)
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 130) {
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 131) 	WARN_ON(pc->core->bus->hosttype == BCMA_HOSTTYPE_PCI);
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 132) }
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 133) static inline void bcma_core_pci_init(struct bcma_drv_pci *pc)
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 134) {
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 135) 	/* Initialization is required for PCI hosted bus */
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 136) 	WARN_ON(pc->core->bus->hosttype == BCMA_HOSTTYPE_PCI);
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 137) }
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 138) #endif
4b259a5cc5ea9 (Hauke Mehrtens     2012-01-31 00:03:33 +0100 139) 
804e27dee49e2 (Rafał Miłecki      2015-02-08 17:11:49 +0100 140) /* driver_pcie2.c */
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 141) #ifdef CONFIG_BCMA_DRIVER_PCI
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 142) void bcma_core_pcie2_init(struct bcma_drv_pcie2 *pcie2);
804e27dee49e2 (Rafał Miłecki      2015-02-08 17:11:49 +0100 143) void bcma_core_pcie2_up(struct bcma_drv_pcie2 *pcie2);
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 144) #else
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 145) static inline void bcma_core_pcie2_init(struct bcma_drv_pcie2 *pcie2)
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 146) {
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 147) 	/* Initialization is required for PCI hosted bus */
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 148) 	WARN_ON(pcie2->core->bus->hosttype == BCMA_HOSTTYPE_PCI);
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 149) }
982a40f5c0bb0 (Rafał Miłecki      2015-03-05 18:25:11 +0100 150) #endif
804e27dee49e2 (Rafał Miłecki      2015-02-08 17:11:49 +0100 151) 
a4855f39d4eb3 (Hauke Mehrtens     2012-12-05 18:46:02 +0100 152) extern int bcma_chipco_watchdog_register(struct bcma_drv_cc *cc);
a4855f39d4eb3 (Hauke Mehrtens     2012-12-05 18:46:02 +0100 153) 
9352f69c9194f (Rafał Miłecki      2011-07-05 19:48:26 +0200 154) #ifdef CONFIG_BCMA_DRIVER_PCI_HOSTMODE
0f58a01ddd5e8 (Greg Kroah-Hartman 2012-12-21 15:12:59 -0800 155) bool bcma_core_pci_is_in_hostmode(struct bcma_drv_pci *pc);
0f58a01ddd5e8 (Greg Kroah-Hartman 2012-12-21 15:12:59 -0800 156) void bcma_core_pci_hostmode_init(struct bcma_drv_pci *pc);
ae8ce289e55e6 (Rafał Miłecki      2015-01-25 14:02:48 +0100 157) #else
ae8ce289e55e6 (Rafał Miłecki      2015-01-25 14:02:48 +0100 158) static inline bool bcma_core_pci_is_in_hostmode(struct bcma_drv_pci *pc)
ae8ce289e55e6 (Rafał Miłecki      2015-01-25 14:02:48 +0100 159) {
ae8ce289e55e6 (Rafał Miłecki      2015-01-25 14:02:48 +0100 160) 	return false;
ae8ce289e55e6 (Rafał Miłecki      2015-01-25 14:02:48 +0100 161) }
ae8ce289e55e6 (Rafał Miłecki      2015-01-25 14:02:48 +0100 162) static inline void bcma_core_pci_hostmode_init(struct bcma_drv_pci *pc)
ae8ce289e55e6 (Rafał Miłecki      2015-01-25 14:02:48 +0100 163) {
ae8ce289e55e6 (Rafał Miłecki      2015-01-25 14:02:48 +0100 164) }
9352f69c9194f (Rafał Miłecki      2011-07-05 19:48:26 +0200 165) #endif /* CONFIG_BCMA_DRIVER_PCI_HOSTMODE */
9352f69c9194f (Rafał Miłecki      2011-07-05 19:48:26 +0200 166) 
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 167) /**************************************************
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 168)  * driver_mips.c
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 169)  **************************************************/
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 170) 
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 171) #ifdef CONFIG_BCMA_DRIVER_MIPS
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 172) unsigned int bcma_core_mips_irq(struct bcma_device *dev);
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 173) void bcma_core_mips_early_init(struct bcma_drv_mips *mcore);
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 174) void bcma_core_mips_init(struct bcma_drv_mips *mcore);
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 175) #else
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 176) static inline unsigned int bcma_core_mips_irq(struct bcma_device *dev)
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 177) {
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 178) 	return 0;
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 179) }
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 180) static inline void bcma_core_mips_early_init(struct bcma_drv_mips *mcore)
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 181) {
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 182) }
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 183) static inline void bcma_core_mips_init(struct bcma_drv_mips *mcore)
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 184) {
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 185) }
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 186) #endif
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 187) 
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 188) /**************************************************
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 189)  * driver_gmac_cmn.c
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 190)  **************************************************/
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 191) 
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 192) #ifdef CONFIG_BCMA_DRIVER_GMAC_CMN
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 193) void bcma_core_gmac_cmn_init(struct bcma_drv_gmac_cmn *gc);
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 194) #else
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 195) static inline void bcma_core_gmac_cmn_init(struct bcma_drv_gmac_cmn *gc)
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 196) {
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 197) }
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 198) #endif
0a4e699a41f76 (Rafał Miłecki      2015-03-04 14:24:52 +0100 199) 
cf0936b06d8e9 (Hauke Mehrtens     2012-11-20 22:24:30 +0000 200) #ifdef CONFIG_BCMA_DRIVER_GPIO
cf0936b06d8e9 (Hauke Mehrtens     2012-11-20 22:24:30 +0000 201) /* driver_gpio.c */
cf0936b06d8e9 (Hauke Mehrtens     2012-11-20 22:24:30 +0000 202) int bcma_gpio_init(struct bcma_drv_cc *cc);
c50ae9470e542 (Hauke Mehrtens     2013-02-03 23:25:33 +0100 203) int bcma_gpio_unregister(struct bcma_drv_cc *cc);
cf0936b06d8e9 (Hauke Mehrtens     2012-11-20 22:24:30 +0000 204) #else
cf0936b06d8e9 (Hauke Mehrtens     2012-11-20 22:24:30 +0000 205) static inline int bcma_gpio_init(struct bcma_drv_cc *cc)
cf0936b06d8e9 (Hauke Mehrtens     2012-11-20 22:24:30 +0000 206) {
cf0936b06d8e9 (Hauke Mehrtens     2012-11-20 22:24:30 +0000 207) 	return -ENOTSUPP;
cf0936b06d8e9 (Hauke Mehrtens     2012-11-20 22:24:30 +0000 208) }
c50ae9470e542 (Hauke Mehrtens     2013-02-03 23:25:33 +0100 209) static inline int bcma_gpio_unregister(struct bcma_drv_cc *cc)
c50ae9470e542 (Hauke Mehrtens     2013-02-03 23:25:33 +0100 210) {
c50ae9470e542 (Hauke Mehrtens     2013-02-03 23:25:33 +0100 211) 	return 0;
c50ae9470e542 (Hauke Mehrtens     2013-02-03 23:25:33 +0100 212) }
cf0936b06d8e9 (Hauke Mehrtens     2012-11-20 22:24:30 +0000 213) #endif /* CONFIG_BCMA_DRIVER_GPIO */
cf0936b06d8e9 (Hauke Mehrtens     2012-11-20 22:24:30 +0000 214) 
8369ae33b7052 (Rafał Miłecki      2011-05-09 18:56:46 +0200 215) #endif