From 3c37d66c28b7150c076091b1a5f7b4206ff71761 Mon Sep 17 00:00:00 2001 From: ameerj Date: Mon, 23 Nov 2020 18:38:13 -0500 Subject: Address PR feedback Co-Authored-By: LC <712067+lioncash@users.noreply.github.com> --- src/core/hle/service/nvdrv/devices/nvhost_nvdec.cpp | 3 +-- src/core/hle/service/nvdrv/devices/nvhost_vic.cpp | 3 +-- src/video_core/cdma_pusher.cpp | 9 ++++----- src/video_core/cdma_pusher.h | 4 +--- 4 files changed, 7 insertions(+), 12 deletions(-) diff --git a/src/core/hle/service/nvdrv/devices/nvhost_nvdec.cpp b/src/core/hle/service/nvdrv/devices/nvhost_nvdec.cpp index 36970f828..ecba1dba1 100644 --- a/src/core/hle/service/nvdrv/devices/nvhost_nvdec.cpp +++ b/src/core/hle/service/nvdrv/devices/nvhost_nvdec.cpp @@ -34,8 +34,7 @@ NvResult nvhost_nvdec::Ioctl1(Ioctl command, const std::vector& input, case 0xa: { if (command.length == 0x1c) { LOG_INFO(Service_NVDRV, "NVDEC video stream ended"); - Tegra::ChCommandHeaderList cmdlist(1); - cmdlist[0] = Tegra::ChCommandHeader{0xDEADB33F}; + Tegra::ChCommandHeaderList cmdlist{{0xDEADB33F}}; system.GPU().PushCommandBuffer(cmdlist); } return UnmapBuffer(input, output); diff --git a/src/core/hle/service/nvdrv/devices/nvhost_vic.cpp b/src/core/hle/service/nvdrv/devices/nvhost_vic.cpp index a29abd15b..70849a9bd 100644 --- a/src/core/hle/service/nvdrv/devices/nvhost_vic.cpp +++ b/src/core/hle/service/nvdrv/devices/nvhost_vic.cpp @@ -30,8 +30,7 @@ NvResult nvhost_vic::Ioctl1(Ioctl command, const std::vector& input, std::ve return MapBuffer(input, output); case 0xa: { if (command.length == 0x1c) { - Tegra::ChCommandHeaderList cmdlist(1); - cmdlist[0] = Tegra::ChCommandHeader{0xDEADB33F}; + Tegra::ChCommandHeaderList cmdlist{{0xDEADB33F}}; system.GPU().PushCommandBuffer(cmdlist); } return UnmapBuffer(input, output); diff --git a/src/video_core/cdma_pusher.cpp b/src/video_core/cdma_pusher.cpp index d80e74225..e1f00c4da 100644 --- a/src/video_core/cdma_pusher.cpp +++ b/src/video_core/cdma_pusher.cpp @@ -103,8 +103,8 @@ void CDmaPusher::ExecuteCommand(u32 state_offset, u32 data) { case ThiMethod::SetMethod1: LOG_DEBUG(Service_NVDRV, "NVDEC method 0x{:X}", static_cast(nvdec_thi_state.method_0)); - nvdec_processor->ProcessMethod( - static_cast(nvdec_thi_state.method_0), data); + nvdec_processor->ProcessMethod(static_cast(nvdec_thi_state.method_0), + data); break; default: break; @@ -128,8 +128,7 @@ void CDmaPusher::ExecuteCommand(u32 state_offset, u32 data) { case ThiMethod::SetMethod1: LOG_DEBUG(Service_NVDRV, "VIC method 0x{:X}, Args=({})", static_cast(vic_thi_state.method_0), data); - vic_processor->ProcessMethod(static_cast(vic_thi_state.method_0), - data); + vic_processor->ProcessMethod(static_cast(vic_thi_state.method_0), data); break; default: break; @@ -138,7 +137,7 @@ void CDmaPusher::ExecuteCommand(u32 state_offset, u32 data) { case ChClassId::Host1x: // This device is mainly for syncpoint synchronization LOG_DEBUG(Service_NVDRV, "Host1X Class Method"); - host1x_processor->ProcessMethod(static_cast(offset), data); + host1x_processor->ProcessMethod(static_cast(offset), data); break; default: UNIMPLEMENTED_MSG("Current class not implemented {:X}", static_cast(current_class)); diff --git a/src/video_core/cdma_pusher.h b/src/video_core/cdma_pusher.h index e16eb2254..1bada44dd 100644 --- a/src/video_core/cdma_pusher.h +++ b/src/video_core/cdma_pusher.h @@ -5,9 +5,7 @@ #pragma once #include -#include #include -#include #include "common/bit_field.h" #include "common/common_types.h" @@ -16,9 +14,9 @@ namespace Tegra { class GPU; +class Host1x; class Nvdec; class Vic; -class Host1x; enum class ChSubmissionMode : u32 { SetClass = 0, -- cgit v1.2.3