diff --git a/rpcs3/Emu/SysCalls/Modules/cellAdec.cpp b/rpcs3/Emu/SysCalls/Modules/cellAdec.cpp index 36c522670a..11b9158bc6 100644 --- a/rpcs3/Emu/SysCalls/Modules/cellAdec.cpp +++ b/rpcs3/Emu/SysCalls/Modules/cellAdec.cpp @@ -609,7 +609,7 @@ int cellAdecQueryAttr(vm::ptr type, vm::ptr attr) // TODO: check values attr->adecVerLower = 0x280000; // from dmux attr->adecVerUpper = 0x260000; - attr->workMemSize = 4194304; // 4MB + attr->workMemSize = 4 * 1024 * 1024; // 4 MB return CELL_OK; } diff --git a/rpcs3/Emu/SysCalls/Modules/cellGem.cpp b/rpcs3/Emu/SysCalls/Modules/cellGem.cpp index 10854f1892..47c5392d16 100644 --- a/rpcs3/Emu/SysCalls/Modules/cellGem.cpp +++ b/rpcs3/Emu/SysCalls/Modules/cellGem.cpp @@ -130,7 +130,7 @@ s32 cellGemGetMemorySize(be_t max_connect) if (max_connect > CELL_GEM_MAX_NUM) return CELL_GEM_ERROR_INVALID_PARAMETER; - return 1048576 * max_connect; // 1MB * max_connect + return 1024 * 1024 * max_connect; // 1 MB * max_connect } int cellGemGetRGB() diff --git a/rpcs3/Emu/SysCalls/Modules/cellSysutil.cpp b/rpcs3/Emu/SysCalls/Modules/cellSysutil.cpp index 1c22cce875..b44866b397 100644 --- a/rpcs3/Emu/SysCalls/Modules/cellSysutil.cpp +++ b/rpcs3/Emu/SysCalls/Modules/cellSysutil.cpp @@ -664,7 +664,7 @@ int cellHddGameCheck(u32 version, vm::ptr dirName, u32 errDialog, vm vm::var get; vm::var set; - get->hddFreeSizeKB = 40 * 1048576; // 40 GB, TODO: Use the free space of the computer's HDD where RPCS3 is being run. + get->hddFreeSizeKB = 40 * 1024 * 1024; // 40 GB, TODO: Use the free space of the computer's HDD where RPCS3 is being run. get->isNewData = CELL_HDDGAME_ISNEWDATA_EXIST; get->sysSizeKB = 0; // TODO get->st_atime__ = 0; // TODO @@ -710,11 +710,10 @@ int cellHddGameCheck(u32 version, vm::ptr dirName, u32 errDialog, vm funcStat(result, get, set); - /* - if (result->result != CELL_HDDGAME_CBRESULT_OK && - result->result != CELL_HDDGAME_CBRESULT_OK_CANCEL) // Error in compiling in MVS. Need to use LE byte order? + if (result->result.ToLE() != CELL_HDDGAME_CBRESULT_OK && + result->result.ToLE() != CELL_HDDGAME_CBRESULT_OK_CANCEL) { return CELL_HDDGAME_ERROR_CBRESULT; - */ + } // TODO ? @@ -794,7 +793,7 @@ int cellWebBrowserEstimate2(const vm::ptr config, v // TODO: When cellWebBrowser stuff is implemented, change this to some real // needed memory buffer size. - *memSize = 1048576; // 1 MB + *memSize = 1 * 1024 * 1024; // 1 MB return CELL_OK; } diff --git a/rpcs3/Emu/SysCalls/Modules/cellVdec.cpp b/rpcs3/Emu/SysCalls/Modules/cellVdec.cpp index 15bca18cc7..0f7fc6b45c 100644 --- a/rpcs3/Emu/SysCalls/Modules/cellVdec.cpp +++ b/rpcs3/Emu/SysCalls/Modules/cellVdec.cpp @@ -174,7 +174,7 @@ u32 vdecQueryAttr(CellVdecCodecType type, u32 profile, u32 spec_addr /* may be 0 // TODO: check values attr->decoderVerLower = 0x280000; // from dmux attr->decoderVerUpper = 0x260000; - attr->memSize = 4194304; // 4MB + attr->memSize = 4 * 1024 * 1024; // 4 MB attr->cmdDepth = 16; return CELL_OK; } diff --git a/rpcs3/Emu/SysCalls/Modules/cellVpost.cpp b/rpcs3/Emu/SysCalls/Modules/cellVpost.cpp index e9be058a25..5944b4f055 100644 --- a/rpcs3/Emu/SysCalls/Modules/cellVpost.cpp +++ b/rpcs3/Emu/SysCalls/Modules/cellVpost.cpp @@ -21,7 +21,7 @@ int cellVpostQueryAttr(vm::ptr cfgParam, vm::ptrdelay = 0; - attr->memSize = 4194304; // 4MB + attr->memSize = 4 * 1024 * 1024; // 4 MB attr->vpostVerLower = 0x280000; // from dmux attr->vpostVerUpper = 0x260000; diff --git a/rpcs3/Emu/SysCalls/lv2/lv2Fs.cpp b/rpcs3/Emu/SysCalls/lv2/lv2Fs.cpp index a66e16a185..8765908b71 100644 --- a/rpcs3/Emu/SysCalls/lv2/lv2Fs.cpp +++ b/rpcs3/Emu/SysCalls/lv2/lv2Fs.cpp @@ -534,7 +534,7 @@ s32 cellFsGetFreeSize(vm::ptr path, vm::ptr> block_size, v // TODO: Get real values. Currently, it always returns 40 GB of free space divided in 4 KB blocks *block_size = 4096; // ? - *block_count = 10485760; // ? + *block_count = 10 * 1024 * 1024; // ? return CELL_OK; } @@ -589,9 +589,13 @@ s32 cellFsStReadInit(u32 fd, vm::ptr ringbuf) fs_config.m_ring_buffer = *ringbuf; - if(ringbuf->ringbuf_size < 0x40000000) // If the size is less than 1MB - fs_config.m_alloc_mem_size = (((u32)ringbuf->ringbuf_size + 65535) / (65536)) * (65536); - fs_config.m_alloc_mem_size = (((u32)ringbuf->ringbuf_size + 1048575) / (1048576)) * (1048576); + // If the size is less than 1MB + if(ringbuf->ringbuf_size < 0x40000000) { + fs_config.m_alloc_mem_size = (((u32)ringbuf->ringbuf_size + 64 * 1024 - 1) / (64 * 1024)) * (64 * 1024); + } + else { + fs_config.m_alloc_mem_size = (((u32)ringbuf->ringbuf_size + 1024 * 1024 - 1) / (1024 * 1024)) * (1024 * 1024); + } // alloc memory fs_config.m_buffer = (u32)Memory.Alloc(fs_config.m_alloc_mem_size, 1024); diff --git a/rpcs3/rpcs3.cpp b/rpcs3/rpcs3.cpp index 09da440a9c..dc40edfd17 100644 --- a/rpcs3/rpcs3.cpp +++ b/rpcs3/rpcs3.cpp @@ -152,11 +152,7 @@ void Rpcs3App::OnArguments() // rpcs3-*.exe Initializes RPCS3 // rpcs3-*.exe [(S)ELF] Initializes RPCS3, then loads and runs the specified (S)ELF file. - if (Rpcs3App::argc > 1) - { - // Force this value to be true - Ini.HLEExitOnStop.SetValue(true); - + if (Rpcs3App::argc > 1) { Emu.SetPath(fmt::ToUTF8(argv[1])); Emu.Load(); Emu.Run();