linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* RMO ? (in the prom_init.c)
@ 2009-09-11  6:33 HongWoo Lee
  2009-09-11  7:39 ` Benjamin Herrenschmidt
  0 siblings, 1 reply; 2+ messages in thread
From: HongWoo Lee @ 2009-09-11  6:33 UTC (permalink / raw)
  To: linuxppc-dev list

Hi ~

Can anybody tell me what the RMO is ?? in the linux kernel. 
(arch/powerpc/kernel/prom_init.c)
Through googling and guessing, I found "Read Memory Only" and "Relaxed 
Memory Order".
But none of these are not properly understood in the context.

Thanks in advance.

HongWoo.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: RMO ? (in the prom_init.c)
  2009-09-11  6:33 RMO ? (in the prom_init.c) HongWoo Lee
@ 2009-09-11  7:39 ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 2+ messages in thread
From: Benjamin Herrenschmidt @ 2009-09-11  7:39 UTC (permalink / raw)
  To: HongWoo Lee; +Cc: linuxppc-dev list

On Fri, 2009-09-11 at 15:33 +0900, HongWoo Lee wrote:
> Hi ~
> 
> Can anybody tell me what the RMO is ?? in the linux kernel. 
> (arch/powerpc/kernel/prom_init.c)
> Through googling and guessing, I found "Read Memory Only" and "Relaxed 
> Memory Order".
> But none of these are not properly understood in the context.

It's actually a bad name and should probably be "RMA" , aka Real Mode
Area.

This is a "feature" of the POWER architecture for servers, when running
under a hypervisor. Not all of memory can be accessed when the processor
is in "real mode" (MSR:IR and/or DR off).

The reason is obvious, since the OS doesn't have access to real memory
but virtualized logical addresses. And since all of the virtualization
normally goes through the MMU hash table, "real mode" accesses that
bypass the hash table are problematic to allow in an OS.

The "solution" used by those processors is to have a HW feature that
allows a chunk of physical memory to be made accessible to the partition
in "real" mode, which is called the RMA.

That means in practice that the kernel can only access that portion of
it's logical address space while in real mode, it needs to use
translations in the hash table to access the whole of it.

The value in prom_init.c is used to constrain some allocations to that
range for things that will be accessed while running in real mode (such
as RTAS), though it's also abused to constrain those allocations to a
subset of memory even without hypervisors to work around things like
firmware bugs etc...

Cheers,
Ben.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-09-11  7:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-09-11  6:33 RMO ? (in the prom_init.c) HongWoo Lee
2009-09-11  7:39 ` Benjamin Herrenschmidt

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).