diff --git a/Source/Core/Core/IOS/SDIO/SDIOSlot0.cpp b/Source/Core/Core/IOS/SDIO/SDIOSlot0.cpp index d75135d5b9..a832c66b38 100644 --- a/Source/Core/Core/IOS/SDIO/SDIOSlot0.cpp +++ b/Source/Core/Core/IOS/SDIO/SDIOSlot0.cpp @@ -61,6 +61,8 @@ void SDIOSlot0::DoState(PointerWrap& p) p.Do(m_block_length); p.Do(m_bus_width); p.Do(m_registers); + p.Do(m_protocol); + p.Do(m_sdhc_supported); } void SDIOSlot0::EventNotify() @@ -501,7 +503,7 @@ u32 SDIOSlot0::GetOCRegister() const return ocr; } -std::array SDIOSlot0::GetCSDv1() +std::array SDIOSlot0::GetCSDv1() const { u64 size = m_card.GetSize(); @@ -577,13 +579,13 @@ std::array SDIOSlot0::GetCSDv1() constexpr u32 crc = 0; // Form the csd using the description above - return { + return {{ 0x007f003, 0x5b5f8000 | (c_size >> 2), 0x3ffc7f80 | (c_size << 30) | (c_size_mult << 15), 0x07c04001 | (crc << 1), - }; + }}; } -std::array SDIOSlot0::GetCSDv2() +std::array SDIOSlot0::GetCSDv2() const { const u64 size = m_card.GetSize(); @@ -632,9 +634,9 @@ std::array SDIOSlot0::GetCSDv2() constexpr u32 crc = 0; // Form the csd using the description above - return { + return {{ 0x400e005a, 0x5f590000 | (c_size >> 16), 0x00007f80 | (c_size << 16), 0x0a400001 | (crc << 1), - }; + }}; } u64 SDIOSlot0::GetAddressFromRequest(u32 arg) const diff --git a/Source/Core/Core/IOS/SDIO/SDIOSlot0.h b/Source/Core/Core/IOS/SDIO/SDIOSlot0.h index 6f0f0255c6..ee6e3115e0 100644 --- a/Source/Core/Core/IOS/SDIO/SDIOSlot0.h +++ b/Source/Core/Core/IOS/SDIO/SDIOSlot0.h @@ -145,8 +145,8 @@ private: u32 GetOCRegister() const; - std::array GetCSDv1(); - std::array GetCSDv2(); + std::array GetCSDv1() const; + std::array GetCSDv2() const; void InitSDHC(); u64 GetAddressFromRequest(u32 arg) const; diff --git a/Source/Core/Core/State.cpp b/Source/Core/Core/State.cpp index 9af7b25439..73ce9271af 100644 --- a/Source/Core/Core/State.cpp +++ b/Source/Core/Core/State.cpp @@ -73,7 +73,7 @@ static Common::Event g_compressAndDumpStateSyncEvent; static std::thread g_save_thread; // Don't forget to increase this after doing changes on the savestate system -static const u32 STATE_VERSION = 88; // Last changed in PR 5733 +static const u32 STATE_VERSION = 89; // Last changed in PR 5890 // Maps savestate versions to Dolphin versions. // Versions after 42 don't need to be added to this list,