mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-04 14:08:37 +00:00
[orbis-kernel] store sdk version to the context
This commit is contained in:
parent
a847e739fc
commit
dc44b619b2
3 changed files with 15 additions and 11 deletions
|
|
@ -159,6 +159,7 @@ public:
|
|||
Ref<RcBase> dmemDevice;
|
||||
Ref<RcBase> blockpoolDevice;
|
||||
AudioOut *audioOut = nullptr;
|
||||
uint sdkVersion{};
|
||||
|
||||
private:
|
||||
mutable pthread_mutex_t m_heap_mtx;
|
||||
|
|
|
|||
|
|
@ -372,17 +372,8 @@ orbis::SysResult orbis::sys___sysctl(Thread *thread, ptr<sint> name,
|
|||
return ErrorCode::INVAL;
|
||||
}
|
||||
|
||||
auto processParam =
|
||||
reinterpret_cast<std::byte *>(thread->tproc->processParam);
|
||||
|
||||
auto sdkVersion = processParam //
|
||||
+ sizeof(uint64_t) // size
|
||||
+ sizeof(uint32_t) // magic
|
||||
+ sizeof(uint32_t); // entryCount
|
||||
|
||||
std::printf("Reporting SDK version %x\n",
|
||||
*reinterpret_cast<uint32_t *>(sdkVersion));
|
||||
*(uint32_t *)old = *reinterpret_cast<uint32_t *>(sdkVersion);
|
||||
std::printf("Reporting SDK version %x\n", g_context.sdkVersion);
|
||||
*(uint32_t *)old = g_context.sdkVersion;
|
||||
return {};
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue