summaryrefslogtreecommitdiff
path: root/drivers/leds/Kconfig
diff options
context:
space:
mode:
authorAmitoj Kaur Chawla <amitoj1606@gmail.com>2016-03-09 08:53:47 +0530
committerJacek Anaszewski <j.anaszewski@samsung.com>2016-03-14 09:22:22 +0100
commit8d3b6a4001ceaeef1aaac39e6cb5380780b4ef9c (patch)
tree37c33eee222708f659e407006c343ef9da76440b /drivers/leds/Kconfig
parentf165a66e16f0aa8270ec4a26fdb07606eb7d6ae3 (diff)
leds: wm831x-status: Use devm_led_classdev_register
Switch to resource-managed function devm_led_classdev_register instead of led_classdev_register and remove unneeded led_classdev_unregister. Also, remove platform_set_drvdata from probe function and the remove function, wm831x_status_remove as it is now has nothing to do. The Coccinelle semantic patch used to make this change is as follows: //<smpl> @platform@ identifier p, probefn, removefn; @@ struct platform_driver p = { .probe = probefn, .remove = removefn, }; @prb@ identifier platform.probefn, pdev; expression e; @@ probefn(struct platform_device *pdev, ...) { ... e = - led_classdev_register + devm_led_classdev_register (...); ... ?- led_classdev_unregister(...); ... } @remove depends on prb@ identifier platform.removefn; @@ removefn(...) { ... ?- led_classdev_unregister(...); ... } //</smpl> Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com>
Diffstat (limited to 'drivers/leds/Kconfig')
0 files changed, 0 insertions, 0 deletions