leds: sm5701: Remove build warnings 52/159752/3
authorWook Song <wook16.song@samsung.com>
Mon, 13 Nov 2017 02:38:06 +0000 (11:38 +0900)
committerSeung-Woo Kim <sw0312.kim@samsung.com>
Mon, 13 Nov 2017 06:35:27 +0000 (06:35 +0000)
This patch remove build warnings caused by wrong usage of the
container_of macro.

Change-Id: I76d9e74300a85fd864b2e93caf7429588df90d04
Signed-off-by: Wook Song <wook16.song@samsung.com>
drivers/leds/leds-sm5701.c

index b805683..175d511 100644 (file)
@@ -423,7 +423,7 @@ static ssize_t sm5701_movie_store(struct device *dev,
         ssize_t ret;
         struct led_classdev *led_cdev = dev_get_drvdata(dev);
         struct SM5701_leds_data *chip =
-            container_of(led_cdev, struct SM5701_leds_data, work_movie);
+            container_of(led_cdev, struct SM5701_leds_data, cdev_movie);
         unsigned int state;
 
         ret = kstrtouint(buf, 10, &state);
@@ -481,7 +481,7 @@ static ssize_t sm5701_flash_store(struct device *dev,
         ssize_t ret;
         struct led_classdev *led_cdev = dev_get_drvdata(dev);
         struct SM5701_leds_data *chip =
-            container_of(led_cdev, struct SM5701_leds_data, work_flash);
+            container_of(led_cdev, struct SM5701_leds_data, cdev_flash);
         unsigned int state;
 
         ret = kstrtouint(buf, 10, &state);