diff options
author | Alexander Graf <agraf@suse.de> | 2010-02-09 17:37:09 +0100 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2010-02-14 16:10:54 +0200 |
commit | b2eca4453fb60c85c63912b7218b41b521165d94 (patch) | |
tree | 951d178cd8383814e6570d7d5921aa363dfecf83 /target-ppc | |
parent | a2236d4820a09a35e017508c57564c97736c79f7 (diff) |
PPC: Fix large pages
We were masking 1TB SLB entries on the feature bit of 16 MB pages. Obviously
that breaks, so let's just ignore 1TB SLB entries for now and instead do
16MB pages correctly.
This fixes PPC64 Linux boot with -m above 256.
Signed-off-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'target-ppc')
-rw-r--r-- | target-ppc/helper.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/target-ppc/helper.c b/target-ppc/helper.c index a4fae31e38..cd1c9fea0e 100644 --- a/target-ppc/helper.c +++ b/target-ppc/helper.c @@ -736,14 +736,13 @@ static inline int slb_lookup(CPUPPCState *env, target_ulong eaddr, PRIx32 "\n", __func__, n, slb->tmp64, slb->tmp); if (slb_is_valid(slb)) { /* SLB entry is valid */ + mask = 0xFFFFFFFFF0000000ULL; if (slb->tmp & 0x8) { - /* 1 TB Segment */ - mask = 0xFFFF000000000000ULL; + /* 16 MB PTEs */ if (target_page_bits) - *target_page_bits = 24; // XXX 16M pages? + *target_page_bits = 24; } else { - /* 256MB Segment */ - mask = 0xFFFFFFFFF0000000ULL; + /* 4 KB PTEs */ if (target_page_bits) *target_page_bits = TARGET_PAGE_BITS; } |