Re: [PATCH 11/26] KVM: PPC: Make RMO a define
From: Alexander Graf <hidden>
Date: 2010-06-29 08:04:48
Also in:
kvm
On 29.06.2010, at 09:52, Segher Boessenkool wrote:
quoted
quoted
quoted
quoted
Also, it seems you construct the physical address by masking out =
bits from
quoted
quoted
quoted
quoted
the effective address. Most implementations will trap or machine =
check if
quoted
quoted
quoted
quoted
you address outside of physical address space, instead.=20 Well the only case where I remember to have hit a real RMO case is =
on the PS3 - that issues a data/instruction storage interrupt when = accessing anything > 8MB in real mode.
quoted
quoted
quoted
=20 So I'd argue this is heavily implementation specific.=20 It is. So what is the behaviour you want to implement?=20 The one below.=20 I'm sorry, I lost it. "Below"?
Well, the ones a few lines below :).
=20quoted
quoted
quoted
Apart from that what I'm trying to cover is that on ppc64 accessing =
0xc0000000000000 in real mode gets you 0x0. Is there a better name for = this?
quoted
quoted
=20 (You missed two zeroes). In hypervisor real mode, the top few bits are magic. They are used =
for e.g.
quoted
quoted
enabling hypervisor offset real mode. In supervisor real mode, those bits are ignored (and all other bits =
that do
quoted
quoted
not correspond to physical address lines may also be ignored).=20 So which bits exactly are reserved? I couldn't find a reference to =
that part.
=20 If by "reserved" you mean "cannot be used for addressing", it's the =
top four
bits. Book III-S chapter 5.7.3 in the Power Architecture 2.06 =
document.
Implementations are allowed to ignore more bits than that. =20 I believe in earlier versions of the architecture it was the top two =
bits,
not four, but maybe I misremember.
Ah, nice. So that part is implementation specific too. Awesome ;).
=20quoted
quoted
Maybe you want to call it physical_address_mask or similar?=20 PAM - doesn't sound bad :).=20 And miraculously nothing in the Power arch uses that acronym yet! But =
I
would spell it out if I were you, acronyms are confusing.
Well, the bad thing about not using acronyms here is that I'll run out = of the 80 character limit pretty soon. And that means line wraps and = more confusingness when reading the code. Alex