From: tglx@linutronix.de (Thomas Gleixner)
To: linux-arm-kernel@lists.infradead.org
Subject: [patch 1/2] arm: Disable outer (L2) cache in kexec
Date: Mon, 5 Jul 2010 13:13:18 +0200 (CEST) [thread overview]
Message-ID: <alpine.LFD.2.00.1007051311040.2525@localhost.localdomain> (raw)
In-Reply-To: <1278327174.11315.21.camel@e102109-lin.cambridge.arm.com>
On Mon, 5 Jul 2010, Catalin Marinas wrote:
> On Mon, 2010-07-05 at 10:25 +0100, Thomas Gleixner wrote:
> > kexec does not disable the outer cache before disabling the inner
> > caches in cpu_proc_fin(). So L2 is enabled across the kexec jump. When
> > the new kernel enables chaches again, it randomly crashes.
> >
> > Disabling L2 before calling cpu_proc_fin() cures the problem.
> >
> > Disabling L2 requires the following new functions: flush_all(),
> > inv_all() and disable(). Add them to outer_cache_fns and call them
> > from the kexec code.
> >
> > Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> > Index: linux-2.6/arch/arm/include/asm/outercache.h
> > ===================================================================
> > --- linux-2.6.orig/arch/arm/include/asm/outercache.h
> > +++ linux-2.6/arch/arm/include/asm/outercache.h
> > @@ -25,6 +25,9 @@ struct outer_cache_fns {
> > void (*inv_range)(unsigned long, unsigned long);
> > void (*clean_range)(unsigned long, unsigned long);
> > void (*flush_range)(unsigned long, unsigned long);
> > + void (*flush_all)(void);
> > + void (*inv_all)(void);
> > + void (*disable)(void);
>
> Why don't we handle the flush_all/inv_all in the disable function and
> avoid exporting them? Once exported, people may start using them in
Because OMAP needs them to avoid reimplementing everything in the OMAP
part. So OMAP only needs to override the disable function. And if
Russell wants to add his cleanup patch which he posted last week, then
the split and the export needs to be done anyway.
Thanks,
tglx
next prev parent reply other threads:[~2010-07-05 11:13 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-05 9:25 [patch 0/2] [patch 0/2] ARM: Disable outer cache before kexec call -V2 Thomas Gleixner
2010-07-05 9:25 ` [patch 1/2] arm: Disable outer (L2) cache in kexec Thomas Gleixner
2010-07-05 10:52 ` Catalin Marinas
2010-07-05 11:13 ` Thomas Gleixner [this message]
2010-07-05 11:16 ` Catalin Marinas
2010-07-05 9:25 ` [patch 2/2] arm: Implement l2x0 cache disable functions Thomas Gleixner
2010-07-05 10:54 ` Catalin Marinas
2010-07-05 11:10 ` Thomas Gleixner
2010-07-05 11:14 ` Catalin Marinas
-- strict thread matches above, loose matches on Subject: below --
2010-07-05 11:52 [patch 0/2] ARM: Disable outer cache before kexec call -V3 Thomas Gleixner
2010-07-05 11:52 ` [patch 1/2] arm: Disable outer (L2) cache in kexec Thomas Gleixner
2010-07-05 12:11 ` Catalin Marinas
2010-07-01 16:05 [patch 0/2] ARM: Disable outer cache before kexec call Thomas Gleixner
2010-07-01 16:05 ` [patch 1/2] arm: Disable outer (L2) cache in kexec Thomas Gleixner
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=alpine.LFD.2.00.1007051311040.2525@localhost.localdomain \
--to=tglx@linutronix.de \
--cc=linux-arm-kernel@lists.infradead.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox