Patchwork [CONSOLIDATED,REQUEST,44/64] qemu: backport patch to fix pl031 RTC

login
register
mail settings
Submitter Saul Wold
Date Aug. 14, 2012, 12:13 p.m.
Message ID <4c24f7f1bde1405673a845692eed9295c0b9db83.1344946189.git.sgw@linux.intel.com>
Download mbox | patch
Permalink /patch/34547/
State Accepted
Commit a2a47ebfc3c8afa93bbf28e4a243538ea61079ac
Headers show

Comments

Saul Wold - Aug. 14, 2012, 12:13 p.m.
From: "Roy.Li" <rongqing.li@windriver.com>

Intergrate the patch from:
http://repo.or.cz/w/qemu.git/commit/13a16f1d91fc7a46b65b22a33f6ffea1b826a097

Signed-off-by: Roy.Li <rongqing.li@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
---
 ...-Actually-raise-interrupt-on-timer-expiry.patch |   41 ++++++++++++++++++++
 meta/recipes-devtools/qemu/qemu_0.15.1.bb          |    1 +
 2 files changed, 42 insertions(+), 0 deletions(-)
 create mode 100644 meta/recipes-devtools/qemu/qemu-0.15.1/hw-pl031-Actually-raise-interrupt-on-timer-expiry.patch

Patch

diff --git a/meta/recipes-devtools/qemu/qemu-0.15.1/hw-pl031-Actually-raise-interrupt-on-timer-expiry.patch b/meta/recipes-devtools/qemu/qemu-0.15.1/hw-pl031-Actually-raise-interrupt-on-timer-expiry.patch
new file mode 100644
index 0000000..2ccc663
--- /dev/null
+++ b/meta/recipes-devtools/qemu/qemu-0.15.1/hw-pl031-Actually-raise-interrupt-on-timer-expiry.patch
@@ -0,0 +1,41 @@ 
+Upstream-Status: Backport
+commit 13a16f1d91fc7a46b65b22a33f6ffea1b826a097 
+in git://git.qemu.org/qemu.git master
+
+From 13a16f1d91fc7a46b65b22a33f6ffea1b826a097 Mon Sep 17 00:00:00 2001
+From: Peter Maydell <peter.maydell@linaro.org>
+Date: Thu, 16 Feb 2012 09:56:10 +0000
+Subject: [PATCH] hw/pl031: Actually raise interrupt on timer expiry
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Fix a typo in pl031_interrupt() which meant we were setting a bit
+in the interrupt mask rather than the interrupt status register
+and thus not actually raising an interrupt. This fix allows the
+rtctest program from the kernel's Documentation/rtc.txt to pass
+rather than hanging.
+
+Reported-by: Daniel Forsgren <daniel.forsgren@enea.com>
+Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
+Acked-by: Andreas Färber <afaerber@suse.de>
+---
+ hw/pl031.c |    2 +-
+ 1 files changed, 1 insertions(+), 1 deletions(-)
+
+diff --git a/hw/pl031.c b/hw/pl031.c
+index 05b5b11..69abc4f 100644
+--- a/hw/pl031.c
++++ b/hw/pl031.c
+@@ -76,7 +76,7 @@ static void pl031_interrupt(void * opaque)
+ {
+     pl031_state *s = (pl031_state *)opaque;
+ 
+-    s->im = 1;
++    s->is = 1;
+     DPRINTF("Alarm raised\n");
+     pl031_update(s);
+ }
+-- 
+1.7.4.1
+
diff --git a/meta/recipes-devtools/qemu/qemu_0.15.1.bb b/meta/recipes-devtools/qemu/qemu_0.15.1.bb
index 7b862ed..a914bcf 100644
--- a/meta/recipes-devtools/qemu/qemu_0.15.1.bb
+++ b/meta/recipes-devtools/qemu/qemu_0.15.1.bb
@@ -22,6 +22,7 @@  SRC_URI = "\
     file://dummy-gl-config.patch \
     file://0001-ppc64-Fix-linker-script.patch \
     file://ppc-s500-set-invalid-mask.patch \
+    file://hw-pl031-Actually-raise-interrupt-on-timer-expiry.patch \
     "
 
 # Only use the GL passthrough patches for native/nativesdk versions