[oe-commits] : linux-2.6.24: fix compile for archs that do not support __udivdi3()

OE GIT Trial gittrial at amethyst.openembedded.net
Sat Oct 4 21:18:31 UTC 2008


Module: org.openembedded.dev.git
Branch: org.openembedded.dev
Commit: 3b936fe7629f2abc38770dda431291e779fc7425
URL:    http://gitweb.openembedded.net/?p=org.openembedded.dev.git&a=commit;h=3b936fe7629f2abc38770dda431291e779fc7425

Author:  <woglinde2 at openembedded.org>
Date:   Sat Oct  4 21:07:45 2008 +0000

linux-2.6.24: fix compile for archs that do not support  __udivdi3()
* add time.h.patch from kernel ml
* bump PR

---

 packages/linux/linux-2.6.24/time.h.patch |   25 +++++++++++++++++++++++++
 packages/linux/linux_2.6.24.bb           |    3 ++-
 2 files changed, 27 insertions(+), 1 deletions(-)

diff --git a/packages/linux/linux-2.6.24/time.h.patch b/packages/linux/linux-2.6.24/time.h.patch
new file mode 100644
index 0000000..fd22f3a
--- /dev/null
+++ b/packages/linux/linux-2.6.24/time.h.patch
@@ -0,0 +1,25 @@
+....since some architectures don't support __udivdi3() (and
+ we don't want to use that, anyway).
+ 
+ Signed-off-by: Segher Boessenkool 
+ ---
+ include/linux/time.h | 4 ++++
+ 1 files changed, 4 insertions(+), 0 deletions(-)
+
+
+Index: linux-2.6.24/include/linux/time.h
+===================================================================
+--- linux-2.6.24.orig/include/linux/time.h	2008-06-23 11:17:09.021841180 +0200
++++ linux-2.6.24/include/linux/time.h	2008-06-23 11:18:34.445167140 +0200
+@@ -173,6 +173,11 @@
+ {
+ 	ns += a->tv_nsec;
+ 	while(unlikely(ns >= NSEC_PER_SEC)) {
++		/* The following asm() prevents the compiler from
++		 * optimising this loop into a modulo operation.
++		 */
++		asm("" : "+r"(ns));
++
+ 		ns -= NSEC_PER_SEC;
+ 		a->tv_sec++;
+ 	}
diff --git a/packages/linux/linux_2.6.24.bb b/packages/linux/linux_2.6.24.bb
index 7fd2f45..de12e4c 100644
--- a/packages/linux/linux_2.6.24.bb
+++ b/packages/linux/linux_2.6.24.bb
@@ -10,10 +10,11 @@ DEFAULT_PREFERENCE_at32stk1000 = "1"
 DEFAULT_PREFERENCE_ts72xx = "1"
 DEFAULT_PREFERENCE_cs-e9302 = "1"
 
-PR = "r14"
+PR = "r15"
 
 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 \
+	   file://time.h.patch;patch=1 \
            file://defconfig"
 
 # Moved away temporarely until committed properly (work in progress).





More information about the Openembedded-commits mailing list