diff options
Diffstat (limited to 'drivers/base/platform.c')
-rw-r--r-- | drivers/base/platform.c | 27 |
1 files changed, 20 insertions, 7 deletions
diff --git a/drivers/base/platform.c b/drivers/base/platform.c index 1ba9d617d241..f6bcf22e6bd1 100644 --- a/drivers/base/platform.c +++ b/drivers/base/platform.c | |||
@@ -1052,9 +1052,11 @@ static __initdata LIST_HEAD(early_platform_driver_list); | |||
1052 | static __initdata LIST_HEAD(early_platform_device_list); | 1052 | static __initdata LIST_HEAD(early_platform_device_list); |
1053 | 1053 | ||
1054 | /** | 1054 | /** |
1055 | * early_platform_driver_register | 1055 | * early_platform_driver_register - register early platform driver |
1056 | * @epdrv: early_platform driver structure | 1056 | * @epdrv: early_platform driver structure |
1057 | * @buf: string passed from early_param() | 1057 | * @buf: string passed from early_param() |
1058 | * | ||
1059 | * Helper function for early_platform_init() / early_platform_init_buffer() | ||
1058 | */ | 1060 | */ |
1059 | int __init early_platform_driver_register(struct early_platform_driver *epdrv, | 1061 | int __init early_platform_driver_register(struct early_platform_driver *epdrv, |
1060 | char *buf) | 1062 | char *buf) |
@@ -1106,9 +1108,12 @@ int __init early_platform_driver_register(struct early_platform_driver *epdrv, | |||
1106 | } | 1108 | } |
1107 | 1109 | ||
1108 | /** | 1110 | /** |
1109 | * early_platform_add_devices - add a numbers of early platform devices | 1111 | * early_platform_add_devices - adds a number of early platform devices |
1110 | * @devs: array of early platform devices to add | 1112 | * @devs: array of early platform devices to add |
1111 | * @num: number of early platform devices in array | 1113 | * @num: number of early platform devices in array |
1114 | * | ||
1115 | * Used by early architecture code to register early platform devices and | ||
1116 | * their platform data. | ||
1112 | */ | 1117 | */ |
1113 | void __init early_platform_add_devices(struct platform_device **devs, int num) | 1118 | void __init early_platform_add_devices(struct platform_device **devs, int num) |
1114 | { | 1119 | { |
@@ -1128,8 +1133,12 @@ void __init early_platform_add_devices(struct platform_device **devs, int num) | |||
1128 | } | 1133 | } |
1129 | 1134 | ||
1130 | /** | 1135 | /** |
1131 | * early_platform_driver_register_all | 1136 | * early_platform_driver_register_all - register early platform drivers |
1132 | * @class_str: string to identify early platform driver class | 1137 | * @class_str: string to identify early platform driver class |
1138 | * | ||
1139 | * Used by architecture code to register all early platform drivers | ||
1140 | * for a certain class. If omitted then only early platform drivers | ||
1141 | * with matching kernel command line class parameters will be registered. | ||
1133 | */ | 1142 | */ |
1134 | void __init early_platform_driver_register_all(char *class_str) | 1143 | void __init early_platform_driver_register_all(char *class_str) |
1135 | { | 1144 | { |
@@ -1151,7 +1160,7 @@ void __init early_platform_driver_register_all(char *class_str) | |||
1151 | } | 1160 | } |
1152 | 1161 | ||
1153 | /** | 1162 | /** |
1154 | * early_platform_match | 1163 | * early_platform_match - find early platform device matching driver |
1155 | * @epdrv: early platform driver structure | 1164 | * @epdrv: early platform driver structure |
1156 | * @id: id to match against | 1165 | * @id: id to match against |
1157 | */ | 1166 | */ |
@@ -1169,7 +1178,7 @@ early_platform_match(struct early_platform_driver *epdrv, int id) | |||
1169 | } | 1178 | } |
1170 | 1179 | ||
1171 | /** | 1180 | /** |
1172 | * early_platform_left | 1181 | * early_platform_left - check if early platform driver has matching devices |
1173 | * @epdrv: early platform driver structure | 1182 | * @epdrv: early platform driver structure |
1174 | * @id: return true if id or above exists | 1183 | * @id: return true if id or above exists |
1175 | */ | 1184 | */ |
@@ -1187,7 +1196,7 @@ static __init int early_platform_left(struct early_platform_driver *epdrv, | |||
1187 | } | 1196 | } |
1188 | 1197 | ||
1189 | /** | 1198 | /** |
1190 | * early_platform_driver_probe_id | 1199 | * early_platform_driver_probe_id - probe drivers matching class_str and id |
1191 | * @class_str: string to identify early platform driver class | 1200 | * @class_str: string to identify early platform driver class |
1192 | * @id: id to match against | 1201 | * @id: id to match against |
1193 | * @nr_probe: number of platform devices to successfully probe before exiting | 1202 | * @nr_probe: number of platform devices to successfully probe before exiting |
@@ -1257,10 +1266,14 @@ static int __init early_platform_driver_probe_id(char *class_str, | |||
1257 | } | 1266 | } |
1258 | 1267 | ||
1259 | /** | 1268 | /** |
1260 | * early_platform_driver_probe | 1269 | * early_platform_driver_probe - probe a class of registered drivers |
1261 | * @class_str: string to identify early platform driver class | 1270 | * @class_str: string to identify early platform driver class |
1262 | * @nr_probe: number of platform devices to successfully probe before exiting | 1271 | * @nr_probe: number of platform devices to successfully probe before exiting |
1263 | * @user_only: only probe user specified early platform devices | 1272 | * @user_only: only probe user specified early platform devices |
1273 | * | ||
1274 | * Used by architecture code to probe registered early platform drivers | ||
1275 | * within a certain class. For probe to happen a registered early platform | ||
1276 | * device matching a registered early platform driver is needed. | ||
1264 | */ | 1277 | */ |
1265 | int __init early_platform_driver_probe(char *class_str, | 1278 | int __init early_platform_driver_probe(char *class_str, |
1266 | int nr_probe, | 1279 | int nr_probe, |