Commit 21c04611 authored by Bobby Bingham's avatar Bobby Bingham Committed by Aurelien Jarno
Browse files

target-sh4: move features flag after CPU_COMMON



Everything before CPU_COMMON in the structure is cleared as part of a
CPU reset. This included the features flag, which indicates whether SH4A
instructions are supported or not. As a result, a CPU reset downgraded
the CPU from an SH4A to an SH4.

Signed-off-by: default avatarBobby Bingham <koorogi@koorogi.info>
Reviewed-by: default avatarRichard Henderson <rth@twiddle.net>
Signed-off-by: default avatarAurelien Jarno <aurelien@aurel32.net>
parent a1d22a36
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -157,9 +157,6 @@ typedef struct CPUSH4State {
    /* float point status register */
    float_status fp_status;

    /* The features that we should emulate. See sh_features above.  */
    uint32_t features;

    /* Those belong to the specific unit (SH7750) but are handled here */
    uint32_t mmucr;		/* MMU control register */
    uint32_t pteh;		/* page table entry high register */
@@ -180,6 +177,9 @@ typedef struct CPUSH4State {

    int id;			/* CPU model */

    /* The features that we should emulate. See sh_features above.  */
    uint32_t features;

    void *intc_handle;
    int in_sleep;		/* SR_BL ignored during sleep */
    memory_content *movcal_backup;