diff --git a/app/src/main/cpp/skyline/services/nvdrv/INvDrvServices.cpp b/app/src/main/cpp/skyline/services/nvdrv/INvDrvServices.cpp index 7cc0925a..f3e1d2c5 100644 --- a/app/src/main/cpp/skyline/services/nvdrv/INvDrvServices.cpp +++ b/app/src/main/cpp/skyline/services/nvdrv/INvDrvServices.cpp @@ -7,12 +7,12 @@ #include "driver.h" #include "devices/nvdevice.h" -#define NVRESULT(x) [&response, this](NvResult err) { \ - if (err != NvResult::Success) \ - state.logger->Debug("IOCTL Failed: {}", err); \ - \ - response.Push(err); \ - return Result{}; \ +#define NVRESULT(x) [&response, this](NvResult err) { \ + if (err != NvResult::Success) \ + state.logger->Debug("IOCTL Failed: 0x{:X}", err); \ + \ + response.Push(err); \ + return Result{}; \ } (x) namespace skyline::service::nvdrv { diff --git a/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/ctrl_gpu.cpp b/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/ctrl_gpu.cpp index eeaee9f3..f78810a1 100644 --- a/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/ctrl_gpu.cpp +++ b/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/ctrl_gpu.cpp @@ -77,5 +77,12 @@ namespace skyline::service::nvdrv::device::nvhost { IOCTL_CASE_ARGS(OUT, SIZE(0x8), MAGIC(CtrlGpuMagic), FUNC(0x14), GetActiveSlotMask, ARGS(Out, Out)) })) + + INLINE_IOCTL_HANDLER_FUNC(Ioctl3, CtrlGpu, ({ + INLINE_IOCTL_CASE_ARGS(INOUT, SIZE(0xB0), MAGIC(CtrlGpuMagic), FUNC(0x5), + GetCharacteristics3, ARGS(InOut, In, Out)) + INLINE_IOCTL_CASE_ARGS(INOUT, SIZE(0x18), MAGIC(CtrlGpuMagic), FUNC(0x6), + GetTpcMasks3, ARGS(In, Pad, Out)) + })) #include } diff --git a/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/ctrl_gpu.h b/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/ctrl_gpu.h index 1183bb86..2c202c6b 100644 --- a/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/ctrl_gpu.h +++ b/app/src/main/cpp/skyline/services/nvdrv/devices/nvhost/ctrl_gpu.h @@ -118,5 +118,7 @@ namespace skyline::service::nvdrv::device::nvhost { std::shared_ptr QueryEvent(u32 eventId) override; PosixResult Ioctl(IoctlDescriptor cmd, span buffer) override; + + PosixResult Ioctl3(IoctlDescriptor cmd, span buffer, span inlineBuffer) override; }; }