Linux MIPS Architecture development
 help / color / mirror / Atom feed
From: Raymond Lo <lo@broadon.com>
To: linux-mips@oss.sgi.com
Subject: virtual coherency issues with 4Kc ?
Date: Fri, 31 May 2002 15:22:41 -0700	[thread overview]
Message-ID: <3CF7F7B1.50300@broadon.com> (raw)

I'm evaluting the MIPS 4Kc core.   One thing I'm trying to find out is 
how does linux deal with virtual aliasing in the cache for 4Kc.  

The cache of 4Kc is virtually-indexed and it has no hardware support to 
suppress virtual aliasing.   The cachetlb.txt under linux/Documentation 
indicates that two things need to be done in software to handle virtual 
aliasing in D-cache.

The first is to handle virtual aliasing in user address spaces.  Shared 
pages are mmaped at virtual addresses that are multiples of the cache 
size.   That has already been taked care of in  include/asm-mips/shmparam.h.

The second is to handle virtual aliasing between kernel virtual address 
space and user virtual address space by providing a number of functions 
to flush the cache at various points in the kernel.   The old interface 
is flush_page_to_ram.   The new ones are
  copy_user_page,
  clear_user_page,
  flush_dcache_page.

I'm surprised to find out that flush_dcache_page is a macro defined to 
be  do {} while (0) in linux/asm-mips/pgtable.h.  The source code I 
looked is the web CVS on oss.sgi.com and 2.4.18.

Apparently the necessary flushing hasn't been done from the mm and fs 
code for any MIPS port.  I know this is not necessary for R4000 with 
virtual coherency execptions.     I don't understand why it can be 
skipped for 4Kc.   Can anybody shine some light on the subject?

 -Raymond

 
P.S.   The link http://oss.sgi.com/mips/archive/ is stale.  

             reply	other threads:[~2002-05-31 22:21 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-05-31 22:22 Raymond Lo [this message]
2002-06-01  0:07 ` virtual coherency issues with 4Kc ? Kevin D. Kissell
2002-06-01  0:07   ` Kevin D. Kissell
2002-06-03  1:14 ` Ralf Baechle

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=3CF7F7B1.50300@broadon.com \
    --to=lo@broadon.com \
    --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