| To: | Ralf Baechle <ralf@linux-mips.org> |
|---|---|
| Subject: | [PATCH -queue v0 2/6] [loongson] oprofile: avoid do_IRQ for perfcounter when the interrupt is from bonito |
| From: | Wu Zhangjin <wuzhangjin@gmail.com> |
| Date: | Wed, 4 Nov 2009 17:05:08 +0800 |
| Cc: | Wu Zhangjin <wuzhangjin@gmail.com>, linux-mips@linux-mips.org, LKML <linux-kernel@vger.kernel.org>, huhb@lemote.com, yanh@lemote.com, Zhang Le <r0bertz@gentoo.org>, Thomas Gleixner <tglx@linutronix.de>, Nicholas Mc Guire <der.herr@hofr.at>, zhangfx@lemote.com, liujl@lemote.com |
| Dkim-signature: | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:subject:date :message-id:x-mailer:in-reply-to:references; bh=AcQ4R5dJlFioqnmx7cLQvs7Sq5EDkZx7sGAVCLDY3zc=; b=hLGy3ZV7LBOnEJCi5PWy9fFDPS0ICZzonP0uOCPExeJAygYs6002hc1LvVK3e1rt/o T/6syzaQ4N5Tdvirwac3RfIIdACzCqUWGN1bC7cLXZx1tLfxiVNXaRNiu9nzIZuDGduj zidouvYPOANHIiWfgYZHDs9YN7Rns3G4YELuA= |
| Domainkey-signature: | a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references; b=OHSqVRYFdLyc6X87mlEIpcx+jur6oHZxOaGJ5gZ1lFI8qnFiDt8vDd3D+5arhy7VNr RqpFOb4x7Y/2kI2KOHVPHW8AM4tINocSC7zWGAlEQXG2oA410+nnrVlGvrDnppL/9DZ4 gYS9e3AqYxDPCGlneGr7s/5T6ca9/A2qDzafg= |
| In-reply-to: | <cover.1257325319.git.wuzhangjin@gmail.com> |
| Original-recipient: | rfc822;linux-mips@linux-mips.org |
| References: | <cover.1257325319.git.wuzhangjin@gmail.com> |
| Sender: | linux-mips-bounce@linux-mips.org |
In loongson2f, the IP6 is shared by bonito and perfcounter, we need to
avoid do_IRQ for perfcounter when the interrupt is from bonito. This
patch does it.
Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com>
---
arch/mips/oprofile/op_model_loongson2.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/arch/mips/oprofile/op_model_loongson2.c
b/arch/mips/oprofile/op_model_loongson2.c
index 575cd14..08d4b09 100644
--- a/arch/mips/oprofile/op_model_loongson2.c
+++ b/arch/mips/oprofile/op_model_loongson2.c
@@ -125,6 +125,9 @@ static irqreturn_t loongson2_perfcount_handler(int irq,
void *dev_id)
*/
/* Check whether the irq belongs to me */
+ enabled = read_c0_perfcnt() & LOONGSON2_PERFCNT_INT_EN;
+ if (!enabled)
+ return IRQ_NONE;
enabled = reg.cnt1_enabled | reg.cnt2_enabled;
if (!enabled)
return IRQ_NONE;
--
1.6.2.1
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | [PATCH -queue v0 1/6] [loongson] add basic loongson-2f support, Wu Zhangjin |
|---|---|
| Next by Date: | [PATCH -queue v0 3/6] [loongson] add basic cs5536 vsm support, Wu Zhangjin |
| Previous by Thread: | [PATCH -queue v0 1/6] [loongson] add basic loongson-2f support, Wu Zhangjin |
| Next by Thread: | [PATCH -queue v0 3/6] [loongson] add basic cs5536 vsm support, Wu Zhangjin |
| Indexes: | [Date] [Thread] [Top] [All Lists] |