diff options
Diffstat (limited to 'drivers/usb/misc/appledisplay.c')
-rw-r--r-- | drivers/usb/misc/appledisplay.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/drivers/usb/misc/appledisplay.c b/drivers/usb/misc/appledisplay.c index 416cde5893af..cd2c5574cf93 100644 --- a/drivers/usb/misc/appledisplay.c +++ b/drivers/usb/misc/appledisplay.c | |||
@@ -189,11 +189,9 @@ static void appledisplay_work(struct work_struct *work) | |||
189 | container_of(work, struct appledisplay, work.work); | 189 | container_of(work, struct appledisplay, work.work); |
190 | int retval; | 190 | int retval; |
191 | 191 | ||
192 | up(&pdata->bd->sem); | ||
193 | retval = appledisplay_bl_get_brightness(pdata->bd); | 192 | retval = appledisplay_bl_get_brightness(pdata->bd); |
194 | if (retval >= 0) | 193 | if (retval >= 0) |
195 | pdata->bd->props->brightness = retval; | 194 | pdata->bd->props->brightness = retval; |
196 | down(&pdata->bd->sem); | ||
197 | 195 | ||
198 | /* Poll again in about 125ms if there's still a button pressed */ | 196 | /* Poll again in about 125ms if there's still a button pressed */ |
199 | if (pdata->button_pressed) | 197 | if (pdata->button_pressed) |
@@ -288,9 +286,7 @@ static int appledisplay_probe(struct usb_interface *iface, | |||
288 | } | 286 | } |
289 | 287 | ||
290 | /* Try to get brightness */ | 288 | /* Try to get brightness */ |
291 | up(&pdata->bd->sem); | ||
292 | brightness = appledisplay_bl_get_brightness(pdata->bd); | 289 | brightness = appledisplay_bl_get_brightness(pdata->bd); |
293 | down(&pdata->bd->sem); | ||
294 | 290 | ||
295 | if (brightness < 0) { | 291 | if (brightness < 0) { |
296 | retval = brightness; | 292 | retval = brightness; |
@@ -299,9 +295,7 @@ static int appledisplay_probe(struct usb_interface *iface, | |||
299 | } | 295 | } |
300 | 296 | ||
301 | /* Set brightness in backlight device */ | 297 | /* Set brightness in backlight device */ |
302 | up(&pdata->bd->sem); | ||
303 | pdata->bd->props->brightness = brightness; | 298 | pdata->bd->props->brightness = brightness; |
304 | down(&pdata->bd->sem); | ||
305 | 299 | ||
306 | /* save our data pointer in the interface device */ | 300 | /* save our data pointer in the interface device */ |
307 | usb_set_intfdata(iface, pdata); | 301 | usb_set_intfdata(iface, pdata); |