libnx
nv.h
Go to the documentation of this file.
1 /**
2  * @file nv.h
3  * @brief NVIDIA low level driver (nvdrv*) service IPC wrapper.
4  * @author yellows8
5  * @copyright libnx Authors
6  */
7 #pragma once
8 #include "../types.h"
9 
10 typedef enum {
11  NVSERVTYPE_Default = -1,
12  NVSERVTYPE_Application = 0,
13  NVSERVTYPE_Applet = 1,
14  NVSERVTYPE_Sysmodule = 2,
15  NVSERVTYPE_T = 3,
16 } nvServiceType;
17 
18 Result nvInitialize(nvServiceType servicetype, size_t sharedmem_size);
19 void nvExit(void);
20 
21 Result nvOpen(u32 *fd, const char *devicepath);
22 Result nvIoctl(u32 fd, u32 request, void* argp);
23 Result nvClose(u32 fd);
24 Result nvQueryEvent(u32 fd, u32 event_id, Handle *handle_out);
25 
26 Result nvConvertError(int rc);
u32 Handle
Kernel object handle.
Definition: types.h:45
u32 Result
Function error code result type.
Definition: types.h:46
uint32_t u32
32-bit unsigned integer.
Definition: types.h:23