Switch 2: GSV services: Difference between revisions
Created page with "= (S2) GraphicsSupervisor = This is a TIPC interface so the command numbers are subtracted by 16. {| class="wikitable" border="1" |- ! Cmd || Name |- | 1 || #InitializeGraphicsWithTransferMemory |- | 4 || #InitializeGraphics |- | 11 || #SetCurrentProcessHandle |- | 12 || |- | 101 || #StartGraphics |- | 111 || |- | 112 || |- | 114 || |- | 115 || |- | 187 || |- | 201 || |- | 301 || |- | 303 || |- | 311 || |- | 312 || |- | 314 || |- | 315 ||..." |
No edit summary |
||
| (11 intermediate revisions by 2 users not shown) | |||
| Line 1: | Line 1: | ||
= | = UserSession = | ||
This is a TIPC interface so the command numbers are subtracted by 16. | This is a TIPC interface so the command numbers are subtracted by 16. | ||
This multiplexes several interfaces into a single session that can be acquired through [[Applet_Manager_services|am]]. | |||
{| class="wikitable" border="1" | {| class="wikitable" border="1" | ||
|- | |- | ||
! Cmd || Name | ! Cmd || Interface || Name | ||
|- | |||
| 1 || Gsv || [[#BootWithTransferMemory|BootWithTransferMemory]] | |||
|- | |||
| 4 || Gsv || [[#BootWithRemoteMemory|BootWithRemoteMemory]] | |||
|- | |||
| 11 || || [[#SetCurrentProcessHandle|SetCurrentProcessHandle]] | |||
|- | |||
| 12 || || | |||
|- | |||
| 101 || || [[#CreateContext|CreateContext]] | |||
|- | |||
| 111 || NativeMemory || CreateNativeMemory | |||
|- | |||
| 112 || NativeMemory || DestroyNativeMemory | |||
|- | |||
| 113 || NativeMemory || CreateNativeMemoryBlockByTransferMemory | |||
|- | |||
| 114 || NativeMemory || CreateNativeMemoryBlock | |||
|- | |||
| 115 || NativeMemory || BootNativeMemoryManagement | |||
|- | |||
| 187 || NativeMemory || QueryNativeMemoryNvsNvRmMemIdForDebug | |||
|- | |||
| 201 || Syncpt || [[#CreateSyncptContext|CreateSyncptContext]] | |||
|- | |||
| 202 || Syncpt || [[#InitializeSyncptContext|InitializeSyncptContext]] | |||
|- | |||
| 211 || Syncpt || [[#CreateDebugSyncDevice|CreateDebugSyncDevice]] | |||
|- | |||
| 212 || Syncpt || [[#DestroyDebugSyncDevice|DestroyDebugSyncDevice]] | |||
|- | |||
| 213 || Syncpt || [[#CreateDebugSyncCounter|CreateDebugSyncCounter]] | |||
|- | |||
| 214 || Syncpt || [[#DestroyDebugSyncCounter|DestroyDebugSyncCounter]] | |||
|- | |||
| 215 || Syncpt || [[#ReportDebugSyncCounterValue|ReportDebugSyncCounterValue]] | |||
|- | |||
| 301 || Display || [[#CreateDisplayContext|CreateDisplayContext]] | |||
|- | |||
| 303 || Display || [[#DestroyDisplayContext|DestroyDisplayContext]] | |||
|- | |||
| 305 || Display || [[#InitializeDisplayContext|InitializeDisplayContext]] | |||
|- | |||
| 311 || Display || | |||
|- | |||
| 312 || Display || | |||
|- | |||
| 314 || Display || | |||
|- | |||
| 315 || Display || | |||
|- | |||
| 321 || Display || | |||
|- | |||
| 327 || Display || | |||
|- | |||
| 361 || Display || | |||
|- | |||
| 391 || Display || CalculateRequiredBufferMemory | |||
|- | |||
| 401 || Gpu || [[#CreateGpuContext|CreateGpuContext]] | |||
|- | |||
| 402 || Gpu || [[#InitializeGpuContext|InitializeGpuContext]] | |||
|- | |||
| 403 || Gpu || [[#DestroyGpuContext|DestroyGpuContext]] | |||
|- | |||
| 423 || Gpu || | |||
|- | |||
| 424 || Gpu || | |||
|- | |||
| 425 || Gpu || | |||
|- | |||
| 426 || Gpu || MapNativeImage | |||
|- | |||
| 427 || Gpu || UnmapNativeImage | |||
|- | |||
| 428 || Gpu || QueryNativeImage | |||
|- | |||
| 429 || Gpu || CreateNativeImage | |||
|- | |||
| 430 || Gpu || DestroyNativeImage | |||
|- | |||
| 434 || Gpu || ExistsAddressSpace | |||
|- | |||
| 435 || Gpu || CalculateNativeImageSize | |||
|- | |||
| 437 || Gpu || CreateNativeMemoryWithGpukMemHandle | |||
|- | |||
| 493 || Gpu || CreateUserlandDebuggerSession | |||
|- | |||
| 494 || Gpu || | |||
|- | |||
| 496 || Gpu || [[#CreateGpuSessionWithTransferMemory|CreateGpuSessionWithTransferMemory]] | |||
|- | |||
| 497 || Gpu || [[#CreateGpuSessionWithRemoteMemory|CreateGpuSessionWithRemoteMemory]] | |||
|- | |||
| 498 || Gpu || TryQueryDonatedTransferMemoryUsage | |||
|- | |||
| 601 || Camera || CreateCameraContext | |||
|- | |||
| 602 || Camera || InitializeCameraContext | |||
|- | |||
| 603 || Camera || DestroyCameraContext | |||
|- | |||
| 612 || Camera || DestroyOutputBufferPool | |||
|- | |||
| 613 || Camera || CreateAliasOutputBufferPool | |||
|- | |||
| 614 || Camera || DestroyAliasOutputBufferPool | |||
|- | |||
| 615 || Camera || CreateOutputBufferPool | |||
|- | |||
| 616 || Camera || ReadFrameDataAsync | |||
|- | |||
| 620 || Camera || InitializeB | |||
|- | |||
| 621 || Camera || FinalizeB | |||
|- | |||
| 622 || Camera || ListCameras | |||
|- | |||
| 623 || Camera || OpenCamera | |||
|- | |||
| 624 || Camera || CloseCamera | |||
|- | |||
| 626 || Camera || ListSensorMode | |||
|- | |||
| 627 || Camera || SetSensorMode | |||
|- | |||
| 628 || Camera || GetAvailableStreams | |||
|- | |||
| 629 || Camera || GetRequiredWorkBufferSize | |||
|- | |||
| 630 || Camera || CreateStream | |||
|- | |||
| 632 || Camera || GetReadDoneEvent | |||
|- | |||
| 633 || Camera || GetStreamOutputSize | |||
|- | |||
| 634 || Camera || DestroyStream | |||
|- | |||
| 636 || Camera || ReadFrameDataAsync | |||
|- | |||
| 637 || Camera || GetAttachedEvent | |||
|- | |||
| 638 || Camera || GetDetachedEvent | |||
|- | |||
| 639 || Camera || GetFrameInfo | |||
|- | |||
| 640 || Camera || GetFrameInfo2 | |||
|- | |||
| 641 || Camera || GetConnectionChangedEvent | |||
|- | |||
| 650 || Camera || SetPictureQualityConfig | |||
|- | |||
| 651 || Camera || GetPictureQualityConfig | |||
|- | |||
| 652 || Camera || SetDigitalWindow | |||
|- | |||
| 653 || Camera || GetDigitalWindow | |||
|- | |||
| 654 || Camera || GetDigitalWindowCapability | |||
|- | |||
| 655 || Camera || GetSupportedFunctions | |||
|- | |||
| 656 || Camera || GetSupportedDebugFunctions | |||
|- | |||
| 657 || Camera || GetCameraPrivacyCoverStatus | |||
|- | |||
| 658 || Camera || GetCameraDeviceTemperature | |||
|- | |||
| 659 || Camera || GetDeviceUniqueId | |||
|- | |||
| 660 || Camera || GetSensorMode | |||
|- | |||
| 661 || Camera || GetStride | |||
|- | |||
| 662 || Camera || UnlinkSensor | |||
|- | |||
| 663 || Camera || GetDeviceModel | |||
|- | |||
| 664 || Camera || SetRawSensorMode | |||
|- | |||
| 665 || Camera || GetAccessAllowed | |||
|- | |||
| 666 || Camera || GetHostDrivenAeRegion | |||
|- | |- | ||
| | | 667 || Camera || SetHostDrivenAeRegion | ||
|- | |- | ||
| | | 691 || Camera || CalculateImageArraySize | ||
|- | |- | ||
| | | 801 || || | ||
|- | |- | ||
| | | 802 || || | ||
|- | |- | ||
| | | 803 || || | ||
|- | |- | ||
| | | 811 || || | ||
|- | |- | ||
| | | 812 || || | ||
|- | |- | ||
| | | 813 || || | ||
|- | |- | ||
| | | 814 || || | ||
|- | |- | ||
| | | 861 || || | ||
|- | |- | ||
| | | 891 || || | ||
|- | |- | ||
| | | 901 || VideoDecoder || [[#CreateVideoDecoderContext|CreateVideoDecoderContext]] | ||
|- | |- | ||
| | | 902 || VideoDecoder || [[#InitializeVideoDecoderContext|InitializeVideoDecoderContext]] | ||
|- | |- | ||
| | | 903 || VideoDecoder || [[#DestroyVideoDecoderContext|DestroyVideoDecoderContext]] | ||
|- | |- | ||
| | | 904 || VideoDecoderForSystem || [[#InitializeVideoDecoderContextForSystem|InitializeVideoDecoderContextForSystem]] | ||
|- | |- | ||
| | | 905 || VideoDecoder || [[#InitializeVideoDecoderContext2|InitializeVideoDecoderContext2]] | ||
|- | |- | ||
| | | 911 || VideoDecoder || InitializeDecoderImagePool | ||
|- | |- | ||
| | | 912 || VideoDecoder || FinalizeDecoderImagePool | ||
|- | |- | ||
| | | 921 || VideoDecoderForSystem || InitializeDecoderAliasImagePool | ||
|- | |- | ||
| | | 922 || VideoDecoderForSystem || FinalizeDecoderAliasImagePool | ||
|- | |- | ||
| | | 961 || VideoDecoder || | ||
|- | |- | ||
| | | 991 || VideoDecoder || | ||
|- | |- | ||
| | | 1001 || VideoEncoder || [[#CreateVideoEncoderContext|CreateVideoEncoderContext]] | ||
|- | |- | ||
| | | 1002 || VideoEncoder || [[#InitializeVideoEncoderContext|InitializeVideoEncoderContext]] | ||
|- | |- | ||
| | | 1003 || VideoEncoder || [[#DestroyVideoEncoderContext|DestroyVideoEncoderContext]] | ||
|- | |- | ||
| | | 1004 || VideoEncoderForSystem || [[#InitializeVideoEncoderContextForSystem|InitializeVideoEncoderContextForSystem]] | ||
|- | |- | ||
| | | 1011 || VideoEncoder || InitializeEncoderImagePool | ||
|- | |- | ||
| | | 1012 || VideoEncoder || FinalizeEncoderImagePool | ||
|- | |- | ||
| | | 1021 || VideoEncoderForSystem || InitializeEncoderAliasImagePool | ||
|- | |- | ||
| | | 1022 || VideoEncoderForSystem || FinalizeEncoderAliasImagePool | ||
|- | |- | ||
| | | 1061 || VideoEncoder || | ||
|- | |- | ||
| | | 1091 || VideoEncoder || | ||
|- | |- | ||
| | | 1101 || GraphicsFrame || CreateGraphicsFrameContext | ||
|- | |- | ||
| | | 1102 || GraphicsFrame || InitializeGraphicsFrameContext | ||
|- | |- | ||
| | | 1111 || GraphicsFrame || SetGraphicsFrameLengthMode | ||
|- | |- | ||
| | | 1112 || GraphicsFrame || SetGraphicsFrameRestartMode | ||
|- | |- | ||
| | | 1113 || GraphicsFrame || SetGraphicsFrameGpuTimesliceMode | ||
|- | |- | ||
| | | 1201 || Chat || CreateChatContext | ||
|- | |- | ||
| | | 1202 || Chat || InitializeChatContext | ||
|- | |- | ||
| | | 1203 || Chat || DestroyChatContext | ||
|- | |- | ||
| | | 1211 || Chat || CreateImagePool | ||
|- | |- | ||
| | | 1212 || Chat || DestroyImagePool | ||
|- | |- | ||
| | | 1291 || Chat || CalculateRequiredBufferMemory | ||
|- | |- | ||
| | | 1301 || Adraw || [[#CreateAdrawContext|CreateAdrawContext]] | ||
|- | |- | ||
| | | 1302 || Adraw || [[#InitializeAdrawContext|InitializeAdrawContext]] | ||
|- | |- | ||
| | | 1325 || Adraw || [[#GetAdrawFrameBufferHandle|GetAdrawFrameBufferHandle]] | ||
|- | |- | ||
| | | 1326 || Adraw || [[#GetAdrawImageHandle|GetAdrawImageHandle]] | ||
|- | |- | ||
| | | 1401 || NvDrv || [[#CreateNvDrv2UserSessionWithTransferMemory|CreateNvDrv2UserSessionWithTransferMemory]] | ||
|- | |- | ||
| | | 1402 || NvDrv || [[#CreateNvDrv2UserSessionWithRemoteMemory|CreateNvDrv2UserSessionWithRemoteMemory]] | ||
|- | |- | ||
| | | 1411 || NvDrv || [[#GetNvDrv2UserTransferMemoryUsage|GetNvDrv2UserTransferMemoryUsage]] | ||
|- | |- | ||
| | | 1501 || InterModuleImage || CreateInterModuleImageContext | ||
|- | |- | ||
| | | 1502 || InterModuleImage || InitializeInterModuleImageContext | ||
|- | |- | ||
| | | 1510 || InterModuleImage || | ||
|- | |- | ||
| 1601 || | | 1601 || || | ||
|- | |- | ||
| 1602 || | | 1602 || || | ||
|- | |- | ||
| 1603 || | | 1603 || || | ||
|- | |- | ||
| 1611 || | | 1611 || || | ||
|- | |- | ||
| 1612 || | | 1612 || || | ||
|- | |- | ||
| 1691 || | | 1691 || || | ||
|} | |} | ||
== | == BootWithTransferMemory == | ||
Unofficial name. | Unofficial name. | ||
Takes a TransferMemory handle, an input [[Applet_Manager_services#AppletResourceUserId|AppletResourceUserId]] and an input u64 '''TransferMemorySize'''. No output. | Takes a TransferMemory handle, an input [[Applet_Manager_services#AppletResourceUserId|AppletResourceUserId]] and an input u64 '''TransferMemorySize'''. No output. | ||
== | == BootWithRemoteMemory == | ||
Unofficial name. | Unofficial name. | ||
| Line 142: | Line 328: | ||
Takes a Process handle. No output. | Takes a Process handle. No output. | ||
Called directly after [[# | Called directly after [[#BootWithTransferMemory]] or [[#BootWithRemoteMemory]]. | ||
== | == CreateContext == | ||
Unofficial name. | Unofficial name. | ||
| Line 151: | Line 337: | ||
Called directly after [[#SetCurrentProcessHandle]]. | Called directly after [[#SetCurrentProcessHandle]]. | ||
== | == CreateSyncptContext == | ||
Unofficial name. | Unofficial name. | ||
No input/output. | No input/output. | ||
== InitializeSyncptContext == | |||
Unofficial name. | |||
== | No input. Returns a [[#SyncptSession]]. | ||
== CreateDebugSyncDevice == | |||
Unofficial name. | |||
No input/output. | |||
== DestroyDebugSyncDevice == | |||
Unofficial name. | |||
No input/output. | |||
== CreateDebugSyncCounter == | |||
Unofficial name. | |||
Takes an input u32. Returns an output u32 and an output u64. | |||
== DestroyDebugSyncCounter == | |||
Unofficial name. | |||
Takes 2 input u32s. No output. | |||
== ReportDebugSyncCounterValue == | |||
Unofficial name. | |||
Takes an input u32, an input u64 and an input u8. No output. | |||
== CreateDisplayContext == | |||
Unofficial name. | Unofficial name. | ||
No input/output. | No input/output. | ||
Called directly after [[# | == DestroyDisplayContext == | ||
Unofficial name. | |||
No input/output. | |||
== InitializeDisplayContext == | |||
Unofficial name. | |||
Takes an input u64 '''Version'''. Returns a [[#DisplaySession]]. | |||
[19.0.0] '''Version''' must be 0x300010000. | |||
== CreateGpuContext == | |||
Unofficial name. | |||
No input/output. | |||
Called directly after [[#CreateGpuSessionWithTransferMemory]] or [[#CreateGpuSessionWithRemoteMemory]]. | |||
== InitializeGpuContext == | |||
Unofficial name. | |||
No input/output. | |||
Called directly after [[#CreateGpuContext]]. | |||
== DestroyGpuContext == | |||
Unofficial name. | |||
No input/output. | |||
== GetImageInfo == | == GetImageInfo == | ||
| Line 170: | Line 413: | ||
Takes an input u32 '''ImageHandle'''. Returns an [[#(S2)_ImageInfo|ImageInfo]]. | Takes an input u32 '''ImageHandle'''. Returns an [[#(S2)_ImageInfo|ImageInfo]]. | ||
== | == CreateGpuSessionWithTransferMemory == | ||
Unofficial name. | Unofficial name. | ||
Takes a TransferMemory handle and two input u64s '''Version''' and '''TransferMemorySize'''. Returns a [[# | Takes a TransferMemory handle and two input u64s '''Version''' and '''TransferMemorySize'''. Returns a [[#GpuSession]]. | ||
[19.0.0] '''Version''' must be 2. | [19.0.0] '''Version''' must be 2. | ||
== | == CreateGpuSessionWithRemoteMemory == | ||
Unofficial name. | Unofficial name. | ||
Takes an input u64 '''Version'''. Returns a [[# | Takes an input u64 '''Version'''. Returns a [[#GpuSession]]. | ||
[19.0.0] '''Version''' must be 2. | [19.0.0] '''Version''' must be 2. | ||
== | == CreateVideoDecoderContext == | ||
Unofficial name. | |||
No input/output. | |||
== InitializeVideoDecoderContext == | |||
Unofficial name. | |||
No input. Returns a [[#VideoDecoderCreatorSession]]. | |||
== DestroyVideoDecoderContext == | |||
Unofficial name. | |||
No input/output. | |||
== InitializeVideoDecoderContextForSystem == | |||
Unofficial name. | |||
Takes an input u32. Returns a [[#VideoDecoderCreatorSession]]. | |||
== InitializeVideoDecoderContext2 == | |||
Unofficial name. | |||
Takes an input u8. Returns a [[#VideoDecoderCreatorSession]]. | |||
== CreateVideoEncoderContext == | |||
Unofficial name. | |||
No input/output. | |||
== InitializeVideoEncoderContext == | |||
Unofficial name. | |||
No input. Returns a [[#VideoEncoderCreatorSession]]. | |||
== DestroyVideoEncoderContext == | |||
Unofficial name. | Unofficial name. | ||
No input/output. | No input/output. | ||
== | == InitializeVideoEncoderContextForSystem == | ||
Unofficial name. | |||
Takes an input u32. Returns a [[#VideoEncoderCreatorSession]]. | |||
== CreateAdrawContext == | |||
Unofficial name. | Unofficial name. | ||
No input/output. | No input/output. | ||
Called directly after [[# | == InitializeAdrawContext == | ||
Unofficial name. | |||
No input/output. | |||
Called directly after [[#CreateAdrawContext]]. | |||
== GetAdrawFrameBufferHandle == | == GetAdrawFrameBufferHandle == | ||
| Line 215: | Line 503: | ||
Takes a TransferMemory handle, an input u64 '''TransferMemorySize''' and an input u8. Returns an [[NV_services#(S2)_INvDrv2User|INvDrv2User]]. | Takes a TransferMemory handle, an input u64 '''TransferMemorySize''' and an input u8. Returns an [[NV_services#(S2)_INvDrv2User|INvDrv2User]]. | ||
== | == CreateNvDrv2UserSessionWithRemoteMemory == | ||
Unofficial name. | Unofficial name. | ||
| Line 227: | Line 515: | ||
No input. Returns three u64s '''TotalTransferMemorySize''', '''UsedTransferMemorySize''' and '''MaxTransferMemorySize'''. | No input. Returns three u64s '''TotalTransferMemorySize''', '''UsedTransferMemorySize''' and '''MaxTransferMemorySize'''. | ||
== | == SyncptSession == | ||
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16. | Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16. | ||
| Line 234: | Line 522: | ||
! Cmd || Name | ! Cmd || Name | ||
|- | |- | ||
| | | 0 || [[#Ping|Ping]] | ||
|- | |- | ||
| | | 1 || | ||
|- | |- | ||
| 21 || | | 21 || | ||
|- | |- | ||
| 22 || | | 22 || | ||
|- | |- | ||
| | | 103 || | ||
|- | |- | ||
| | | 201 || | ||
|- | |- | ||
| | | 202 || | ||
|} | |||
=== Ping === | |||
Unofficial name. | |||
Takes an input u64. Returns an output u64. | |||
The output u64 should match the input u64. Official software sends the current system tick value. | |||
== DisplaySession == | |||
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16. | |||
{| class="wikitable" border="1" | |||
|- | |||
! Cmd || Name | |||
|- | |||
| 1 || | |||
|- | |||
| 3 || | |||
|- | |||
| 5 || | |||
|- | |||
| 11 || | |||
|- | |||
| 13 || | |||
|- | |||
| 21 || | |||
|- | |||
| 31 || | |||
|- | |||
| 32 || | |||
|- | |||
| 51 || | |||
|- | |||
| 53 || | |||
|- | |||
| 101 || | |||
|- | |- | ||
| 102 || | | 102 || | ||
|- | |- | ||
| | | 103 || | ||
|- | |||
| 104 || | |||
|- | |||
| 105 || | |||
|- | |||
| 106 || | |||
|- | |||
| 107 || | |||
|- | |||
| 111 || | |||
|- | |||
| 112 || | |||
|- | |||
| 113 || | |||
|- | |- | ||
| 201 || | | 201 || | ||
|- | |- | ||
| 202 || | | 202 || | ||
|- | |||
| 212 || | |||
|- | |||
| 228 || | |||
|- | |||
| 229 || | |||
|- | |||
| 251 || | |||
|- | |||
| 252 || | |||
|- | |||
| 261 || | |||
|- | |||
| 262 || | |||
|- | |||
| 263 || | |||
|- | |||
| 264 || | |||
|- | |||
| 265 || | |||
|- | |||
| 266 || | |||
|- | |||
| 267 || | |||
|- | |||
| 268 || | |||
|- | |||
| 269 || | |||
|- | |||
| 270 || | |||
|- | |||
| 271 || | |||
|- | |||
| 272 || | |||
|- | |||
| 301 || | |||
|- | |||
| 302 || | |||
|- | |||
| 351 || | |||
|} | |||
== VideoDecoderCreatorSession == | |||
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16. | |||
{| class="wikitable" border="1" | |||
|- | |||
! Cmd || Name | |||
|- | |||
| 1 || [[#CreateVideoDecoderSession|CreateVideoDecoderSession]] | |||
|} | |||
=== CreateVideoDecoderSession === | |||
Unofficial name. | |||
No input. Returns a [[#VideoDecoderSession]]. | |||
=== VideoDecoderSession === | |||
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16. | |||
{| class="wikitable" border="1" | |||
|- | |||
! Cmd || Name | |||
|- | |||
| 3 || GetVideoDecoderEvent | |||
|- | |||
| 6 || StartDecoding | |||
|- | |||
| 8 || | |||
|- | |||
| 101 || Setup | |||
|- | |||
| 109 || Decode | |||
|- | |||
| 115 || | |||
|- | |||
| 200 || InitializeVideoDecoderWithTransferMemory | |||
|- | |||
| 207 || StopDecoding | |||
|- | |||
| 210 || InitializeVideoDecoderWithRemoteMemory | |||
|- | |||
| 212 || | |||
|- | |||
| 213 || | |||
|- | |||
| 311 || | |||
|- | |||
| 314 || | |||
|- | |||
| 400 || Decode2 | |||
|} | |||
== VideoEncoderCreatorSession == | |||
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16. | |||
{| class="wikitable" border="1" | |||
|- | |||
! Cmd || Name | |||
|- | |||
| 1 || [[#CreateVideoEncoderSession|CreateVideoEncoderSession]] | |||
|} | |||
=== CreateVideoEncoderSession === | |||
Unofficial name. | |||
No input. Returns a [[#VideoEncoderSession]]. | |||
=== VideoEncoderSession === | |||
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16. | |||
{| class="wikitable" border="1" | |||
|- | |||
! Cmd || Name | |||
|- | |||
| 4 || GetVideoEncoderEvent | |||
|- | |||
| 5 || StartEncoding | |||
|- | |||
| 100 || InitializeVideoEncoder | |||
|- | |||
| 101 || Setup | |||
|- | |||
| 102 || | |||
|- | |||
| 108 || Encode | |||
|- | |||
| 110 || | |||
|- | |||
| 111 || | |||
|- | |||
| 112 || | |||
|- | |||
| 206 || StopEncoding | |||
|} | |||
== GpuSession == | |||
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16. | |||
{| class="wikitable" border="1" | |||
|- | |||
! Cmd || Name | |||
|- | |||
| 11 || [[#GetEventIdRange|GetEventIdRange]] | |||
|- | |||
| 12 || [[#CreateEvent|CreateEvent]] | |||
|- | |||
| 21 || [[#RequestKUserWorkerSession|RequestKUserWorkerSession]] | |||
|- | |||
| 22 || [[#GetKUserWorkerSession|GetKUserWorkerSession]] | |||
|- | |||
| 33 || CreateGpuAddressSpace | |||
|- | |||
| 41 || CreateGraphicsDevice | |||
|- | |||
| 42 || DestroyGraphicsDevice | |||
|- | |||
| 102 || | |||
|- | |||
| 200 || SynchronizeGpuAddressSpace | |||
|- | |||
| 201 || GetUserPartitionGpuAddress | |||
|- | |||
| 202 || GetGsvPartitionGpuAddress | |||
|} | |} | ||
| Line 267: | Line 770: | ||
Takes an input u32 '''EventId'''. Returns an output Event handle. | Takes an input u32 '''EventId'''. Returns an output Event handle. | ||
=== | === RequestKUserWorkerSession === | ||
Unofficial name. | Unofficial name. | ||
| Line 274: | Line 777: | ||
'''EventId''' must have been previously passed to [[#CreateEvent]] and the returned Event handle will be signalled when the session is ready. | '''EventId''' must have been previously passed to [[#CreateEvent]] and the returned Event handle will be signalled when the session is ready. | ||
=== | === GetKUserWorkerSession === | ||
Unofficial name. | Unofficial name. | ||
No input. Returns a [[# | No input. Returns a [[#GetKUserWorkerSession]]. | ||
Called after [[# | Called after [[#RequestKUserWorkerSession]] and the Event handle has been signalled. | ||
=== | === KUserWorkerSession === | ||
This is "nn::gpuk::impl::kuser::KUserWorkerSession". | |||
This is a TIPC interface so the command numbers are subtracted by 16. | |||
{| class="wikitable" border="1" | {| class="wikitable" border="1" | ||
| Line 288: | Line 793: | ||
! Cmd || Name | ! Cmd || Name | ||
|- | |- | ||
| 101 || [[#CreateGpuMemory]] | | 101 || [[#CreateGpuMemory|CreateGpuMemory]] | ||
|- | |||
| 102 || [[#DestroyGpuMemory|DestroyGpuMemory]] | |||
|- | |||
| 171 || EnsureGpuMemoryComptags | |||
|- | |||
| 172 || SetGpuMemoryUserDebugLabel | |||
|- | |||
| 173 || SetGpuMemorySdkDebugLabel | |||
|- | |||
| 201 || [19.0.0-19.1.0] NormalMapGpuMemory4K | |||
|- | |- | ||
| | | 202 || [19.0.0-19.1.0] NormalUnmapGpuMemory4K | ||
|- | |- | ||
| | | 203 || [19.0.0-19.1.0] CreateSparseRegion | ||
|- | |- | ||
| | | 204 || [19.0.0-19.1.0] DestroySparseRegion | ||
|- | |- | ||
| | | 205 || [19.0.0-19.1.0] ExecuteSparseMapRequests | ||
|- | |- | ||
| | | 207 || [19.0.0-19.1.0] NormalModifyMemoryKind4K | ||
|- | |- | ||
| | | 209 || [20.0.0+] SetGpuSegmentUserDebugLabel | ||
|- | |- | ||
| | | 210 || [20.0.0+] SetGpuSegmentSdkDebugLabel | ||
|- | |- | ||
| 211 || [20. | | 211 || [20.0.0+] NormalMapGpuMemory4K | ||
|- | |- | ||
| 212 || [20. | | 212 || [20.0.0+] NormalModifyMemoryKind4K | ||
|- | |- | ||
| 213 || [20. | | 213 || [20.0.0+] NormalUnmapGpuMemory4K | ||
|- | |- | ||
| 214 || [20. | | 214 || [20.0.0+] CreateSparseRegion | ||
|- | |- | ||
| 215 || [20. | | 215 || [20.0.0+] DestroySparseRegion | ||
|- | |- | ||
| 216 || [20. | | 216 || [20.0.0+] ExecuteSparseMapRequests | ||
|} | |} | ||
| Line 330: | Line 845: | ||
The Event handle associated with '''EventId''' will be signalled when the memory is released. | The Event handle associated with '''EventId''' will be signalled when the memory is released. | ||
= gsv:m = | |||
= gsv:t = | |||
= gsv:sv = | |||
= gsv:s3 = | |||
= gsv:s4 = | |||
Latest revision as of 05:01, 26 June 2026
UserSession
This is a TIPC interface so the command numbers are subtracted by 16.
This multiplexes several interfaces into a single session that can be acquired through am.
| Cmd | Interface | Name |
|---|---|---|
| 1 | Gsv | BootWithTransferMemory |
| 4 | Gsv | BootWithRemoteMemory |
| 11 | SetCurrentProcessHandle | |
| 12 | ||
| 101 | CreateContext | |
| 111 | NativeMemory | CreateNativeMemory |
| 112 | NativeMemory | DestroyNativeMemory |
| 113 | NativeMemory | CreateNativeMemoryBlockByTransferMemory |
| 114 | NativeMemory | CreateNativeMemoryBlock |
| 115 | NativeMemory | BootNativeMemoryManagement |
| 187 | NativeMemory | QueryNativeMemoryNvsNvRmMemIdForDebug |
| 201 | Syncpt | CreateSyncptContext |
| 202 | Syncpt | InitializeSyncptContext |
| 211 | Syncpt | CreateDebugSyncDevice |
| 212 | Syncpt | DestroyDebugSyncDevice |
| 213 | Syncpt | CreateDebugSyncCounter |
| 214 | Syncpt | DestroyDebugSyncCounter |
| 215 | Syncpt | ReportDebugSyncCounterValue |
| 301 | Display | CreateDisplayContext |
| 303 | Display | DestroyDisplayContext |
| 305 | Display | InitializeDisplayContext |
| 311 | Display | |
| 312 | Display | |
| 314 | Display | |
| 315 | Display | |
| 321 | Display | |
| 327 | Display | |
| 361 | Display | |
| 391 | Display | CalculateRequiredBufferMemory |
| 401 | Gpu | CreateGpuContext |
| 402 | Gpu | InitializeGpuContext |
| 403 | Gpu | DestroyGpuContext |
| 423 | Gpu | |
| 424 | Gpu | |
| 425 | Gpu | |
| 426 | Gpu | MapNativeImage |
| 427 | Gpu | UnmapNativeImage |
| 428 | Gpu | QueryNativeImage |
| 429 | Gpu | CreateNativeImage |
| 430 | Gpu | DestroyNativeImage |
| 434 | Gpu | ExistsAddressSpace |
| 435 | Gpu | CalculateNativeImageSize |
| 437 | Gpu | CreateNativeMemoryWithGpukMemHandle |
| 493 | Gpu | CreateUserlandDebuggerSession |
| 494 | Gpu | |
| 496 | Gpu | CreateGpuSessionWithTransferMemory |
| 497 | Gpu | CreateGpuSessionWithRemoteMemory |
| 498 | Gpu | TryQueryDonatedTransferMemoryUsage |
| 601 | Camera | CreateCameraContext |
| 602 | Camera | InitializeCameraContext |
| 603 | Camera | DestroyCameraContext |
| 612 | Camera | DestroyOutputBufferPool |
| 613 | Camera | CreateAliasOutputBufferPool |
| 614 | Camera | DestroyAliasOutputBufferPool |
| 615 | Camera | CreateOutputBufferPool |
| 616 | Camera | ReadFrameDataAsync |
| 620 | Camera | InitializeB |
| 621 | Camera | FinalizeB |
| 622 | Camera | ListCameras |
| 623 | Camera | OpenCamera |
| 624 | Camera | CloseCamera |
| 626 | Camera | ListSensorMode |
| 627 | Camera | SetSensorMode |
| 628 | Camera | GetAvailableStreams |
| 629 | Camera | GetRequiredWorkBufferSize |
| 630 | Camera | CreateStream |
| 632 | Camera | GetReadDoneEvent |
| 633 | Camera | GetStreamOutputSize |
| 634 | Camera | DestroyStream |
| 636 | Camera | ReadFrameDataAsync |
| 637 | Camera | GetAttachedEvent |
| 638 | Camera | GetDetachedEvent |
| 639 | Camera | GetFrameInfo |
| 640 | Camera | GetFrameInfo2 |
| 641 | Camera | GetConnectionChangedEvent |
| 650 | Camera | SetPictureQualityConfig |
| 651 | Camera | GetPictureQualityConfig |
| 652 | Camera | SetDigitalWindow |
| 653 | Camera | GetDigitalWindow |
| 654 | Camera | GetDigitalWindowCapability |
| 655 | Camera | GetSupportedFunctions |
| 656 | Camera | GetSupportedDebugFunctions |
| 657 | Camera | GetCameraPrivacyCoverStatus |
| 658 | Camera | GetCameraDeviceTemperature |
| 659 | Camera | GetDeviceUniqueId |
| 660 | Camera | GetSensorMode |
| 661 | Camera | GetStride |
| 662 | Camera | UnlinkSensor |
| 663 | Camera | GetDeviceModel |
| 664 | Camera | SetRawSensorMode |
| 665 | Camera | GetAccessAllowed |
| 666 | Camera | GetHostDrivenAeRegion |
| 667 | Camera | SetHostDrivenAeRegion |
| 691 | Camera | CalculateImageArraySize |
| 801 | ||
| 802 | ||
| 803 | ||
| 811 | ||
| 812 | ||
| 813 | ||
| 814 | ||
| 861 | ||
| 891 | ||
| 901 | VideoDecoder | CreateVideoDecoderContext |
| 902 | VideoDecoder | InitializeVideoDecoderContext |
| 903 | VideoDecoder | DestroyVideoDecoderContext |
| 904 | VideoDecoderForSystem | InitializeVideoDecoderContextForSystem |
| 905 | VideoDecoder | InitializeVideoDecoderContext2 |
| 911 | VideoDecoder | InitializeDecoderImagePool |
| 912 | VideoDecoder | FinalizeDecoderImagePool |
| 921 | VideoDecoderForSystem | InitializeDecoderAliasImagePool |
| 922 | VideoDecoderForSystem | FinalizeDecoderAliasImagePool |
| 961 | VideoDecoder | |
| 991 | VideoDecoder | |
| 1001 | VideoEncoder | CreateVideoEncoderContext |
| 1002 | VideoEncoder | InitializeVideoEncoderContext |
| 1003 | VideoEncoder | DestroyVideoEncoderContext |
| 1004 | VideoEncoderForSystem | InitializeVideoEncoderContextForSystem |
| 1011 | VideoEncoder | InitializeEncoderImagePool |
| 1012 | VideoEncoder | FinalizeEncoderImagePool |
| 1021 | VideoEncoderForSystem | InitializeEncoderAliasImagePool |
| 1022 | VideoEncoderForSystem | FinalizeEncoderAliasImagePool |
| 1061 | VideoEncoder | |
| 1091 | VideoEncoder | |
| 1101 | GraphicsFrame | CreateGraphicsFrameContext |
| 1102 | GraphicsFrame | InitializeGraphicsFrameContext |
| 1111 | GraphicsFrame | SetGraphicsFrameLengthMode |
| 1112 | GraphicsFrame | SetGraphicsFrameRestartMode |
| 1113 | GraphicsFrame | SetGraphicsFrameGpuTimesliceMode |
| 1201 | Chat | CreateChatContext |
| 1202 | Chat | InitializeChatContext |
| 1203 | Chat | DestroyChatContext |
| 1211 | Chat | CreateImagePool |
| 1212 | Chat | DestroyImagePool |
| 1291 | Chat | CalculateRequiredBufferMemory |
| 1301 | Adraw | CreateAdrawContext |
| 1302 | Adraw | InitializeAdrawContext |
| 1325 | Adraw | GetAdrawFrameBufferHandle |
| 1326 | Adraw | GetAdrawImageHandle |
| 1401 | NvDrv | CreateNvDrv2UserSessionWithTransferMemory |
| 1402 | NvDrv | CreateNvDrv2UserSessionWithRemoteMemory |
| 1411 | NvDrv | GetNvDrv2UserTransferMemoryUsage |
| 1501 | InterModuleImage | CreateInterModuleImageContext |
| 1502 | InterModuleImage | InitializeInterModuleImageContext |
| 1510 | InterModuleImage | |
| 1601 | ||
| 1602 | ||
| 1603 | ||
| 1611 | ||
| 1612 | ||
| 1691 |
BootWithTransferMemory
Unofficial name.
Takes a TransferMemory handle, an input AppletResourceUserId and an input u64 TransferMemorySize. No output.
BootWithRemoteMemory
Unofficial name.
Takes a Process handle, an input AppletResourceUserId and five input u64s. No output.
The first u64 appears to be a version ([19.0.0] 0x8000000000000001, [20.1.1] 0x8000000000000005), the last u64 is the output from new InfoType 31 or 32 and the remaining u64s are all 0.
SetCurrentProcessHandle
Unofficial name.
Takes a Process handle. No output.
Called directly after #BootWithTransferMemory or #BootWithRemoteMemory.
CreateContext
Unofficial name.
No input/output.
Called directly after #SetCurrentProcessHandle.
CreateSyncptContext
Unofficial name.
No input/output.
InitializeSyncptContext
Unofficial name.
No input. Returns a #SyncptSession.
CreateDebugSyncDevice
Unofficial name.
No input/output.
DestroyDebugSyncDevice
Unofficial name.
No input/output.
CreateDebugSyncCounter
Unofficial name.
Takes an input u32. Returns an output u32 and an output u64.
DestroyDebugSyncCounter
Unofficial name.
Takes 2 input u32s. No output.
ReportDebugSyncCounterValue
Unofficial name.
Takes an input u32, an input u64 and an input u8. No output.
CreateDisplayContext
Unofficial name.
No input/output.
DestroyDisplayContext
Unofficial name.
No input/output.
InitializeDisplayContext
Unofficial name.
Takes an input u64 Version. Returns a #DisplaySession.
[19.0.0] Version must be 0x300010000.
CreateGpuContext
Unofficial name.
No input/output.
Called directly after #CreateGpuSessionWithTransferMemory or #CreateGpuSessionWithRemoteMemory.
InitializeGpuContext
Unofficial name.
No input/output.
Called directly after #CreateGpuContext.
DestroyGpuContext
Unofficial name.
No input/output.
GetImageInfo
Unofficial name.
Takes an input u32 ImageHandle. Returns an ImageInfo.
CreateGpuSessionWithTransferMemory
Unofficial name.
Takes a TransferMemory handle and two input u64s Version and TransferMemorySize. Returns a #GpuSession.
[19.0.0] Version must be 2.
CreateGpuSessionWithRemoteMemory
Unofficial name.
Takes an input u64 Version. Returns a #GpuSession.
[19.0.0] Version must be 2.
CreateVideoDecoderContext
Unofficial name.
No input/output.
InitializeVideoDecoderContext
Unofficial name.
No input. Returns a #VideoDecoderCreatorSession.
DestroyVideoDecoderContext
Unofficial name.
No input/output.
InitializeVideoDecoderContextForSystem
Unofficial name.
Takes an input u32. Returns a #VideoDecoderCreatorSession.
InitializeVideoDecoderContext2
Unofficial name.
Takes an input u8. Returns a #VideoDecoderCreatorSession.
CreateVideoEncoderContext
Unofficial name.
No input/output.
InitializeVideoEncoderContext
Unofficial name.
No input. Returns a #VideoEncoderCreatorSession.
DestroyVideoEncoderContext
Unofficial name.
No input/output.
InitializeVideoEncoderContextForSystem
Unofficial name.
Takes an input u32. Returns a #VideoEncoderCreatorSession.
CreateAdrawContext
Unofficial name.
No input/output.
InitializeAdrawContext
Unofficial name.
No input/output.
Called directly after #CreateAdrawContext.
GetAdrawFrameBufferHandle
Unofficial name.
Takes an input u64. Returns an output u32 FrameBufferHandle.
Official software sends the Id obtained with GetFrameBufferInfo from adraw.
GetAdrawImageHandle
Unofficial name.
Takes seven input u64s, two input u16s and two input u32s. Returns an output u32 ImageHandle.
Official software sends 0x100000000 in the first u64, 0 in all remaining u64s, Width and Height in the two u16s, BlockCount int the first u32 and the FrameBufferHandle from GetAdrawFrameBufferHandle in the last u32.
CreateNvDrv2UserSessionWithTransferMemory
Unofficial name.
Takes a TransferMemory handle, an input u64 TransferMemorySize and an input u8. Returns an INvDrv2User.
CreateNvDrv2UserSessionWithRemoteMemory
Unofficial name.
No input. Returns an INvDrv2User.
Only one session can be open at a time, otherwise returns error 0x200f3.
GetNvDrv2UserTransferMemoryUsage
Unofficial name.
No input. Returns three u64s TotalTransferMemorySize, UsedTransferMemorySize and MaxTransferMemorySize.
SyncptSession
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16.
| Cmd | Name |
|---|---|
| 0 | Ping |
| 1 | |
| 21 | |
| 22 | |
| 103 | |
| 201 | |
| 202 |
Ping
Unofficial name.
Takes an input u64. Returns an output u64.
The output u64 should match the input u64. Official software sends the current system tick value.
DisplaySession
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16.
| Cmd | Name |
|---|---|
| 1 | |
| 3 | |
| 5 | |
| 11 | |
| 13 | |
| 21 | |
| 31 | |
| 32 | |
| 51 | |
| 53 | |
| 101 | |
| 102 | |
| 103 | |
| 104 | |
| 105 | |
| 106 | |
| 107 | |
| 111 | |
| 112 | |
| 113 | |
| 201 | |
| 202 | |
| 212 | |
| 228 | |
| 229 | |
| 251 | |
| 252 | |
| 261 | |
| 262 | |
| 263 | |
| 264 | |
| 265 | |
| 266 | |
| 267 | |
| 268 | |
| 269 | |
| 270 | |
| 271 | |
| 272 | |
| 301 | |
| 302 | |
| 351 |
VideoDecoderCreatorSession
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16.
| Cmd | Name |
|---|---|
| 1 | CreateVideoDecoderSession |
CreateVideoDecoderSession
Unofficial name.
No input. Returns a #VideoDecoderSession.
VideoDecoderSession
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16.
| Cmd | Name |
|---|---|
| 3 | GetVideoDecoderEvent |
| 6 | StartDecoding |
| 8 | |
| 101 | Setup |
| 109 | Decode |
| 115 | |
| 200 | InitializeVideoDecoderWithTransferMemory |
| 207 | StopDecoding |
| 210 | InitializeVideoDecoderWithRemoteMemory |
| 212 | |
| 213 | |
| 311 | |
| 314 | |
| 400 | Decode2 |
VideoEncoderCreatorSession
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16.
| Cmd | Name |
|---|---|
| 1 | CreateVideoEncoderSession |
CreateVideoEncoderSession
Unofficial name.
No input. Returns a #VideoEncoderSession.
VideoEncoderSession
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16.
| Cmd | Name |
|---|---|
| 4 | GetVideoEncoderEvent |
| 5 | StartEncoding |
| 100 | InitializeVideoEncoder |
| 101 | Setup |
| 102 | |
| 108 | Encode |
| 110 | |
| 111 | |
| 112 | |
| 206 | StopEncoding |
GpuSession
Unofficial name. This is a TIPC interface so the command numbers are subtracted by 16.
| Cmd | Name |
|---|---|
| 11 | GetEventIdRange |
| 12 | CreateEvent |
| 21 | RequestKUserWorkerSession |
| 22 | GetKUserWorkerSession |
| 33 | CreateGpuAddressSpace |
| 41 | CreateGraphicsDevice |
| 42 | DestroyGraphicsDevice |
| 102 | |
| 200 | SynchronizeGpuAddressSpace |
| 201 | GetUserPartitionGpuAddress |
| 202 | GetGsvPartitionGpuAddress |
GetEventIdRange
Unofficial name.
No input. Returns two u32s EventIdMin and EventIdMax.
CreateEvent
Unofficial name.
Takes an input u32 EventId. Returns an output Event handle.
RequestKUserWorkerSession
Unofficial name.
Takes an input u32 EventId. No output.
EventId must have been previously passed to #CreateEvent and the returned Event handle will be signalled when the session is ready.
GetKUserWorkerSession
Unofficial name.
No input. Returns a #GetKUserWorkerSession.
Called after #RequestKUserWorkerSession and the Event handle has been signalled.
KUserWorkerSession
This is "nn::gpuk::impl::kuser::KUserWorkerSession".
This is a TIPC interface so the command numbers are subtracted by 16.
| Cmd | Name |
|---|---|
| 101 | CreateGpuMemory |
| 102 | DestroyGpuMemory |
| 171 | EnsureGpuMemoryComptags |
| 172 | SetGpuMemoryUserDebugLabel |
| 173 | SetGpuMemorySdkDebugLabel |
| 201 | [19.0.0-19.1.0] NormalMapGpuMemory4K |
| 202 | [19.0.0-19.1.0] NormalUnmapGpuMemory4K |
| 203 | [19.0.0-19.1.0] CreateSparseRegion |
| 204 | [19.0.0-19.1.0] DestroySparseRegion |
| 205 | [19.0.0-19.1.0] ExecuteSparseMapRequests |
| 207 | [19.0.0-19.1.0] NormalModifyMemoryKind4K |
| 209 | [20.0.0+] SetGpuSegmentUserDebugLabel |
| 210 | [20.0.0+] SetGpuSegmentSdkDebugLabel |
| 211 | [20.0.0+] NormalMapGpuMemory4K |
| 212 | [20.0.0+] NormalModifyMemoryKind4K |
| 213 | [20.0.0+] NormalUnmapGpuMemory4K |
| 214 | [20.0.0+] CreateSparseRegion |
| 215 | [20.0.0+] DestroySparseRegion |
| 216 | [20.0.0+] ExecuteSparseMapRequests |
CreateGpuMemory
Unofficial name.
Takes two input u64s MemoryAddressStart and MemoryAddressEnd and two u8s. Returns an output u32 GpuMemoryHandle.
The memory region between MemoryAddressStart and MemoryAddressEnd must have been passed to SVC 0x80 with attribute 0x20.
DestroyGpuMemory
Unofficial name.
Takes two input u32s GpuMemoryHandle and EventId. No output.
The Event handle associated with EventId will be signalled when the memory is released.