- Prevents a cloned session's handler from being overwritten by another disconnected session.
- Fixes session handler nullptr asserts with Pokemon Sword & Shield.
- We no longer need to queue up service threads to be destroyed.
- Fixes a race condition where a thread could be destroyed too early, which caused a crash in Pokemon Sword/Shield.
The result code classes are used quite extensively throughout both the
kernel and service HLE code. We can mark these member functions as
[[nodiscard]] to prevent a few logic bugs from slipping through.
- Previously, we would allocate a thread per session, which adds new threads on CloneCurrentObject.
- This results in race conditions with N sessions queuing requests to the same service interface.
- Fixes Pokken Tournament DX crashes/softlocks, which were regressed by #6347.
These macros all interact with the result code type, so they should
ideally be within this file as well, so all the common_funcs machinery
doesn't need to be pulled in just to use them.
ldn: Add and stub lp2p:sys lp2p:app INetworkServiceMonitor INetworkService
Mario Kart Live: Home Circuit needs lp2p:sys lp2p:app INetworkServiceMonitor INetworkService to be able to progress.
Note: The game still fails to boot from unimplemented LDN and BSD services.
We just create one memory subsystem. This is a constant all the time.
So there is no need to call the non-inlined parent.Memory() helper on every callback.
Over the course of the kernel refactoring a tiny bit of missing
overrides slipped through review, so we can add these.
While we're at it, we can remove redundant virtual keywords where
applicable as well.
- Use host allocations for kernel memory, as this is not properly emulated yet.
- Use guest allocations for TLS, as this needs to be backed by DeviceMemory.
Applications may leave this region of memory uninitialized when the text check result is not either Failure or Confirm.
Attempting to read uninitialized memory may cause an exception within the UTF16 to UTF8 string converter.
Fix this by only reading the text check message on Failure or Confirm.
This code was used to switch the CPU ID on thread switches.
However since "hle: kernel: multicore: Replace n-JITs impl. with 4 JITs.", the CPU ID is not a constant.
This has been dead code since this rewrite, and dropped in dynarmic as well. So there is no need to keep it.