Lines Matching +full:non +full:- +full:linear
1 /* SPDX-License-Identifier: GPL-2.0 */
5 * Generic x86 (32-bit and 64-bit) instruction decoder and emulator.
9 * From: xen-unstable 10676:af9809f51f81a3c43f276f00c81a52ef558afda4
59 * location, that this location is the given linear faulting address (cr2), and
62 * automatically deduces which operand of a string-move operation is accessing
73 * some out-of-band mechanism, unknown to the emulator. The memop signals
77 * cmpxchg8b_emulated need support 8-byte accesses.
78 * 4. The emulator cannot handle 64-bit mode emulation on an x86/32 system.
91 /* x86-specific emulation flags */
100 * read_gpr: read a general purpose register (rax - r15)
106 * write_gpr: write a general purpose register (rax - r15)
113 * read_std: Read bytes of standard (non-emulated/special) memory.
115 * @addr: [IN ] Linear address from which to read.
116 * @val: [OUT] Value read from memory, zero-extended to 'u_long'.
126 * write_std: Write bytes of standard (non-emulated/special) memory.
128 * @addr: [IN ] Linear address to which to write.
129 * @val: [OUT] Value write to memory, zero-extended to 'u_long'.
137 * fetch: Read bytes of standard (non-emulated/special) memory.
139 * @addr: [IN ] Linear address from which to read.
140 * @val: [OUT] Value read from memory, zero-extended to 'u_long'.
149 * @addr: [IN ] Linear address from which to read.
150 * @val: [OUT] Value read from memory, zero-extended to 'u_long'.
159 * @addr: [IN ] Linear address to which to write.
160 * @val: [IN ] Value to write to memory (low-order bytes used as
172 * @addr: [IN ] Linear address to access.
238 /* Type, address-of, and value of an instruction's operand. */
282 X86EMUL_MODE_PROT16, /* 16-bit protected mode. */
283 X86EMUL_MODE_PROT32, /* 32-bit protected mode. */
284 X86EMUL_MODE_PROT64, /* 64-bit (long) mode. */
288 * fastop functions are declared as taking a never-defined fastop parameter,
382 ctxt->ops->vm_bugged(ctxt); \
436 X86_ICTP_NONE = 0, /* Allow zero-init to not match anything */
505 #define EMULATION_FAILED -1
522 nr &= NR_EMULATOR_GPRS - 1; in reg_read()
524 if (!(ctxt->regs_valid & (1 << nr))) { in reg_read()
525 ctxt->regs_valid |= 1 << nr; in reg_read()
526 ctxt->_regs[nr] = ctxt->ops->read_gpr(ctxt, nr); in reg_read()
528 return ctxt->_regs[nr]; in reg_read()
534 nr &= NR_EMULATOR_GPRS - 1; in reg_write()
536 BUILD_BUG_ON(sizeof(ctxt->regs_dirty) * BITS_PER_BYTE < NR_EMULATOR_GPRS); in reg_write()
537 BUILD_BUG_ON(sizeof(ctxt->regs_valid) * BITS_PER_BYTE < NR_EMULATOR_GPRS); in reg_write()
539 ctxt->regs_valid |= 1 << nr; in reg_write()
540 ctxt->regs_dirty |= 1 << nr; in reg_write()
541 return &ctxt->_regs[nr]; in reg_write()