mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-10 16:19:28 +01:00
Initialise WiiRoot once per emulation session
This removes unnecessary initialisations which would cause issues in determinism mode.
This commit is contained in:
parent
94ba78d717
commit
f5ef060b21
@ -8,6 +8,7 @@
|
|||||||
#include "Common/CommonTypes.h"
|
#include "Common/CommonTypes.h"
|
||||||
|
|
||||||
#include "Core/ConfigManager.h"
|
#include "Core/ConfigManager.h"
|
||||||
|
#include "Core/Core.h"
|
||||||
#include "Core/CoreTiming.h"
|
#include "Core/CoreTiming.h"
|
||||||
#include "Core/HW/AudioInterface.h"
|
#include "Core/HW/AudioInterface.h"
|
||||||
#include "Core/HW/CPU.h"
|
#include "Core/HW/CPU.h"
|
||||||
@ -23,6 +24,7 @@
|
|||||||
#include "Core/HW/WII_IPC.h"
|
#include "Core/HW/WII_IPC.h"
|
||||||
#include "Core/IOS/IOS.h"
|
#include "Core/IOS/IOS.h"
|
||||||
#include "Core/State.h"
|
#include "Core/State.h"
|
||||||
|
#include "Core/WiiRoot.h"
|
||||||
|
|
||||||
namespace HW
|
namespace HW
|
||||||
{
|
{
|
||||||
@ -48,6 +50,8 @@ void Init()
|
|||||||
|
|
||||||
if (SConfig::GetInstance().bWii)
|
if (SConfig::GetInstance().bWii)
|
||||||
{
|
{
|
||||||
|
// The NAND should only be initialised once per emulation session.
|
||||||
|
Core::InitializeWiiRoot(Core::WantsDeterminism());
|
||||||
IOS::Init();
|
IOS::Init();
|
||||||
IOS::HLE::Init(); // Depends on Memory
|
IOS::HLE::Init(); // Depends on Memory
|
||||||
}
|
}
|
||||||
@ -58,6 +62,7 @@ void Shutdown()
|
|||||||
// IOS should always be shut down regardless of bWii because it can be running in GC mode (MIOS).
|
// IOS should always be shut down regardless of bWii because it can be running in GC mode (MIOS).
|
||||||
IOS::HLE::Shutdown(); // Depends on Memory
|
IOS::HLE::Shutdown(); // Depends on Memory
|
||||||
IOS::Shutdown();
|
IOS::Shutdown();
|
||||||
|
Core::ShutdownWiiRoot();
|
||||||
|
|
||||||
SystemTimers::Shutdown();
|
SystemTimers::Shutdown();
|
||||||
CPU::Shutdown();
|
CPU::Shutdown();
|
||||||
|
@ -212,8 +212,6 @@ EmulationKernel::EmulationKernel(u64 title_id) : Kernel(title_id)
|
|||||||
if (!SetupMemory(title_id, MemorySetupType::IOSReload))
|
if (!SetupMemory(title_id, MemorySetupType::IOSReload))
|
||||||
WARN_LOG(IOS, "No information about this IOS -- cannot set up memory values");
|
WARN_LOG(IOS, "No information about this IOS -- cannot set up memory values");
|
||||||
|
|
||||||
Core::InitializeWiiRoot(Core::WantsDeterminism());
|
|
||||||
|
|
||||||
if (title_id == Titles::MIOS)
|
if (title_id == Titles::MIOS)
|
||||||
{
|
{
|
||||||
MIOS::Load();
|
MIOS::Load();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user