Commit 40c935ae3de413d6bbc5471c231c90e26a63d562
Committed by
Benjamin Herrenschmidt
1 parent
b2bb65f680
Exists in
smarc-l5.0.0_1.0.0-ga
and in
5 other branches
powerpc/sysdev: Use module_platform_driver macro
This patch removes some code duplication by using module_platform_driver. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@st.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Showing 1 changed file with 1 additions and 12 deletions Side-by-side Diff
arch/powerpc/sysdev/pmi.c
... | ... | @@ -214,18 +214,7 @@ |
214 | 214 | .of_match_table = pmi_match, |
215 | 215 | }, |
216 | 216 | }; |
217 | - | |
218 | -static int __init pmi_module_init(void) | |
219 | -{ | |
220 | - return platform_driver_register(&pmi_of_platform_driver); | |
221 | -} | |
222 | -module_init(pmi_module_init); | |
223 | - | |
224 | -static void __exit pmi_module_exit(void) | |
225 | -{ | |
226 | - platform_driver_unregister(&pmi_of_platform_driver); | |
227 | -} | |
228 | -module_exit(pmi_module_exit); | |
217 | +module_platform_driver(pmi_of_platform_driver); | |
229 | 218 | |
230 | 219 | int pmi_send_message(pmi_message_t msg) |
231 | 220 | { |