linux-2.6.24: fix sa1100-rtc
authorHenning Heinold <heinold@inf.fu-berlin.de>
Mon, 17 Mar 2008 22:08:29 +0000 (22:08 +0000)
committerHenning Heinold <heinold@inf.fu-berlin.de>
Mon, 17 Mar 2008 22:08:29 +0000 (22:08 +0000)
* hopefully fix the rtc1hz and rtcalarm register bug
* added patch under linux-2.6.24/simpad/
* bump pr
* thanks MrData for the patch

packages/linux/linux-2.6.24/simpad/linux-2.6.24-SIMpad-rtc-sa1100.patch [new file with mode: 0644]
packages/linux/linux_2.6.24.bb

diff --git a/packages/linux/linux-2.6.24/simpad/linux-2.6.24-SIMpad-rtc-sa1100.patch b/packages/linux/linux-2.6.24/simpad/linux-2.6.24-SIMpad-rtc-sa1100.patch
new file mode 100644 (file)
index 0000000..6e09bfd
--- /dev/null
@@ -0,0 +1,28 @@
+diff -Nur linux-2.6.24.vanilla/drivers/rtc/rtc-sa1100.c linux-2.6.24/drivers/rtc/rtc-sa1100.c
+--- linux-2.6.24.vanilla/drivers/rtc/rtc-sa1100.c      2008-01-24 23:58:37.000000000 +0100
++++ linux-2.6.24/drivers/rtc/rtc-sa1100.c      2008-03-17 20:52:41.000000000 +0100
+@@ -15,6 +15,10 @@
+  * Converted to the RTC subsystem and Driver Model
+  *   by Richard Purdie <rpurdie@rpsys.net>
+  *
++ * 2008/03/17 mrdata:
++ *            disable IRQ RTC1Hz and RTCAlrm before request_irq
++ *            in sa1100_rtc_open()
++ *
+  * This program is free software; you can redistribute it and/or
+  * modify it under the terms of the GNU General Public License
+  * as published by the Free Software Foundation; either version
+@@ -154,7 +158,12 @@
+ static int sa1100_rtc_open(struct device *dev)
+ {
+       int ret;
+-
++      
++      spin_lock_irq(&sa1100_rtc_lock);
++      RTSR &= ~RTSR_HZE;
++      RTSR &= ~RTSR_ALE;
++      spin_unlock_irq(&sa1100_rtc_lock);
++      
+       ret = request_irq(IRQ_RTC1Hz, sa1100_rtc_interrupt, IRQF_DISABLED,
+                               "rtc 1Hz", dev);
+       if (ret) {
index 1b3d834..7fc1aa3 100644 (file)
@@ -11,7 +11,7 @@ DEFAULT_PREFERENCE_at32stk1000 = "1"
 
 DEPENDS_append_mpc8313e-rdb = " dtc-native"
 
-PR = "r8"
+PR = "r9"
 
 SRC_URI = "${KERNELORG_MIRROR}/pub/linux/kernel/v2.6/linux-2.6.24.tar.bz2 \
            http://kamikaze.waninkoko.info/patches/2.6.24/kamikaze1/broken-out/squashfs-lzma-2.6.24.patch;patch=1 \
@@ -33,6 +33,7 @@ SRC_URI_append_simpad = "\
            file://linux-2.6.24-SIMpad-ucb1x00-ts-supend-and-accuracy.patch;patch=1 \
            file://linux-2.6.24-SIMpad-hostap_cs-shared-irq.patch;patch=1 \
            file://linux-2.6.24-SIMpad-orinoco_cs-shared-irq.patch;patch=1 \ 
+           file://linux-2.6.24-SIMpad-rtc-sa1100.patch;patch=1 \
            file://collie-kexec.patch;patch=1 \
            file://export_atags-r2.patch;patch=1 \
            "