Re: [PATCH] target/i386: seg_helper: Correct segement selector nullification in the RET/IRET helper

2020-11-12 Thread Paolo Bonzini
On 22/10/20 12:16, Bin Meng wrote: From: Bin Meng Per the SDM, when returning to outer privilege level, for segment registers (ES, FS, GS, and DS) if the check fails, the segment selector becomes null, but QEMU clears the base/limit/flags as well as nullifying the segment selector, which should

Re: [PATCH] target/i386: seg_helper: Correct segement selector nullification in the RET/IRET helper

2020-11-11 Thread Bin Meng
On Mon, Nov 2, 2020 at 4:20 PM Bin Meng wrote: > > On Thu, Oct 22, 2020 at 6:16 PM Bin Meng wrote: > > > > From: Bin Meng > > > > Per the SDM, when returning to outer privilege level, for segment > > registers (ES, FS, GS, and DS) if the check fails, the segment > > selector becomes null, but QE

Re: [PATCH] target/i386: seg_helper: Correct segement selector nullification in the RET/IRET helper

2020-11-02 Thread Bin Meng
On Thu, Oct 22, 2020 at 6:16 PM Bin Meng wrote: > > From: Bin Meng > > Per the SDM, when returning to outer privilege level, for segment > registers (ES, FS, GS, and DS) if the check fails, the segment > selector becomes null, but QEMU clears the base/limit/flags as well > as nullifying the segme

[PATCH] target/i386: seg_helper: Correct segement selector nullification in the RET/IRET helper

2020-10-22 Thread Bin Meng
From: Bin Meng Per the SDM, when returning to outer privilege level, for segment registers (ES, FS, GS, and DS) if the check fails, the segment selector becomes null, but QEMU clears the base/limit/flags as well as nullifying the segment selector, which should be a spec violation. Real hardware