mirror of
https://github.com/RPCS3/rpcs3.git
synced 2024-11-23 11:13:19 +01:00
Relax /dev_bdvd mounting requirements
Allow some PSN games with DG category to boot
This commit is contained in:
parent
7f542a5c99
commit
c8a6bc6e24
@ -439,8 +439,10 @@ void Emulator::Load(bool add_only)
|
||||
// Detect boot location
|
||||
const std::string hdd0_game = vfs::get("/dev_hdd0/game/");
|
||||
const std::string hdd0_disc = vfs::get("/dev_hdd0/disc/");
|
||||
const std::size_t bdvd_pos = m_cat == "DG" && bdvd_dir.empty() && disc.empty() ? elf_dir.rfind("/PS3_GAME/") + 1 : 0;
|
||||
const bool from_hdd0_game = m_path.find(hdd0_game) != -1;
|
||||
|
||||
if (m_cat == "DG" && m_path.find(hdd0_game) != -1 && disc.empty())
|
||||
if (bdvd_pos && from_hdd0_game)
|
||||
{
|
||||
// Booting disc game from wrong location
|
||||
LOG_ERROR(LOADER, "Disc game %s found at invalid location /dev_hdd0/game/", m_title_id);
|
||||
@ -459,13 +461,10 @@ void Emulator::Load(bool add_only)
|
||||
}
|
||||
|
||||
// Booting disc game
|
||||
if (m_cat == "DG" && bdvd_dir.empty() && disc.empty())
|
||||
if (bdvd_pos)
|
||||
{
|
||||
// Mount /dev_bdvd/ if necessary
|
||||
if (auto pos = elf_dir.rfind("/PS3_GAME/") + 1)
|
||||
{
|
||||
bdvd_dir = elf_dir.substr(0, pos);
|
||||
}
|
||||
bdvd_dir = elf_dir.substr(0, bdvd_pos);
|
||||
}
|
||||
|
||||
// Booting patch data
|
||||
@ -514,12 +513,12 @@ void Emulator::Load(bool add_only)
|
||||
{
|
||||
// Don't need /dev_bdvd
|
||||
}
|
||||
else if (disc.empty())
|
||||
else if (disc.empty() && !from_hdd0_game)
|
||||
{
|
||||
LOG_ERROR(LOADER, "Failed to mount disc directory for the disc game %s", m_title_id);
|
||||
return;
|
||||
}
|
||||
else
|
||||
else if (!disc.empty())
|
||||
{
|
||||
bdvd_dir = disc;
|
||||
vfs::mount("dev_bdvd", bdvd_dir);
|
||||
|
Loading…
Reference in New Issue
Block a user