target-i386: Ensure bit 10 on DR7 is never cleared

Bit 10 of DR7 is documented as always set to 1, so ensure that's
always the case.

Backports commit 9055330ffbf5ca85f024c29874799d9c8bd17aa9 from qemu
This commit is contained in:
Eduardo Habkost 2018-02-16 16:08:38 -05:00 committed by Lioncash
parent 77b129a1c6
commit e88063fa05
No known key found for this signature in database
GPG key ID: 4E3C3CC1031BA9C7

View file

@ -84,6 +84,8 @@ void cpu_x86_update_dr7(CPUX86State *env, uint32_t new_dr7)
int i;
target_ulong old_dr7 = env->dr[7];
new_dr7 |= DR7_FIXED_1;
/* If nothing is changing except the global/local enable bits,
then we can make the change more efficient. */
if (((old_dr7 ^ new_dr7) & ~0xff) == 0) {