leds: class: Improve LED and LED flash class registration API
[linux-block.git] / include / linux / led-class-flash.h
index f52713f0a2697c0173bc86a9c98257f9d836f1fe..1e824963af17409de8bb066e57e4ca779345c22b 100644 (file)
@@ -86,15 +86,20 @@ static inline struct led_classdev_flash *lcdev_to_flcdev(
 }
 
 /**
- * led_classdev_flash_register - register a new object of led_classdev class
- *                              with support for flash LEDs
- * @parent: the flash LED to register
+ * led_classdev_flash_register_ext - register a new object of LED class with
+ *                                  init data and with support for flash LEDs
+ * @parent: LED flash controller device this flash LED is driven by
  * @fled_cdev: the led_classdev_flash structure for this device
+ * @init_data: the LED class flash device initialization data
  *
  * Returns: 0 on success or negative error value on failure
  */
-extern int led_classdev_flash_register(struct device *parent,
-                               struct led_classdev_flash *fled_cdev);
+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)
 
 /**
  * led_classdev_flash_unregister - unregisters an object of led_classdev class