Debian Codegraph @

src/nouveau/headers/nvidia/classes/clc9d1.h

raw
1 /*
2 * SPDX-FileCopyrightText: Copyright (c) 1993-2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
3 * SPDX-License-Identifier: MIT
4 *
5 * Permission is hereby granted, free of charge, to any person obtaining a
6 * copy of this software and associated documentation files (the "Software"),
7 * to deal in the Software without restriction, including without limitation
8 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
9 * and/or sell copies of the Software, and to permit persons to whom the
10 * Software is furnished to do so, subject to the following conditions:
11 *
12 * The above copyright notice and this permission notice shall be included in
13 * all copies or substantial portions of the Software.
14 *
15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
18 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
20 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
21 * DEALINGS IN THE SOFTWARE.
22 */
23
24 #include "nvtypes.h"
25
26 #ifndef _clc9d1_h_
27 #define _clc9d1_h_
28
29 #ifdef __cplusplus
30 extern "C" {
31 #endif
32
33 #define NVC9D1_VIDEO_NVJPG (0x0000C9D1)
34
35 #define NVC9D1_NOP (0x00000100)
36 #define NVC9D1_NOP_PARAMETER 31:0
37 #define NVC9D1_PM_TRIGGER (0x00000140)
38 #define NVC9D1_PM_TRIGGER_V 31:0
39 #define NVC9D1_SET_APPLICATION_ID (0x00000200)
40 #define NVC9D1_SET_APPLICATION_ID_ID 31:0
41 #define NVC9D1_SET_APPLICATION_ID_ID_NVJPG_DECODER (0x00000001)
42 #define NVC9D1_SET_APPLICATION_ID_ID_NVJPG_ENCODER (0x00000002)
43 #define NVC9D1_SET_WATCHDOG_TIMER (0x00000204)
44 #define NVC9D1_SET_WATCHDOG_TIMER_TIMER 31:0
45 #define NVC9D1_SEMAPHORE_A (0x00000240)
46 #define NVC9D1_SEMAPHORE_A_UPPER 24:0
47 #define NVC9D1_SEMAPHORE_B (0x00000244)
48 #define NVC9D1_SEMAPHORE_B_LOWER 31:0
49 #define NVC9D1_SEMAPHORE_C (0x00000248)
50 #define NVC9D1_SEMAPHORE_C_PAYLOAD 31:0
51 #define NVC9D1_CTX_SAVE_AREA (0x0000024C)
52 #define NVC9D1_CTX_SAVE_AREA_OFFSET 27:0
53 #define NVC9D1_CTX_SAVE_AREA_CTX_VALID 31:28
54 #define NVC9D1_CTX_SWITCH (0x00000250)
55 #define NVC9D1_CTX_SWITCH_RESTORE 0:0
56 #define NVC9D1_CTX_SWITCH_RESTORE_FALSE (0x00000000)
57 #define NVC9D1_CTX_SWITCH_RESTORE_TRUE (0x00000001)
58 #define NVC9D1_CTX_SWITCH_RST_NOTIFY 1:1
59 #define NVC9D1_CTX_SWITCH_RST_NOTIFY_FALSE (0x00000000)
60 #define NVC9D1_CTX_SWITCH_RST_NOTIFY_TRUE (0x00000001)
61 #define NVC9D1_CTX_SWITCH_RESERVED 7:2
62 #define NVC9D1_CTX_SWITCH_ASID 23:8
63 #define NVC9D1_SET_SEMAPHORE_PAYLOAD_LOWER (0x00000254)
64 #define NVC9D1_SET_SEMAPHORE_PAYLOAD_LOWER_PAYLOAD_LOWER 31:0
65 #define NVC9D1_SET_SEMAPHORE_PAYLOAD_UPPER (0x00000258)
66 #define NVC9D1_SET_SEMAPHORE_PAYLOAD_UPPER_PAYLOAD_UPPER 31:0
67 #define NVC9D1_EXECUTE (0x00000300)
68 #define NVC9D1_EXECUTE_NOTIFY 0:0
69 #define NVC9D1_EXECUTE_NOTIFY_DISABLE (0x00000000)
70 #define NVC9D1_EXECUTE_NOTIFY_ENABLE (0x00000001)
71 #define NVC9D1_EXECUTE_NOTIFY_ON 1:1
72 #define NVC9D1_EXECUTE_NOTIFY_ON_END (0x00000000)
73 #define NVC9D1_EXECUTE_NOTIFY_ON_BEGIN (0x00000001)
74 #define NVC9D1_EXECUTE_AWAKEN 8:8
75 #define NVC9D1_EXECUTE_AWAKEN_DISABLE (0x00000000)
76 #define NVC9D1_EXECUTE_AWAKEN_ENABLE (0x00000001)
77 #define NVC9D1_SEMAPHORE_D (0x00000304)
78 #define NVC9D1_SEMAPHORE_D_STRUCTURE_SIZE 0:0
79 #define NVC9D1_SEMAPHORE_D_STRUCTURE_SIZE_ONE (0x00000000)
80 #define NVC9D1_SEMAPHORE_D_STRUCTURE_SIZE_FOUR (0x00000001)
81 #define NVC9D1_SEMAPHORE_D_AWAKEN_ENABLE 8:8
82 #define NVC9D1_SEMAPHORE_D_AWAKEN_ENABLE_FALSE (0x00000000)
83 #define NVC9D1_SEMAPHORE_D_AWAKEN_ENABLE_TRUE (0x00000001)
84 #define NVC9D1_SEMAPHORE_D_OPERATION 17:16
85 #define NVC9D1_SEMAPHORE_D_OPERATION_RELEASE (0x00000000)
86 #define NVC9D1_SEMAPHORE_D_OPERATION_RESERVED0 (0x00000001)
87 #define NVC9D1_SEMAPHORE_D_OPERATION_RESERVED1 (0x00000002)
88 #define NVC9D1_SEMAPHORE_D_OPERATION_TRAP (0x00000003)
89 #define NVC9D1_SEMAPHORE_D_FLUSH_DISABLE 21:21
90 #define NVC9D1_SEMAPHORE_D_FLUSH_DISABLE_FALSE (0x00000000)
91 #define NVC9D1_SEMAPHORE_D_FLUSH_DISABLE_TRUE (0x00000001)
92 #define NVC9D1_SET_CONTROL_PARAMS (0x00000700)
93 #define NVC9D1_SET_CONTROL_PARAMS_GPTIMER_ON 0:0
94 #define NVC9D1_SET_CONTROL_PARAMS_DUMP_CYCLE_COUNT 1:1
95 #define NVC9D1_SET_CONTROL_PARAMS_DEBUG_MODE 2:2
96 #define NVC9D1_SET_TOTAL_CORE_NUM (0x00000704)
97 #define NVC9D1_SET_TOTAL_CORE_NUM_INDEX 31:0
98 #define NVC9D1_SET_IN_DRV_PIC_SETUP (0x00000708)
99 #define NVC9D1_SET_IN_DRV_PIC_SETUP_OFFSET 31:0
100 #define NVC9D1_SET_OUT_STATUS (0x0000070C)
101 #define NVC9D1_SET_OUT_STATUS_OFFSET 31:0
102 #define NVC9D1_SET_GP_TIMER (0x000007B0)
103 #define NVC9D1_SET_GP_TIMER_OFFSET 31:0
104 #define NVC9D1_PM_TRIGGER_END (0x00001114)
105 #define NVC9D1_PM_TRIGGER_END_V 31:0
106
107 #define NVC9D1_SET_PER_CORE_SET_CORE_INDEX(a) (0x00000710 + (a)*0x00000020)
108 #define NVC9D1_SET_PER_CORE_SET_CORE_INDEX_INDEX 31:0
109 #define NVC9D1_SET_PER_CORE_SET_BITSTREAM(a) (0x00000714 + (a)*0x00000020)
110 #define NVC9D1_SET_PER_CORE_SET_BITSTREAM_OFFSET 31:0
111 #define NVC9D1_SET_PER_CORE_SET_CUR_PIC(a) (0x00000718 + (a)*0x00000020)
112 #define NVC9D1_SET_PER_CORE_SET_CUR_PIC_OFFSET 31:0
113 #define NVC9D1_SET_PER_CORE_SET_CUR_PIC_CHROMA_U(a) (0x0000071C + (a)*0x00000020)
114 #define NVC9D1_SET_PER_CORE_SET_CUR_PIC_CHROMA_U_OFFSET 31:0
115 #define NVC9D1_SET_PER_CORE_SET_CUR_PIC_CHROMA_V(a) (0x00000720 + (a)*0x00000020)
116 #define NVC9D1_SET_PER_CORE_SET_CUR_PIC_CHROMA_V_OFFSET 31:0
117
118 #define NVC9D1_ERROR_NONE (0x00000000)
119 #define NVC9D1_OS_ERROR_EXECUTE_INSUFFICIENT_DATA (0x00000001)
120 #define NVC9D1_OS_ERROR_SEMAPHORE_INSUFFICIENT_DATA (0x00000002)
121 #define NVC9D1_OS_ERROR_INVALID_METHOD (0x00000003)
122 #define NVC9D1_OS_ERROR_INVALID_DMA_PAGE (0x00000004)
123 #define NVC9D1_OS_ERROR_UNHANDLED_INTERRUPT (0x00000005)
124 #define NVC9D1_OS_ERROR_EXCEPTION (0x00000006)
125 #define NVC9D1_OS_ERROR_INVALID_CTXSW_REQUEST (0x00000007)
126 #define NVC9D1_OS_ERROR_APPLICATION (0x00000008)
127 #define NVC9D1_OS_INTERRUPT_EXECUTE_AWAKEN (0x00000100)
128 #define NVC9D1_OS_INTERRUPT_BACKEND_SEMAPHORE_AWAKEN (0x00000200)
129 #define NVC9D1_OS_INTERRUPT_CTX_ERROR_FBIF (0x00000300)
130 #define NVC9D1_OS_INTERRUPT_LIMIT_VIOLATION (0x00000400)
131 #define NVC9D1_OS_INTERRUPT_LIMIT_AND_FBIF_CTX_ERROR (0x00000500)
132 #define NVC9D1_OS_INTERRUPT_HALT_ENGINE (0x00000600)
133 #define NVC9D1_OS_INTERRUPT_TRAP_NONSTALL (0x00000700)
134 #define NVC9D1_OS_INTERRUPT_CTX_SAVE_DONE (0x00000800)
135 #define NVC9D1_OS_INTERRUPT_CTX_RESTORE_DONE (0x00000900)
136 #define NVC9D1_ERROR_JPGAPPTIMER_EXPIRED (0x30000001)
137 #define NVC9D1_ERROR_JPGINVALID_INPUT (0x30000002)
138 #define NVC9D1_ERROR_JPGHWERR_INTERRUPT (0x30000003)
139 #define NVC9D1_ERROR_JPGBAD_MAGIC (0x30000004)
140
141 #ifdef __cplusplus
142 }; /* extern "C" */
143 #endif
144 #endif // _clc9d1_h
145