bunnei
eeb8d0def8
hle: kernel: KServerSession: Use ASSERT_MSG where appropriate.
5 years ago
bunnei
ff57fd7281
hle: kernel: k_server_session: Return service thread by strong pointer.
5 years ago
bunnei
c833ca5fa0
hle: kernel: k_server_session: Ensure service thread is valid before dereference.
5 years ago
bunnei
ea1ca74e7a
hle: kernel: hle_ipc: Use default destructor for SessionRequestManager.
5 years ago
bunnei
38d8bcc574
hle: kernel: KAutoObjectWithListContainer: Use boost::instrusive::rbtree.
- Fixes some crashes introduced by our common intrusive red/black tree impl.
5 years ago
bunnei
8bf7b19d1d
hle: kernel: Refactor to allocate a ServiceThread per service handler.
- 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 .
5 years ago
Morph
c4d6d9dfd3
general: Replace RESULT_UNKNOWN with ResultUnknown
Transition to PascalCase for result names.
5 years ago
Morph
7ebc38a6d1
general: Replace RESULT_SUCCESS with ResultSuccess
Transition to PascalCase for result names.
5 years ago
Lioncash
2197782ecd
k_class_token: Use variable templates where applicable
Same behavior, less code.
5 years ago
Lioncash
a9fcaa9c00
kernel: Add missing override specifiers
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.
5 years ago
Markus Wick
9f92beed0a
Fix two GCC 11 warnings: Unneeded copies.
std::move created an unneeded copy.
iterating without reference also created copies.
5 years ago
Lioncash
2d390c1911
k_thread: Move dereference after null check in Initialize()
Prevents a -Wnonnull warning on GCC.
5 years ago
bunnei
639baf88f7
hle: kernel: KSlabHeap: Allow host or guest allocations.
- 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.
5 years ago
Markus Wick
c9f9e77be3
core/arm_interface: Call SVC after end of dynarmic block.
So we can modify all of dynarmic states within SVC without ExceptionalExit.
Especially as the ExceptionalExit hack is dropped on upstream dynarmic.
5 years ago
Morph
5eecd49108
kernel: process_capability: Add MapRegion capability
- Used by nx-hbloader
5 years ago
bunnei
9d19382daf
hle: kernel: service_thread: Take reference to KServerSession on service request.
5 years ago
bunnei
ea851aaeb8
hle: kernel: k_port: Use AcceptSession to ensure SessionList state is correct.
- Fixes a use-after-free, work-around until we fixup session/port management.
5 years ago
bunnei
227f9e5ab2
hle: kernel: Use host memory allocations for KSlabMemory.
- There are some issues with the current workaround, we will just use host memory until we have a complete kernel memory implementation.
5 years ago
bunnei
78853f888a
Revert "WORKAROUND: Do not use slab heap while we track down issues with resource management."
This reverts commit bb77b5d79f .
5 years ago
bunnei
14f50729e2
hle: kernel: hle_ipc: Simplify incoming/outgoing move/copy/domain objects.
5 years ago
bunnei
6e3c9d2b06
hle: kernel: Implement CloneCurrentObject and improve session management.
5 years ago
bunnei
7b1c7a5e6a
Revert "WORKAROUND: temp. disable session resource limits while we work out issues"
This reverts commit 627eaf8c0e .
5 years ago
Morph
bf87c33d40
KTransferMemory: Return size instead of size * PageSize in GetSize()
size is already the size in bytes. We do not need to multiply it by the page size
5 years ago
Morph
c4f16c8e14
hle_ipc: unsigned -> u32
This is more concise and consistent with the rest of the codebase.
5 years ago
Morph
29ce6e48ed
hle_ipc: Add a getter for PID
5 years ago
Lioncash
eeae5217ba
core: Make variable shadowing a compile-time error
Now that we have most of core free of shadowing, we can enable the
warning as an error to catch anything that may be remaining and also
eliminate this class of logic bug entirely.
5 years ago
bunnei
006a51c86b
hle: kernel: hle_ipc: Fix outgoing IPC response size calculation.
5 years ago
bunnei
627eaf8c0e
WORKAROUND: temp. disable session resource limits while we work out issues
5 years ago
bunnei
bb77b5d79f
WORKAROUND: Do not use slab heap while we track down issues with resource management.
5 years ago
bunnei
232102c794
hle: kernel: hle_ipc: Improve IPC code and add initial support for TIPC.
- Fixes our move handles implementation to actually move objects.
- Simplifies the traditional IPC path.
5 years ago
bunnei
80d920e464
hle: service: Implement IPC::CommandType::Close.
- This was not actually closing sessions before.
5 years ago
bunnei
6e284d951b
hle: kernel: svc: Update ConnectToNamedPort to use new CreateNamedServicePort interface.
5 years ago
bunnei
777e7c52ba
hle: kernel: Implement named service ports using service interface factory.
- This allows us to create a new interface each time ConnectToNamedPort is called, removing the assumption that these are static.
5 years ago
bunnei
2c9d6156d2
hle: kernel: KClientPort: Cleanup comment format.
5 years ago
bunnei
4a781928dd
hle: kernel: Further cleanup and add TIPC helpers.
5 years ago
bunnei
ae86003503
hle: ipc_helpers: Update IPC response generation for TIPC.
5 years ago
german77
1b8951c31b
kernel: Delete unused files
5 years ago
Lioncash
e019da0487
kernel: Eliminate variable shadowing
Now that the large kernel refactor is merged, we can eliminate the
remaining variable shadowing cases.
5 years ago
bunnei
afdbfb884c
hle: kernel: KPageTable: CanContain should not be constexpr.
5 years ago
bunnei
14cb6883db
hle: kernel: Move slab resource counts to Kernel.
5 years ago
bunnei
37338198be
fixup! hle: kernel: Migrate more of KThread to KAutoObject.
5 years ago
bunnei
4ebb8f0dfe
kernel: svc: Remove unused RetrieveResourceLimitValue function.
5 years ago
bunnei
89966df98c
hle: kernel: Fix un/sign mismatch errors with NUM_CPU_CORES.
5 years ago
bunnei
fd11e0722b
fixup! hle: kernel: Add initial impl. of slab setup.
5 years ago
bunnei
7341a973df
fixup! hle: kernel: Migrate to KHandleTable.
5 years ago
bunnei
464b640058
fixup! hle: kernel: Migrate more of KThread to KAutoObject.
5 years ago
bunnei
3fa3fa47e5
fixup! hle: kernel: Migrate KReadableEvent and KWritableEvent to KAutoObject.
5 years ago
bunnei
a50cc0c3f8
fixup! hle: kernel: Migrate to KHandleTable.
5 years ago
bunnei
9536ae2f2e
fixup! hle: kernel: Add initial impl. of KLinkedList.
5 years ago
bunnei
a4fc003902
fixup! hle: kernel: Migrate to KHandleTable.
5 years ago