From eb6f052873aee67168a452e2afaff2657293e154 Mon Sep 17 00:00:00 2001 From: Billy Laws Date: Sat, 23 Oct 2021 14:40:42 +0100 Subject: [PATCH] Fixup GpuChannel::SetNvmapFd to take an FD rather than an nvmap handle --- .../skyline/services/nvdrv/devices/nvhost/gpu_channel.cpp | 6 +++--- .../cpp/skyline/services/nvdrv/devices/nvhost/gpu_channel.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/gpu_channel.cpp b/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/gpu_channel.cpp index 50f57eff..f3b6066a 100644 --- a/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/gpu_channel.cpp +++ b/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/gpu_channel.cpp @@ -65,8 +65,8 @@ namespace skyline::service::nvdrv::device::nvhost { mem[offset++] = (fence.id << 8) | 0x1; } - PosixResult GpuChannel::SetNvmapFd(In id) { - state.logger->Debug("id: {}", id); + PosixResult GpuChannel::SetNvmapFd(In fd) { + state.logger->Debug("fd: {}", fd); return PosixResult::Success; } @@ -224,7 +224,7 @@ namespace skyline::service::nvdrv::device::nvhost { VARIABLE_IOCTL_HANDLER_FUNC(GpuChannel, ({ IOCTL_CASE_ARGS(IN, SIZE(0x4), MAGIC(GpuChannelMagic), FUNC(0x1), - SetNvmapFd, ARGS(In)) + SetNvmapFd, ARGS(In)) IOCTL_CASE_ARGS(IN, SIZE(0x4), MAGIC(GpuChannelMagic), FUNC(0x3), SetTimeout, ARGS(In)) IOCTL_CASE_ARGS(INOUT, SIZE(0x10), MAGIC(GpuChannelMagic), FUNC(0x9), diff --git a/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/gpu_channel.h b/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/gpu_channel.h index 5207dbb5..07090021 100644 --- a/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/gpu_channel.h +++ b/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/gpu_channel.h @@ -57,7 +57,7 @@ namespace skyline::service::nvdrv::device::nvhost { * @brief Sets the nvmap handle id to be used for channel submits (does nothing for GPU channels) * @url https://switchbrew.org/wiki/NV_services#NVGPU_IOCTL_CHANNEL_SET_NVMAP_FD */ - PosixResult SetNvmapFd(In id); + PosixResult SetNvmapFd(In id); /** * @brief Sets the timeout for channel submits