From: Ralf Baechle <ralf@oss.sgi.com>
To: Justin Carlson <justinca@cs.cmu.edu>
Cc: linux-mips@oss.sgi.com
Subject: Re: __flush_cache_all() miscellany
Date: Wed, 29 May 2002 14:07:59 -0700 [thread overview]
Message-ID: <20020529140759.A888@dea.linux-mips.net> (raw)
In-Reply-To: <1022691053.7644.16.camel@ldt-sj3-022.sj.broadcom.com>; from justinca@cs.cmu.edu on Wed, May 29, 2002 at 09:50:52AM -0700
On Wed, May 29, 2002 at 09:50:52AM -0700, Justin Carlson wrote:
> Looking at the cache routines, I've noticed that there's been a
> relatively recent introduction of a __flush_cache_all() routine.
> Looking at oss.sgi.com's cvs logs, I see this comment:
>
> >Introduce __flush_cache_all() which flushes the cache no matter if
> >this operation is necessary from the mm point of view or not.
>
> Some questions:
>
> Which caches does this apply to? It looks like the current
> implementations assume L1 only.
The operation got introduced for the R10000 where we only need to flush
the caches during initialization or the (unlikely on Origin) case of
> Would anyone have a problem with renaming this function? To me, at
> least, it's rather confusing to have all of:
No. You may have noticed that I already introduced a bunch of local_*()
functions for the TLB stuff for the same reason - the old functions had
poor names. The common Linux conventions to use extra underscores for a
more basic version of a function (like get_user vs __get_user etc.) is
frequently not expressive enough.
> flush_cache_all()
> _flush_cache_all()
> __flush_cache_all()
> ___flush_cache_all()
Odd number of underscores means it's a pointer ;)
> defined, especially when the latter two mean something significantly
> different from the former two. I'd prefer calling the new one
> {_}force_flush_l1_caches() or somesuch.
Ok.
> In a related note, one of the few places this routine is called is the
> kgdb stub routines (in arch/mips/kernel/gdb-stub.c):
>
> void set_async_breakpoint(unsigned int epc)
> {
> int cpu = smp_processor_id();
>
> async_bp[cpu].addr = epc;
> async_bp[cpu].val = *(unsigned *)epc;
> *(unsigned *)epc = BP;
> __flush_cache_all();
> }
>
> Shouldn't that be a flush_icache_range() call anyways?
Yes.
Ralf
next prev parent reply other threads:[~2002-05-29 21:06 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-05-29 16:50 __flush_cache_all() miscellany Justin Carlson
2002-05-29 19:26 ` Justin Carlson
2002-05-29 19:50 ` Maciej W. Rozycki
2002-05-29 20:20 ` Justin Carlson
2002-05-29 21:00 ` Maciej W. Rozycki
2002-05-29 21:33 ` Ralf Baechle
2002-05-29 21:46 ` Maciej W. Rozycki
2002-05-29 22:46 ` Ralf Baechle
2002-05-29 22:59 ` Justin Carlson
2002-05-29 23:24 ` Jun Sun
2002-06-03 17:23 ` Maciej W. Rozycki
2002-05-29 21:03 ` Kevin D. Kissell
2002-05-29 21:03 ` Kevin D. Kissell
2002-05-29 21:28 ` Ralf Baechle
2002-05-29 21:09 ` Ralf Baechle
2002-05-29 21:07 ` Ralf Baechle [this message]
2002-05-30 12:31 ` Florian Laws
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=20020529140759.A888@dea.linux-mips.net \
--to=ralf@oss.sgi.com \
--cc=justinca@cs.cmu.edu \
--cc=linux-mips@oss.sgi.com \
/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