summaryrefslogtreecommitdiffstats
path: root/userspace/sdks/nv570/inc/ctrl/ctrl208f/ctrl208ffifo.h
blob: d5b8849b6f26eb5cfb736d33fe488e7a400c6e65 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
/*
 * SPDX-FileCopyrightText: Copyright (c) 2006-2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
 * SPDX-License-Identifier: MIT
 *
 * Permission is hereby granted, free of charge, to any person obtaining a
 * copy of this software and associated documentation files (the "Software"),
 * to deal in the Software without restriction, including without limitation
 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
 * and/or sell copies of the Software, and to permit persons to whom the
 * Software is furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 * DEALINGS IN THE SOFTWARE.
 */

#pragma once

#include <nvtypes.h>

//
// This file was generated with FINN, an NVIDIA coding tool.
// Source file:      ctrl/ctrl208f/ctrl208ffifo.finn
//

#include "ctrl/ctrl208f/ctrl208fbase.h"

/*
 * NV208F_CTRL_CMD_FIFO_CHECK_ENGINE_CONTEXT
 *
 * This command checks whether or not engine context exists for a given
 * engine for the channel with a given channel ID. This API is intended
 * for testing virtual context. For debug only.
 *
 *   hChannel
 *     The handle to the channel.
 *   engine
 *     The engine ID.
 *     Valid values are:
 *        NV2080_ENGINE_TYPE_GRAPHICS
 *   exists
 *     The output are TRUE or FALSE.
 *
 * Possible status values returned are:
 *   NV_OK
 *   NV_ERR_INVALID_DEVICE
 *   NV_ERR_INVALID_CHANNEL
 *   NV_ERR_INVALID_ARGUMENT
 */
#define NV208F_CTRL_CMD_FIFO_CHECK_ENGINE_CONTEXT (0x208f0401) /* finn: Evaluated from "(FINN_NV20_SUBDEVICE_DIAG_FIFO_INTERFACE_ID << 8) | NV208F_CTRL_FIFO_CHECK_ENGINE_CONTEXT_PARAMS_MESSAGE_ID" */

#define NV208F_CTRL_FIFO_CHECK_ENGINE_CONTEXT_PARAMS_MESSAGE_ID (0x1U)

typedef struct NV208F_CTRL_FIFO_CHECK_ENGINE_CONTEXT_PARAMS {
    NvHandle hChannel;
    NvU32    engine;
    NvBool   exists;
} NV208F_CTRL_FIFO_CHECK_ENGINE_CONTEXT_PARAMS;

/*
 * NV208F_CTRL_CMD_FIFO_GET_CHANNEL_STATE
 *
 * This command returns the fifo channel state for the given channel.
 * This is for testing channel behavior.  For debug only.
 *
 *   hChannel 
 *    The handle to the channel
 *   hClient 
 *    The handle to the client
 *   enabled
 *      The channel is able to run.
 *   scheduled
 *      The channel has been scheduled to run.
 *   cpuMap
 *      There is a cpu mapping available to this channel.
 *   contention
 *      The virtual channel is under contention
 *   runlistSet
 *      A runlist has been chosen for this channel
 *   deferRC
 *      An RC error has occurred, but recovery will occur at channel teardown.
 *
 * Possible status values returned are:
 *   NV_OK
 *   NV_ERR_INVALID_DEVICE
 *   NV_ERR_INVALID_CHANNEL
 */
#define NV208F_CTRL_CMD_FIFO_GET_CHANNEL_STATE (0x208f0403) /* finn: Evaluated from "(FINN_NV20_SUBDEVICE_DIAG_FIFO_INTERFACE_ID << 8) | NV208F_CTRL_FIFO_GET_CHANNEL_STATE_PARAMS_MESSAGE_ID" */

#define NV208F_CTRL_FIFO_GET_CHANNEL_STATE_PARAMS_MESSAGE_ID (0x3U)

typedef struct NV208F_CTRL_FIFO_GET_CHANNEL_STATE_PARAMS {
    NvHandle hChannel;
    NvHandle hClient;
    NvBool   bEnabled;
    NvBool   bScheduled;
    NvBool   bCpuMap;
    NvBool   bContention;
    NvBool   bRunlistSet;
    NvBool   bDeferRC;
} NV208F_CTRL_FIFO_GET_CHANNEL_STATE_PARAMS;

/*
 * NV208F_CTRL_CMD_FIFO_GET_CONTIG_RUNLIST_POOL
 *
 * This command returns the location of the pool runlists are allocated from for
 * WPR testing.
 * For debug only.
 *
 * physAddr [out]
 *    Physical address of the pool
 *
 * size [out]
 *    Size in bytes of the pool
 *
 */
#define NV208F_CTRL_CMD_FIFO_GET_CONTIG_RUNLIST_POOL (0x208f0404) /* finn: Evaluated from "(FINN_NV20_SUBDEVICE_DIAG_FIFO_INTERFACE_ID << 8) | NV208F_CTRL_FIFO_GET_CONTIG_RUNLIST_POOL_PARAMS_MESSAGE_ID" */

#define NV208F_CTRL_FIFO_GET_CONTIG_RUNLIST_POOL_PARAMS_MESSAGE_ID (0x4U)

typedef struct NV208F_CTRL_FIFO_GET_CONTIG_RUNLIST_POOL_PARAMS {
    NV_DECLARE_ALIGNED(NvU64 physAddr, 8);
    NV_DECLARE_ALIGNED(NvU64 size, 8);
} NV208F_CTRL_FIFO_GET_CONTIG_RUNLIST_POOL_PARAMS;

/* _ctrl208ffifo_h_ */