| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * Backlight control code for Sharp Zaurus SL-5500 |
|---|
| 3 | 4 | * |
|---|
| 4 | 5 | * Copyright 2005 John Lenz <lenz@cs.wisc.edu> |
|---|
| 5 | 6 | * Maintainer: Pavel Machek <pavel@ucw.cz> (unless John wants to :-) |
|---|
| 6 | | - * GPL v2 |
|---|
| 7 | 7 | * |
|---|
| 8 | 8 | * This driver assumes single CPU. That's okay, because collie is |
|---|
| 9 | 9 | * slightly old hardware, and no one is going to retrofit second CPU to |
|---|
| .. | .. |
|---|
| 111 | 111 | |
|---|
| 112 | 112 | static int locomolcd_set_intensity(struct backlight_device *bd) |
|---|
| 113 | 113 | { |
|---|
| 114 | | - int intensity = bd->props.brightness; |
|---|
| 114 | + int intensity = backlight_get_brightness(bd); |
|---|
| 115 | 115 | |
|---|
| 116 | | - if (bd->props.power != FB_BLANK_UNBLANK) |
|---|
| 117 | | - intensity = 0; |
|---|
| 118 | | - if (bd->props.fb_blank != FB_BLANK_UNBLANK) |
|---|
| 119 | | - intensity = 0; |
|---|
| 120 | 116 | if (locomolcd_flags & LOCOMOLCD_SUSPENDED) |
|---|
| 121 | 117 | intensity = 0; |
|---|
| 122 | 118 | |
|---|