18c2ecf20Sopenharmony_ci#ifndef __NVIF_PUSH006C_H__ 28c2ecf20Sopenharmony_ci#define __NVIF_PUSH006C_H__ 38c2ecf20Sopenharmony_ci#include <nvif/push.h> 48c2ecf20Sopenharmony_ci 58c2ecf20Sopenharmony_ci#include <nvhw/class/cl006c.h> 68c2ecf20Sopenharmony_ci 78c2ecf20Sopenharmony_ci#ifndef PUSH006C_SUBC 88c2ecf20Sopenharmony_ci// Host methods 98c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV06E 0 108c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV176E 0 118c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV826F 0 128c2ecf20Sopenharmony_ci 138c2ecf20Sopenharmony_ci// ContextSurfaces2d 148c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV042 0 158c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV062 0 168c2ecf20Sopenharmony_ci 178c2ecf20Sopenharmony_ci// ContextClipRectangle 188c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV019 0 198c2ecf20Sopenharmony_ci 208c2ecf20Sopenharmony_ci// ContextRop 218c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV043 0 228c2ecf20Sopenharmony_ci 238c2ecf20Sopenharmony_ci// ContextPattern 248c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV044 0 258c2ecf20Sopenharmony_ci 268c2ecf20Sopenharmony_ci// Misc dodginess... 278c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV_SW 1 288c2ecf20Sopenharmony_ci 298c2ecf20Sopenharmony_ci// ImageBlit 308c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV05F 2 318c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV09F 2 328c2ecf20Sopenharmony_ci 338c2ecf20Sopenharmony_ci// GdiRectangleText 348c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV04A 3 358c2ecf20Sopenharmony_ci 368c2ecf20Sopenharmony_ci// Twod 378c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV502D 3 388c2ecf20Sopenharmony_ci 398c2ecf20Sopenharmony_ci// MemoryToMemoryFormat 408c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV039 4 418c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV5039 4 428c2ecf20Sopenharmony_ci 438c2ecf20Sopenharmony_ci// DmaCopy 448c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV85B5 4 458c2ecf20Sopenharmony_ci 468c2ecf20Sopenharmony_ci// Cipher 478c2ecf20Sopenharmony_ci#define PUSH006C_SUBC_NV74C1 4 488c2ecf20Sopenharmony_ci#endif 498c2ecf20Sopenharmony_ci 508c2ecf20Sopenharmony_ci#define PUSH_HDR(p,o,n,s,m,c) do { \ 518c2ecf20Sopenharmony_ci PUSH_ASSERT(!((s) & ~DRF_MASK(NV06C_METHOD_SUBCHANNEL)), "subc"); \ 528c2ecf20Sopenharmony_ci PUSH_ASSERT(!((m) & ~DRF_SMASK(NV06C_METHOD_ADDRESS)), "mthd"); \ 538c2ecf20Sopenharmony_ci PUSH_ASSERT(!((c) & ~DRF_MASK(NV06C_METHOD_COUNT)), "count"); \ 548c2ecf20Sopenharmony_ci PUSH_DATA__((p), NVVAL_X(NV06C_METHOD_ADDRESS, (m) >> 2) | \ 558c2ecf20Sopenharmony_ci NVVAL_X(NV06C_METHOD_SUBCHANNEL, (s)) | \ 568c2ecf20Sopenharmony_ci NVVAL_X(NV06C_METHOD_COUNT, (c)) | \ 578c2ecf20Sopenharmony_ci NVVAL_X(NV06C_OPCODE, NV06C_OPCODE_##o), \ 588c2ecf20Sopenharmony_ci " "n" subc %d mthd 0x%04x size %d - %s", \ 598c2ecf20Sopenharmony_ci (u32)(s), (u32)(m), (u32)(c), __func__); \ 608c2ecf20Sopenharmony_ci} while(0) 618c2ecf20Sopenharmony_ci 628c2ecf20Sopenharmony_ci#define PUSH_MTHD_HDR(p,c,m,n) PUSH_HDR(p, METHOD, "incr", PUSH006C_SUBC_##c, m, n) 638c2ecf20Sopenharmony_ci#define PUSH_MTHD_INC 4:4 648c2ecf20Sopenharmony_ci#define PUSH_NINC_HDR(p,c,m,n) PUSH_HDR(p, NONINC_METHOD, "ninc", PUSH006C_SUBC_##c, m, n) 658c2ecf20Sopenharmony_ci#define PUSH_NINC_INC 0:0 668c2ecf20Sopenharmony_ci 678c2ecf20Sopenharmony_ci#define PUSH_JUMP(p,o) do { \ 688c2ecf20Sopenharmony_ci PUSH_ASSERT(!((o) & ~0x1fffffffcULL), "offset"); \ 698c2ecf20Sopenharmony_ci PUSH_DATA__((p), NVVAL_X(NV06C_OPCODE, NV06C_OPCODE_JUMP) | \ 708c2ecf20Sopenharmony_ci NVVAL_X(NV06C_JUMP_OFFSET, (o) >> 2), \ 718c2ecf20Sopenharmony_ci " jump 0x%08x - %s", (u32)(o), __func__); \ 728c2ecf20Sopenharmony_ci} while(0) 738c2ecf20Sopenharmony_ci#endif 74