summaryrefslogtreecommitdiffstats
path: root/src/core
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2020-10-31 09:22:53 +0100
committerbunnei <bunneidev@gmail.com>2020-10-31 09:22:53 +0100
commita0e5cccb9298aa95012494ee7196d28fef6f48b0 (patch)
tree837765b9ed7b33924eef955b9d2815e48f448410 /src/core
parentMerge pull request #4872 from jbeich/clang (diff)
downloadyuzu-a0e5cccb9298aa95012494ee7196d28fef6f48b0.tar
yuzu-a0e5cccb9298aa95012494ee7196d28fef6f48b0.tar.gz
yuzu-a0e5cccb9298aa95012494ee7196d28fef6f48b0.tar.bz2
yuzu-a0e5cccb9298aa95012494ee7196d28fef6f48b0.tar.lz
yuzu-a0e5cccb9298aa95012494ee7196d28fef6f48b0.tar.xz
yuzu-a0e5cccb9298aa95012494ee7196d28fef6f48b0.tar.zst
yuzu-a0e5cccb9298aa95012494ee7196d28fef6f48b0.zip
Diffstat (limited to 'src/core')
-rw-r--r--src/core/hle/service/ldr/ldr.cpp16
1 files changed, 15 insertions, 1 deletions
diff --git a/src/core/hle/service/ldr/ldr.cpp b/src/core/hle/service/ldr/ldr.cpp
index 9ad5bbf0d..eeaca44b6 100644
--- a/src/core/hle/service/ldr/ldr.cpp
+++ b/src/core/hle/service/ldr/ldr.cpp
@@ -166,7 +166,7 @@ public:
{0, &RelocatableObject::LoadNro, "LoadNro"},
{1, &RelocatableObject::UnloadNro, "UnloadNro"},
{2, &RelocatableObject::LoadNrr, "LoadNrr"},
- {3, nullptr, "UnloadNrr"},
+ {3, &RelocatableObject::UnloadNrr, "UnloadNrr"},
{4, &RelocatableObject::Initialize, "Initialize"},
{10, nullptr, "LoadNrrEx"},
};
@@ -272,6 +272,20 @@ public:
rb.Push(RESULT_SUCCESS);
}
+ void UnloadNrr(Kernel::HLERequestContext& ctx) {
+ IPC::RequestParser rp{ctx};
+ const auto pid = rp.Pop<u64>();
+ const auto nrr_address = rp.Pop<VAddr>();
+
+ LOG_DEBUG(Service_LDR, "called with pid={}, nrr_address={:016X}", pid, nrr_address);
+
+ nrr.erase(nrr_address);
+
+ IPC::ResponseBuilder rb{ctx, 2};
+
+ rb.Push(RESULT_SUCCESS);
+ }
+
bool ValidateRegionForMap(Kernel::Memory::PageTable& page_table, VAddr start,
std::size_t size) const {
constexpr std::size_t padding_size{4 * Kernel::Memory::PageSize};