Merge pull request #6944 from leoetlino/init-fs-contents
Move Wii FS content init to happen after Boot
This commit is contained in:
commit
da03ff2e25
|
@ -517,6 +517,12 @@ static void EmuThread(std::unique_ptr<BootParameters> boot)
|
||||||
if (!CBoot::BootUp(std::move(boot)))
|
if (!CBoot::BootUp(std::move(boot)))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
// Initialise Wii filesystem contents.
|
||||||
|
// This is done here after Boot and not in HW to ensure that we operate
|
||||||
|
// with the correct title context since save copying requires title directories to exist.
|
||||||
|
Common::ScopeGuard wiifs_guard{Core::CleanUpWiiFileSystemContents};
|
||||||
|
Core::InitializeWiiFileSystemContents();
|
||||||
|
|
||||||
// This adds the SyncGPU handler to CoreTiming, so now CoreTiming::Advance might block.
|
// This adds the SyncGPU handler to CoreTiming, so now CoreTiming::Advance might block.
|
||||||
Fifo::Prepare();
|
Fifo::Prepare();
|
||||||
|
|
||||||
|
|
|
@ -54,13 +54,11 @@ void Init()
|
||||||
Core::InitializeWiiRoot(Core::WantsDeterminism());
|
Core::InitializeWiiRoot(Core::WantsDeterminism());
|
||||||
IOS::Init();
|
IOS::Init();
|
||||||
IOS::HLE::Init(); // Depends on Memory
|
IOS::HLE::Init(); // Depends on Memory
|
||||||
Core::InitializeWiiFileSystemContents();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Shutdown()
|
void Shutdown()
|
||||||
{
|
{
|
||||||
Core::CleanUpWiiFileSystemContents();
|
|
||||||
// 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();
|
||||||
|
|
Loading…
Reference in New Issue