VirtualBox

Changeset 47328 in vbox for trunk/include/iprt


Ignore:
Timestamp:
Jul 22, 2013 10:50:49 PM (11 years ago)
Author:
vboxsync
Message:

CPUM,++: Fix DR6 and DR7 read-as-1 (RA1) and read-as-zero (RAZ) values on load since REM didn't set them right for years. Introduced constants for these values.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/iprt/x86.h

    r47305 r47328  
    745745/** Value of DR6 after powerup/reset. */
    746746#define X86_DR6_INIT_VAL                    UINT64_C(0xFFFF0FF0)
     747/** Bits which must be 1s in DR6. */
     748#define X86_DR6_RA1_MASK                    UINT64_C(0xffff0ff0)
     749/** Bits which must be 0s in DR6. */
     750#define X86_DR6_RAZ_MASK                    RT_BIT_64(12)
     751/** Bits which must be 0s on writes to DR6. */
     752#define X86_DR6_MBZ_MASK                    UINT64_C(0xffffffff00000000)
    747753/** @} */
    748754
     
    791797#define X86_DR7_LEN3_MASK                   (3 << 30)
    792798
    793 /** Bits which must be 1s. */
    794 #define X86_DR7_MB1_MASK                    (RT_BIT(10))
     799/** Bits which reads as 1s. */
     800#define X86_DR7_RA1_MASK                    (RT_BIT(10))
     801/** Bits which reads as zeros. */
     802#define X86_DR7_RAZ_MASK                    UINT64_C(0x0000d800)
     803/** Bits which must be 0s when writing to DR7. */
     804#define X86_DR7_MBZ_MASK                    UINT64_C(0xffffffff00000000)
    795805
    796806/** Calcs the L bit of Nth breakpoint.
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette