summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorpancho horrillo <pancho@pancho.name>2009-12-23 11:09:13 +0100
committerGreg Kroah-Hartman <gregkh@suse.de>2010-01-06 14:26:33 -0800
commit79ec7f562e3d0a7a78697ce3031e648e5a4cbdc2 (patch)
tree7af26120ed8d8b4df526521cd6db6038088d7abf /drivers
parent61a6c8ed6de9b2eb4c3f2850bbfb2e0aa9e182f0 (diff)
USB: Fix a bug on appledisplay.c regarding signedness
commit 37e9066b2f85480d99d3795373f5ef0b00ac1189 upstream. brightness status is reported by the Apple Cinema Displays as an 'unsigned char' (u8) value, but the code used 'char' instead. Note that he driver was developed on the PowerPC architecture, where the two types are synonymous, which is not always the case. Fixed that. Otherwise the driver will interpret brightness levels > 127 as negative, and fail to load. Signed-off-by: pancho horrillo <pancho@pancho.name> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/usb/misc/appledisplay.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/misc/appledisplay.c b/drivers/usb/misc/appledisplay.c
index 1d8e39a557d9..62ff5e729110 100644
--- a/drivers/usb/misc/appledisplay.c
+++ b/drivers/usb/misc/appledisplay.c
@@ -72,8 +72,8 @@ struct appledisplay {
struct usb_device *udev; /* usb device */
struct urb *urb; /* usb request block */
struct backlight_device *bd; /* backlight device */
- char *urbdata; /* interrupt URB data buffer */
- char *msgdata; /* control message data buffer */
+ u8 *urbdata; /* interrupt URB data buffer */
+ u8 *msgdata; /* control message data buffer */
struct delayed_work work;
int button_pressed;