mirror of
https://github.com/armbian/build
synced 2025-09-24 19:47:06 +07:00
fix crash dump on eager led setting
This commit is contained in:
@@ -987,6 +987,10 @@ index 000000000000..111111111111
|
||||
+ return ret;
|
||||
+ }
|
||||
+
|
||||
+ mutex_init(&display->lock);
|
||||
+ INIT_WORK(&display->flush_brightness, tm16xx_display_flush_brightness);
|
||||
+ INIT_WORK(&display->flush_display, tm16xx_display_flush_data);
|
||||
+
|
||||
+ display->main_led.name = TM16XX_DEVICE_NAME;
|
||||
+ display->main_led.brightness = display->controller->max_brightness;
|
||||
+ display->main_led.max_brightness = display->controller->max_brightness;
|
||||
@@ -1036,10 +1040,6 @@ index 000000000000..111111111111
|
||||
+ i++;
|
||||
+ }
|
||||
+
|
||||
+ mutex_init(&display->lock);
|
||||
+ INIT_WORK(&display->flush_brightness, tm16xx_display_flush_brightness);
|
||||
+ INIT_WORK(&display->flush_display, tm16xx_display_flush_data);
|
||||
+
|
||||
+ ret = tm16xx_display_init(display);
|
||||
+ if (ret < 0) {
|
||||
+ dev_err(display->dev, "Failed to initialize display: %d\n", ret);
|
||||
|
||||
@@ -988,6 +988,10 @@ index 000000000000..d938b0166e74
|
||||
+ return ret;
|
||||
+ }
|
||||
+
|
||||
+ mutex_init(&display->lock);
|
||||
+ INIT_WORK(&display->flush_brightness, tm16xx_display_flush_brightness);
|
||||
+ INIT_WORK(&display->flush_display, tm16xx_display_flush_data);
|
||||
+
|
||||
+ display->main_led.name = TM16XX_DEVICE_NAME;
|
||||
+ display->main_led.brightness = display->controller->max_brightness;
|
||||
+ display->main_led.max_brightness = display->controller->max_brightness;
|
||||
@@ -1037,10 +1041,6 @@ index 000000000000..d938b0166e74
|
||||
+ i++;
|
||||
+ }
|
||||
+
|
||||
+ mutex_init(&display->lock);
|
||||
+ INIT_WORK(&display->flush_brightness, tm16xx_display_flush_brightness);
|
||||
+ INIT_WORK(&display->flush_display, tm16xx_display_flush_data);
|
||||
+
|
||||
+ ret = tm16xx_display_init(display);
|
||||
+ if (ret < 0) {
|
||||
+ dev_err(display->dev, "Failed to initialize display: %d\n", ret);
|
||||
|
||||
Reference in New Issue
Block a user