hal: Branch 'master'

Danny Kukawka dkukawka at kemper.freedesktop.org
Fri Apr 25 13:18:30 PDT 2008


 hald/linux/addons/addon-macbook-backlight.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 9f5219eaa6c7423870b031fdfa07de6a84f25d6e
Author: Danny Kukawka <danny.kukawka at web.de>
Date:   Fri Apr 25 22:18:24 2008 +0200

    fix macbook-backlight for ix86
    
    Fixed macbook-backlight for ix86 with a patch contributed by user
    'godlygeek' via: https://bugs.launchpad.net/hal/+bug/206921
    
    from comment #27:
    > This patch should fix it. Problem is that we're doing bitwise
    > arithmetic on a signed long that happens to be negative.
    > Wackiness ensues, making the result an invalid offset for mmap().
    > Changing the long to unsigned fixes it.

diff --git a/hald/linux/addons/addon-macbook-backlight.c b/hald/linux/addons/addon-macbook-backlight.c
index 99c3905..47817ab 100644
--- a/hald/linux/addons/addon-macbook-backlight.c
+++ b/hald/linux/addons/addon-macbook-backlight.c
@@ -115,7 +115,7 @@ end:
 static gboolean
 map_register_page (void)
 {
-	long address;
+	unsigned long address;
 	int fd;
 
 	address = determine_video_base_address ();


More information about the hal-commit mailing list