From: Nadav Amit Date: Sun, 2 Nov 2014 09:54:46 +0000 (+0200) Subject: KVM: x86: Emulation of MOV-sreg to memory uses incorrect size X-Git-Tag: omap-for-v3.19/fixes-rc1~43^2~83 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b5bbf10ee6b65b70c10c139822bc2dc077cefa76;p=pandora-kernel.git KVM: x86: Emulation of MOV-sreg to memory uses incorrect size In x86, you can only MOV-sreg to memory with either 16-bits or 64-bits size. In contrast, KVM may write to 32-bits memory on MOV-sreg. This patch fixes KVM behavior, and sets the destination operand size to two, if the destination is memory. When destination is registers, and the operand size is 32-bits, the high 16-bits in modern CPUs is filled with zero. This is handled correctly. Signed-off-by: Nadav Amit Signed-off-by: Paolo Bonzini --- Reading git-diff-tree failed