mirror of
https://github.com/switchbrew/libnx.git
synced 2025-06-28 07:42:55 +02:00
Buildfix
This commit is contained in:
parent
a3a2e57fc2
commit
de93886c56
@ -9,5 +9,5 @@ typedef struct NvGpu {
|
|||||||
NvErrorNotifier error_notifier;
|
NvErrorNotifier error_notifier;
|
||||||
} NvGpu;
|
} NvGpu;
|
||||||
|
|
||||||
Result nvgpuCreate(NvGpu* g);
|
Result nvGpuCreate(NvGpu* g);
|
||||||
void nvgpuClose(NvGpu* g);
|
void nvGpuClose(NvGpu* g);
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
#include <switch.h>
|
#include <switch.h>
|
||||||
|
|
||||||
Result nvgpuCreate(NvGpu* g)
|
Result nvGpuCreate(NvGpu* g)
|
||||||
{
|
{
|
||||||
Result rc;
|
Result rc;
|
||||||
|
|
||||||
@ -42,12 +42,12 @@ Result nvgpuCreate(NvGpu* g)
|
|||||||
rc = nvZcullContextCreate(&g->zcull_ctx, g);
|
rc = nvZcullContextCreate(&g->zcull_ctx, g);
|
||||||
|
|
||||||
if (R_FAILED(rc))
|
if (R_FAILED(rc))
|
||||||
nvgpuClose(g);
|
nvGpuClose(g);
|
||||||
|
|
||||||
return rc;
|
return rc;
|
||||||
}
|
}
|
||||||
|
|
||||||
void nvgpuClose(NvGpu* g)
|
void nvGpuClose(NvGpu* g)
|
||||||
{
|
{
|
||||||
nvBufferExit();
|
nvBufferExit();
|
||||||
nvInfoExit();
|
nvInfoExit();
|
||||||
|
@ -14,10 +14,12 @@ Result nvioctlNvhostCtrl_SyncptRead(u32 fd, u32 id, u32* out)
|
|||||||
memset(&data, 0, sizeof(data));
|
memset(&data, 0, sizeof(data));
|
||||||
data.syncpt_id = id;
|
data.syncpt_id = id;
|
||||||
|
|
||||||
|
Result rc;
|
||||||
|
|
||||||
rc = nvIoctl(fd, _NV_IOWR(0x00, 0x14, data), &data);
|
rc = nvIoctl(fd, _NV_IOWR(0x00, 0x14, data), &data);
|
||||||
|
|
||||||
if (R_SUCCEEDED(rc)) {
|
if (R_SUCCEEDED(rc)) {
|
||||||
*out = value;
|
*out = data.value;
|
||||||
}
|
}
|
||||||
|
|
||||||
return rc;
|
return rc;
|
||||||
|
Loading…
Reference in New Issue
Block a user