WFSI: Get the patch info from PREPARE_DEVICE.

This commit is contained in:
Pierre Bourdon 2017-08-17 03:56:26 +02:00
parent e004709b69
commit 5ed3a3f12d
2 changed files with 8 additions and 2 deletions

View File

@ -98,9 +98,11 @@ IPCCommandResult WFSI::IOCtl(const IOCtlRequest& request)
u32 tmd_addr = Memory::Read_U32(request.buffer_in); u32 tmd_addr = Memory::Read_U32(request.buffer_in);
u32 tmd_size = Memory::Read_U32(request.buffer_in + 4); u32 tmd_size = Memory::Read_U32(request.buffer_in + 4);
m_patch_type = Memory::Read_U32(request.buffer_in + 32);
m_continue_install = Memory::Read_U32(request.buffer_in + 36); m_continue_install = Memory::Read_U32(request.buffer_in + 36);
INFO_LOG(IOS_WFS, "IOCTL_WFSI_PREPARE_DEVICE"); INFO_LOG(IOS_WFS, "IOCTL_WFSI_PREPARE_DEVICE: patch type %d, continue install: %s",
m_patch_type, m_continue_install ? "true" : "false");
constexpr u32 MAX_TMD_SIZE = 0x4000; constexpr u32 MAX_TMD_SIZE = 0x4000;
if (tmd_size > MAX_TMD_SIZE) if (tmd_size > MAX_TMD_SIZE)

View File

@ -60,7 +60,11 @@ private:
// Set on PREPARE_DEVICE when the next profile application should not delete // Set on PREPARE_DEVICE when the next profile application should not delete
// temporary install files. // temporary install files.
u32 m_continue_install = 0; bool m_continue_install = false;
// Set on PREPARE_DEVICE to indicate that the install is a patch and not a
// standalone title.
u32 m_patch_type = 0;
ARCUnpacker m_arc_unpacker; ARCUnpacker m_arc_unpacker;