Make sure hardware registers are manipulated as little-endian
[pcsx_rearmed.git] / libpcsxcore / gpu.h
index 63a5572..9dfe634 100644 (file)
@@ -35,6 +35,6 @@
 #define PSXGPU_TIMING_BITS (PSXGPU_LCF | PSXGPU_nBUSY)
 
 #define gpuSyncPluginSR() { \
-       HW_GPU_STATUS &= PSXGPU_TIMING_BITS; \
-       HW_GPU_STATUS |= GPU_readStatus() & ~PSXGPU_TIMING_BITS; \
+       HW_GPU_STATUS &= SWAP32(PSXGPU_TIMING_BITS); \
+       HW_GPU_STATUS |= SWAP32(GPU_readStatus() & ~PSXGPU_TIMING_BITS); \
 }