summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/core/hle/service/nvdrv/devices/nvmap.h46
1 files changed, 25 insertions, 21 deletions
diff --git a/src/core/hle/service/nvdrv/devices/nvmap.h b/src/core/hle/service/nvdrv/devices/nvmap.h
index 5a3044167..39fafaa7c 100644
--- a/src/core/hle/service/nvdrv/devices/nvmap.h
+++ b/src/core/hle/service/nvdrv/devices/nvmap.h
@@ -59,17 +59,25 @@ private:
59 Create = 0xC0080101, 59 Create = 0xC0080101,
60 FromId = 0xC0080103, 60 FromId = 0xC0080103,
61 Alloc = 0xC0200104, 61 Alloc = 0xC0200104,
62 Free = 0xC0180105,
62 Param = 0xC00C0109, 63 Param = 0xC00C0109,
63 GetId = 0xC008010E, 64 GetId = 0xC008010E,
64 Free = 0xC0180105,
65 }; 65 };
66
67 struct IocCreateParams { 66 struct IocCreateParams {
68 // Input 67 // Input
69 u32_le size; 68 u32_le size;
70 // Output 69 // Output
71 u32_le handle; 70 u32_le handle;
72 }; 71 };
72 static_assert(sizeof(IocCreateParams) == 8, "IocCreateParams has wrong size");
73
74 struct IocFromIdParams {
75 // Input
76 u32_le id;
77 // Output
78 u32_le handle;
79 };
80 static_assert(sizeof(IocFromIdParams) == 8, "IocFromIdParams has wrong size");
73 81
74 struct IocAllocParams { 82 struct IocAllocParams {
75 // Input 83 // Input
@@ -81,37 +89,33 @@ private:
81 INSERT_PADDING_BYTES(7); 89 INSERT_PADDING_BYTES(7);
82 u64_le addr; 90 u64_le addr;
83 }; 91 };
92 static_assert(sizeof(IocAllocParams) == 32, "IocAllocParams has wrong size");
84 93
85 struct IocGetIdParams { 94 struct IocFreeParams {
86 // Output
87 u32_le id;
88 // Input
89 u32_le handle;
90 };
91
92 struct IocFromIdParams {
93 // Input
94 u32_le id;
95 // Output
96 u32_le handle; 95 u32_le handle;
96 INSERT_PADDING_BYTES(4);
97 u64_le refcount;
98 u32_le size;
99 u32_le flags;
97 }; 100 };
101 static_assert(sizeof(IocFreeParams) == 24, "IocFreeParams has wrong size");
98 102
99 struct IocParamParams { 103 struct IocParamParams {
100 // Input 104 // Input
101 u32_le handle; 105 u32_le handle;
102 u32_le type; 106 u32_le param;
103 // Output 107 // Output
104 u32_le value; 108 u32_le result;
105 }; 109 };
110 static_assert(sizeof(IocParamParams) == 12, "IocParamParams has wrong size");
106 111
107 struct IocFreeParams { 112 struct IocGetIdParams {
113 // Output
114 u32_le id;
115 // Input
108 u32_le handle; 116 u32_le handle;
109 INSERT_PADDING_BYTES(4);
110 u64_le refcount;
111 u32_le size;
112 u32_le flags;
113 }; 117 };
114 static_assert(sizeof(IocFreeParams) == 24, "IocFreeParams has wrong size"); 118 static_assert(sizeof(IocGetIdParams) == 8, "IocGetIdParams has wrong size");
115 119
116 u32 IocCreate(const std::vector<u8>& input, std::vector<u8>& output); 120 u32 IocCreate(const std::vector<u8>& input, std::vector<u8>& output);
117 u32 IocAlloc(const std::vector<u8>& input, std::vector<u8>& output); 121 u32 IocAlloc(const std::vector<u8>& input, std::vector<u8>& output);