aboutsummaryrefslogtreecommitdiff
path: root/arch/ia64/kvm/mmio.c
diff options
context:
space:
mode:
authorPaul Mackerras <paulus@samba.org>2008-06-30 10:16:50 +1000
committerPaul Mackerras <paulus@samba.org>2008-06-30 10:16:50 +1000
commite9a4b6a3f6592862a67837e80aad3f50468857a6 (patch)
tree087420cf91ac922c7e99757c4490a605ec7b10f2 /arch/ia64/kvm/mmio.c
parent441dbb500b4344a8e3125e5aabab4f9dbf72514f (diff)
parent1702b52092e9a6d05398d3f9581ddc050ef00d06 (diff)
Merge branch 'linux-2.6'
Diffstat (limited to 'arch/ia64/kvm/mmio.c')
-rw-r--r--arch/ia64/kvm/mmio.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/ia64/kvm/mmio.c b/arch/ia64/kvm/mmio.c
index 351bf70da46..7f1a858bc69 100644
--- a/arch/ia64/kvm/mmio.c
+++ b/arch/ia64/kvm/mmio.c
@@ -159,7 +159,8 @@ static void mmio_access(struct kvm_vcpu *vcpu, u64 src_pa, u64 *dest,
if (p->u.ioreq.state == STATE_IORESP_READY) {
if (dir == IOREQ_READ)
- *dest = p->u.ioreq.data;
+ /* it's necessary to ensure zero extending */
+ *dest = p->u.ioreq.data & (~0UL >> (64-(s*8)));
} else
panic_vm(vcpu);
out: