Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 54089
b: refs/heads/master
c: df513e2
h: refs/heads/master
i:
  54087: 302efa4
v: v3
  • Loading branch information
Avi Kivity committed May 3, 2007
1 parent 927eb64 commit 1242d6a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: afeb1f14c5478560262b37431726eb0eb1a42e9e
refs/heads/master: df513e2cdd099822ed32cbc20aaf4ff310372202
5 changes: 3 additions & 2 deletions trunk/drivers/kvm/x86_emulate.c
Original file line number Diff line number Diff line change
Expand Up @@ -833,8 +833,9 @@ x86_emulate_memop(struct x86_emulate_ctxt *ctxt, struct x86_emulate_ops *ops)
dst.ptr = (unsigned long *)cr2;
dst.bytes = (d & ByteOp) ? 1 : op_bytes;
if (d & BitOp) {
dst.ptr += src.val / BITS_PER_LONG;
dst.bytes = sizeof(long);
unsigned long mask = ~(dst.bytes * 8 - 1);

dst.ptr = (void *)dst.ptr + (src.val & mask) / 8;
}
if (!(d & Mov) && /* optimisation - avoid slow emulated read */
((rc = ops->read_emulated((unsigned long)dst.ptr,
Expand Down

0 comments on commit 1242d6a

Please sign in to comment.