From 5d8d696185358e8c65fd16acc935ad1b54f1188d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9o=20Lam?= Date: Sun, 25 Sep 2016 13:45:07 +0200 Subject: [PATCH] Force disable WC24 standby mode MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When standby mode is enabled, this causes games to ES_Launch the system menu instead of directly asking IOS (the STM more precisely) to shut down, which prevents graceful shutdown from working (it'll appear to hang). Dolphin never supported WC24 standby mode anyway, so this shouldn't cause any issues. (This should be reverted if and when WC24 standby is implemented…) --- Source/Core/Common/SysConf.cpp | 2 +- Source/Core/Core/BootManager.cpp | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/Source/Core/Common/SysConf.cpp b/Source/Core/Common/SysConf.cpp index 980318c06b..6bf6d950ea 100644 --- a/Source/Core/Common/SysConf.cpp +++ b/Source/Core/Common/SysConf.cpp @@ -310,7 +310,7 @@ void SysConf::GenerateSysConf() // IPL.IDL current_offset += create_item(items[23], Type_SmallArray, "IPL.IDL", 1, current_offset); - items[23].data[0] = 0x01; + items[23].data[0] = 0x00; // IPL.EULA current_offset += create_item(items[24], Type_Bool, "IPL.EULA", 1, current_offset); diff --git a/Source/Core/Core/BootManager.cpp b/Source/Core/Core/BootManager.cpp index f7651b5bce..6370bbf9d1 100644 --- a/Source/Core/Core/BootManager.cpp +++ b/Source/Core/Core/BootManager.cpp @@ -392,6 +392,15 @@ bool BootCore(const std::string& _rFilename) SConfig::GetInstance().m_SYSCONF->SetData("IPL.PGS", StartUp.bProgressive); SConfig::GetInstance().m_SYSCONF->SetData("IPL.E60", StartUp.bPAL60); + if (StartUp.bWii) + { + // Disable WiiConnect24's standby mode. If it is enabled, it prevents us from receiving + // shutdown commands in the State Transition Manager (STM). + // TODO: remove this if and once Dolphin supports WC24 standby mode. + SConfig::GetInstance().m_SYSCONF->SetData("IPL.IDL", 0x00); + NOTICE_LOG(BOOT, "Disabling WC24 'standby' (shutdown to idle) to avoid hanging on shutdown"); + } + // Run the game // Init the core if (!Core::Init())