[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] sparc64's get_physical_address_code should not fault on TTE
From: |
Jakub Jermar |
Subject: |
[Qemu-devel] sparc64's get_physical_address_code should not fault on TTE's with V=0 |
Date: |
Mon, 12 Jan 2009 21:53:15 +0100 |
User-agent: |
Thunderbird 2.0.0.19 (X11/20090105) |
Hi,
when I make the following change to helper.c, get_physical_address_code:
- // ctx match, vaddr match?
+ // ctx match, vaddr match, valid?
if (env->dmmuregs[1] == (env->itlb_tag[i] & 0x1fff) &&
- (address & mask) == (env->itlb_tag[i] & ~0x1fffULL)) {
- // valid, access ok?
- if ((env->itlb_tte[i] & 0x8000000000000000ULL) == 0 ||
- ((env->itlb_tte[i] & 0x4) && is_user)) {
+ (address & mask) == (env->itlb_tag[i] & ~0x1fffULL) &&
+ env->itlb_tte[i] & 0x8000000000000000ULL) {
+ // access ok?
+ if ((env->itlb_tte[i] & 0x4) && is_user) {
HelenOS gets a little bit further than without this change and seems
to panic more or less gracefully later.
In short, non-valid entries should be skipped by the loop in
get_physical_address_code instead of causing TFAULT, because
the ITLB can contain a valid entry for the same address. The
same is true for DTLB.
Can you confirm this?
Thanks,
Jakub
- [Qemu-devel] sparc64's get_physical_address_code should not fault on TTE's with V=0,
Jakub Jermar <=