diff options
Diffstat (limited to 'drivers/net/ethernet/stmicro/stmmac/stmmac.h')
-rw-r--r-- | drivers/net/ethernet/stmicro/stmmac/stmmac.h | 61 |
1 files changed, 0 insertions, 61 deletions
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac.h b/drivers/net/ethernet/stmicro/stmmac/stmmac.h index bd75ee8b2757..c0a391983372 100644 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac.h +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac.h | |||
@@ -134,65 +134,4 @@ struct stmmac_priv *stmmac_dvr_probe(struct device *device, | |||
134 | void stmmac_disable_eee_mode(struct stmmac_priv *priv); | 134 | void stmmac_disable_eee_mode(struct stmmac_priv *priv); |
135 | bool stmmac_eee_init(struct stmmac_priv *priv); | 135 | bool stmmac_eee_init(struct stmmac_priv *priv); |
136 | 136 | ||
137 | #ifdef CONFIG_STMMAC_PLATFORM | ||
138 | extern struct platform_driver stmmac_pltfr_driver; | ||
139 | |||
140 | static inline int stmmac_register_platform(void) | ||
141 | { | ||
142 | int err; | ||
143 | |||
144 | err = platform_driver_register(&stmmac_pltfr_driver); | ||
145 | if (err) | ||
146 | pr_err("stmmac: failed to register the platform driver\n"); | ||
147 | |||
148 | return err; | ||
149 | } | ||
150 | |||
151 | static inline void stmmac_unregister_platform(void) | ||
152 | { | ||
153 | platform_driver_unregister(&stmmac_pltfr_driver); | ||
154 | } | ||
155 | #else | ||
156 | static inline int stmmac_register_platform(void) | ||
157 | { | ||
158 | pr_debug("stmmac: do not register the platf driver\n"); | ||
159 | |||
160 | return 0; | ||
161 | } | ||
162 | |||
163 | static inline void stmmac_unregister_platform(void) | ||
164 | { | ||
165 | } | ||
166 | #endif /* CONFIG_STMMAC_PLATFORM */ | ||
167 | |||
168 | #ifdef CONFIG_STMMAC_PCI | ||
169 | extern struct pci_driver stmmac_pci_driver; | ||
170 | static inline int stmmac_register_pci(void) | ||
171 | { | ||
172 | int err; | ||
173 | |||
174 | err = pci_register_driver(&stmmac_pci_driver); | ||
175 | if (err) | ||
176 | pr_err("stmmac: failed to register the PCI driver\n"); | ||
177 | |||
178 | return err; | ||
179 | } | ||
180 | |||
181 | static inline void stmmac_unregister_pci(void) | ||
182 | { | ||
183 | pci_unregister_driver(&stmmac_pci_driver); | ||
184 | } | ||
185 | #else | ||
186 | static inline int stmmac_register_pci(void) | ||
187 | { | ||
188 | pr_debug("stmmac: do not register the PCI driver\n"); | ||
189 | |||
190 | return 0; | ||
191 | } | ||
192 | |||
193 | static inline void stmmac_unregister_pci(void) | ||
194 | { | ||
195 | } | ||
196 | #endif /* CONFIG_STMMAC_PCI */ | ||
197 | |||
198 | #endif /* __STMMAC_H__ */ | 137 | #endif /* __STMMAC_H__ */ |