aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorDan Murphy <dmurphy@ti.com>2019-10-01 13:04:36 -0500
committerPavel <pavel@ucw.cz>2019-11-03 17:38:27 +0100
commit4a29f90e60df955f1b6e0dd836955f14a62dc103 (patch)
tree9e5316aaca1b80085a2dc8df94c062443fe5abea /include/linux
parentleds: Kconfig: Be consistent with the usage of "LED" (diff)
downloadlinux-dev-4a29f90e60df955f1b6e0dd836955f14a62dc103.tar.xz
linux-dev-4a29f90e60df955f1b6e0dd836955f14a62dc103.zip
leds: flash: Convert non extended registration to inline
Convert the #define non-extended registration API to an inline function. Signed-off-by: Dan Murphy <dmurphy@ti.com> Signed-off-by: Pavel Machek <pavel@ucw.cz>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/led-class-flash.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/include/linux/led-class-flash.h b/include/linux/led-class-flash.h
index 1e824963af17..7ff287a9e2a2 100644
--- a/include/linux/led-class-flash.h
+++ b/include/linux/led-class-flash.h
@@ -98,8 +98,11 @@ extern int led_classdev_flash_register_ext(struct device *parent,
struct led_classdev_flash *fled_cdev,
struct led_init_data *init_data);
-#define led_classdev_flash_register(parent, fled_cdev) \
- led_classdev_flash_register_ext(parent, fled_cdev, NULL)
+static inline int led_classdev_flash_register(struct device *parent,
+ struct led_classdev_flash *fled_cdev)
+{
+ return led_classdev_flash_register_ext(parent, fled_cdev, NULL);
+}
/**
* led_classdev_flash_unregister - unregisters an object of led_classdev class