All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ralf Baechle <ralf@linux-mips.org>
To: "Dennis.Yxun" <dennis.yxun@gmail.com>
Cc: linux-mips@linux-mips.org, "Anoop P.A." <Anoop_P.A@pmc-sierra.com>
Subject: Re: Problem About Vectored interrupt
Date: Sat, 19 Mar 2011 18:22:54 +0100	[thread overview]
Message-ID: <20110319172254.GA11550@linux-mips.org> (raw)
In-Reply-To: <AANLkTimK1xpHwvfE95rEMCikk8-0EkGjn4b5DwYWyN-E@mail.gmail.com>

On Sat, Mar 19, 2011 at 08:42:17AM +0800, Dennis.Yxun wrote:

> HI ALL:
>   Again, found that when come to set vect irq 7, do additional data flush
> fix my problem, here is the patch
> 
> diff --git a/arch/mips/kernel/traps.c b/arch/mips/kernel/traps.c
> index e971043..850ce58 100644
> --- a/arch/mips/kernel/traps.c
> +++ b/arch/mips/kernel/traps.c
> @@ -1451,6 +1451,9 @@ static void *set_vi_srs_handler(int n, vi_handler_t
> addr, int srs)
>                 *w = (*w & 0xffff0000) | (((u32)handler >> 16) & 0xffff);
>                 w = (u32 *)(b + ori_offset);
>                 *w = (*w & 0xffff0000) | ((u32)handler & 0xffff);
> +               /* FIXME: need flash data cache, for timer irq */
> +               if (n == 7)
> +                       flush_data_cache_page((unsigned int)b);
>                 local_flush_icache_range((unsigned long)b,
>                                          (unsigned long)(b+handler_len));

The call local_flush_icache_range should already flushes the cache and
there should be no reason why a 2nd range makes it any better - or why
it would only be needed for irq 7 - and the timer isn't necessarily
always irq 7.

What is your hardware platform and processor?

  Ralf

  reply	other threads:[~2011-03-19 17:23 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <AANLkTinhM4PUmLbWeAyavf-JPM1Xpu9pJVkXDq4c-f0C@mail.gmail.com>
2010-12-27 14:00 ` Problem About Vectored interrupt Dennis.Yxun
     [not found]   ` <A7DEA48C84FD0B48AAAE33F328C02014033DADEC@BBY1EXM11.pmc_nt.nt.pmc-sierra.bc.ca>
     [not found]     ` <AANLkTikWUehOmyD6Nk3Abz=u7FEb8NMtX2-N4r5HHuY9@mail.gmail.com>
2011-03-19  0:42       ` Dennis.Yxun
2011-03-19 17:22         ` Ralf Baechle [this message]
2011-03-22  2:02           ` Dennis.Yxun

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110319172254.GA11550@linux-mips.org \
    --to=ralf@linux-mips.org \
    --cc=Anoop_P.A@pmc-sierra.com \
    --cc=dennis.yxun@gmail.com \
    --cc=linux-mips@linux-mips.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.