diff options
Diffstat (limited to 'drivers/platform/x86/apple-gmux.c')
-rw-r--r-- | drivers/platform/x86/apple-gmux.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/platform/x86/apple-gmux.c b/drivers/platform/x86/apple-gmux.c index 8a582bdfdc76..6dcef4f199bb 100644 --- a/drivers/platform/x86/apple-gmux.c +++ b/drivers/platform/x86/apple-gmux.c | |||
@@ -87,6 +87,9 @@ static int gmux_update_status(struct backlight_device *bd) | |||
87 | struct apple_gmux_data *gmux_data = bl_get_data(bd); | 87 | struct apple_gmux_data *gmux_data = bl_get_data(bd); |
88 | u32 brightness = bd->props.brightness; | 88 | u32 brightness = bd->props.brightness; |
89 | 89 | ||
90 | if (bd->props.state & BL_CORE_SUSPENDED) | ||
91 | brightness = 0; | ||
92 | |||
90 | /* | 93 | /* |
91 | * Older gmux versions require writing out lower bytes first then | 94 | * Older gmux versions require writing out lower bytes first then |
92 | * setting the upper byte to 0 to flush the values. Newer versions | 95 | * setting the upper byte to 0 to flush the values. Newer versions |
@@ -102,6 +105,7 @@ static int gmux_update_status(struct backlight_device *bd) | |||
102 | } | 105 | } |
103 | 106 | ||
104 | static const struct backlight_ops gmux_bl_ops = { | 107 | static const struct backlight_ops gmux_bl_ops = { |
108 | .options = BL_CORE_SUSPENDRESUME, | ||
105 | .get_brightness = gmux_get_brightness, | 109 | .get_brightness = gmux_get_brightness, |
106 | .update_status = gmux_update_status, | 110 | .update_status = gmux_update_status, |
107 | }; | 111 | }; |