File tree Expand file tree Collapse file tree 3 files changed +23
-3
lines changed Expand file tree Collapse file tree 3 files changed +23
-3
lines changed Original file line number Diff line number Diff line change @@ -1024,7 +1024,18 @@ static struct platform_driver ci_hdrc_driver = {
1024
1024
},
1025
1025
};
1026
1026
1027
- module_platform_driver (ci_hdrc_driver );
1027
+ static int __init ci_hdrc_platform_register (void )
1028
+ {
1029
+ ci_hdrc_host_driver_init ();
1030
+ return platform_driver_register (& ci_hdrc_driver );
1031
+ }
1032
+ module_init (ci_hdrc_platform_register );
1033
+
1034
+ static void __exit ci_hdrc_platform_unregister (void )
1035
+ {
1036
+ platform_driver_unregister (& ci_hdrc_driver );
1037
+ }
1038
+ module_exit (ci_hdrc_platform_unregister );
1028
1039
1029
1040
MODULE_ALIAS ("platform:ci_hdrc" );
1030
1041
MODULE_LICENSE ("GPL v2" );
Original file line number Diff line number Diff line change @@ -237,9 +237,12 @@ int ci_hdrc_host_init(struct ci_hdrc *ci)
237
237
rdrv -> name = "host" ;
238
238
ci -> roles [CI_ROLE_HOST ] = rdrv ;
239
239
240
+ return 0 ;
241
+ }
242
+
243
+ void ci_hdrc_host_driver_init (void )
244
+ {
240
245
ehci_init_driver (& ci_ehci_hc_driver , & ehci_ci_overrides );
241
246
orig_bus_suspend = ci_ehci_hc_driver .bus_suspend ;
242
247
ci_ehci_hc_driver .bus_suspend = ci_ehci_bus_suspend ;
243
-
244
- return 0 ;
245
248
}
Original file line number Diff line number Diff line change 5
5
6
6
int ci_hdrc_host_init (struct ci_hdrc * ci );
7
7
void ci_hdrc_host_destroy (struct ci_hdrc * ci );
8
+ void ci_hdrc_host_driver_init (void );
8
9
9
10
#else
10
11
@@ -18,6 +19,11 @@ static inline void ci_hdrc_host_destroy(struct ci_hdrc *ci)
18
19
19
20
}
20
21
22
+ static void ci_hdrc_host_driver_init (void )
23
+ {
24
+
25
+ }
26
+
21
27
#endif
22
28
23
29
#endif /* __DRIVERS_USB_CHIPIDEA_HOST_H */
You can’t perform that action at this time.
0 commit comments