diff options
author | Lioncash <mathew1800@gmail.com> | 2018-01-21 22:56:58 +0100 |
---|---|---|
committer | Lioncash <mathew1800@gmail.com> | 2018-01-21 23:07:13 +0100 |
commit | 687a17acae0944c0c585c58c69aca0391085f3ef (patch) | |
tree | 3c4810a0f6d5511afc9b0f3c09c8283b0208a2ea /src/core/hle | |
parent | Merge pull request #129 from Rozelette/master (diff) | |
download | yuzu-687a17acae0944c0c585c58c69aca0391085f3ef.tar yuzu-687a17acae0944c0c585c58c69aca0391085f3ef.tar.gz yuzu-687a17acae0944c0c585c58c69aca0391085f3ef.tar.bz2 yuzu-687a17acae0944c0c585c58c69aca0391085f3ef.tar.lz yuzu-687a17acae0944c0c585c58c69aca0391085f3ef.tar.xz yuzu-687a17acae0944c0c585c58c69aca0391085f3ef.tar.zst yuzu-687a17acae0944c0c585c58c69aca0391085f3ef.zip |
Diffstat (limited to 'src/core/hle')
-rw-r--r-- | src/core/hle/service/nvdrv/devices/nvmap.cpp | 12 | ||||
-rw-r--r-- | src/core/hle/service/nvdrv/devices/nvmap.h | 12 |
2 files changed, 12 insertions, 12 deletions
diff --git a/src/core/hle/service/nvdrv/devices/nvmap.cpp b/src/core/hle/service/nvdrv/devices/nvmap.cpp index d37b5b159..ca65d9d35 100644 --- a/src/core/hle/service/nvdrv/devices/nvmap.cpp +++ b/src/core/hle/service/nvdrv/devices/nvmap.cpp @@ -22,16 +22,16 @@ VAddr nvmap::GetObjectAddress(u32 handle) const { } u32 nvmap::ioctl(u32 command, const std::vector<u8>& input, std::vector<u8>& output) { - switch (command) { - case IocCreateCommand: + switch (static_cast<IoctlCommand>(command)) { + case IoctlCommand::Create: return IocCreate(input, output); - case IocAllocCommand: + case IoctlCommand::Alloc: return IocAlloc(input, output); - case IocGetIdCommand: + case IoctlCommand::GetId: return IocGetId(input, output); - case IocFromIdCommand: + case IoctlCommand::FromId: return IocFromId(input, output); - case IocParamCommand: + case IoctlCommand::Param: return IocParam(input, output); } diff --git a/src/core/hle/service/nvdrv/devices/nvmap.h b/src/core/hle/service/nvdrv/devices/nvmap.h index 6954c0324..42e00f370 100644 --- a/src/core/hle/service/nvdrv/devices/nvmap.h +++ b/src/core/hle/service/nvdrv/devices/nvmap.h @@ -48,12 +48,12 @@ private: /// Mapping of currently allocated handles to the objects they represent. std::unordered_map<u32, std::shared_ptr<Object>> handles; - enum IoctlCommands { - IocCreateCommand = 0xC0080101, - IocFromIdCommand = 0xC0080103, - IocAllocCommand = 0xC0200104, - IocParamCommand = 0xC00C0109, - IocGetIdCommand = 0xC008010E + enum class IoctlCommand : u32 { + Create = 0xC0080101, + FromId = 0xC0080103, + Alloc = 0xC0200104, + Param = 0xC00C0109, + GetId = 0xC008010E }; struct IocCreateParams { |