9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: ron minnich <rminnich@gmail.com>
To: 9fans <9fans@9fans.net>
Subject: Re: [9fans] risc-v memory layout
Date: Wed, 7 Jan 2026 08:58:20 -0800	[thread overview]
Message-ID: <CAP6exYKF_GEJpdEOPidscc_J7ezkUCU4DAsFVu4cGzahJBPJkQ@mail.gmail.com> (raw)
In-Reply-To: <77272bef6ca4f3fd68aa5ce5e96c1981@hamnavoe.com>

[-- Attachment #1: Type: text/plain, Size: 1223 bytes --]

you can't avoid M mode on riscv, ever. There are several trap cases that
will drop you in to M mode.

And M mode does not have paging, so it will always be using what x86 would
call real memory addresses.

Given that, the more I look at this, the more I want Plan 9 KVA do be
0->1<<60 or so, and UVA to be above that.

I have not yet seen a reason this won't work. It's just not like an x86 :-)

thanks
Ron

P.S. Richard, this is all your fault, your comment a few days ago got me to
thinking. Always a bad idea :-)

On Wed, Jan 7, 2026 at 5:46 AM Richard Miller <9fans@hamnavoe.com> wrote:

> <rminnich@gmail.com>:
> > M mode, for
> > example, has no virtual addressing, and it would be useful (to say the
> > least) to have kernel and M mode have a common set of addresses.
> 
> Basic question: when would you use M mode? Doesn't the kernel normally
> run entirely in Supervisor mode? Will the firmware on your platform even
> allow Plan 9 to get into M mode?
> 

------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/Tf6e0b1b3f80df821-Maacb4cc0a8b566370c93ba31
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

[-- Attachment #2: Type: text/html, Size: 2757 bytes --]

  reply	other threads:[~2026-01-07 16:59 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-06 23:13 [9fans] risc-v memory layout ron minnich
2026-01-07  9:44 ` Richard Miller
2026-01-07 16:58   ` ron minnich [this message]
2026-01-07 19:42     ` Richard Miller
2026-01-07 21:01       ` Fwd: " ron minnich
2026-01-07 17:54 ` tlaronde
2026-01-07 19:28   ` ron minnich
2026-01-08  2:50     ` Dan Cross
2026-01-08  8:08       ` tlaronde

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=CAP6exYKF_GEJpdEOPidscc_J7ezkUCU4DAsFVu4cGzahJBPJkQ@mail.gmail.com \
    --to=rminnich@gmail.com \
    --cc=9fans@9fans.net \
    /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;
as well as URLs for NNTP newsgroup(s).