1218885Sdim/* $NetBSD: nouveau_nvkm_engine_disp_coreg94.c,v 1.3 2021/12/18 23:45:35 riastradh Exp $ */ 2218885Sdim 3218885Sdim/* 4218885Sdim * Copyright 2012 Red Hat Inc. 5218885Sdim * 6218885Sdim * Permission is hereby granted, free of charge, to any person obtaining a 7218885Sdim * copy of this software and associated documentation files (the "Software"), 8218885Sdim * to deal in the Software without restriction, including without limitation 9218885Sdim * the rights to use, copy, modify, merge, publish, distribute, sublicense, 10218885Sdim * and/or sell copies of the Software, and to permit persons to whom the 11218885Sdim * Software is furnished to do so, subject to the following conditions: 12218885Sdim * 13218885Sdim * The above copyright notice and this permission notice shall be included in 14218885Sdim * all copies or substantial portions of the Software. 15218885Sdim * 16218885Sdim * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17218885Sdim * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18218885Sdim * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 19218885Sdim * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR 20218885Sdim * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 21218885Sdim * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 22218885Sdim * OTHER DEALINGS IN THE SOFTWARE. 23218885Sdim * 24218885Sdim * Authors: Ben Skeggs 25218885Sdim */ 26218885Sdim#include <sys/cdefs.h> 27218885Sdim__KERNEL_RCSID(0, "$NetBSD: nouveau_nvkm_engine_disp_coreg94.c,v 1.3 2021/12/18 23:45:35 riastradh Exp $"); 28249423Sdim 29249423Sdim#include "channv50.h" 30249423Sdim 31249423Sdimstatic const struct nv50_disp_mthd_list 32249423Sdimg94_disp_core_mthd_sor = { 33249423Sdim .mthd = 0x0040, 34218885Sdim .addr = 0x000008, 35218885Sdim .data = { 36218885Sdim { 0x0600, 0x610794 }, 37218885Sdim {} 38218885Sdim } 39218885Sdim}; 40218885Sdim 41249423Sdimconst struct nv50_disp_chan_mthd 42218885Sdimg94_disp_core_mthd = { 43218885Sdim .name = "Core", 44218885Sdim .addr = 0x000000, 45218885Sdim .prev = 0x000004, 46218885Sdim .data = { 47218885Sdim { "Global", 1, &nv50_disp_core_mthd_base }, 48218885Sdim { "DAC", 3, &g84_disp_core_mthd_dac }, 49218885Sdim { "SOR", 4, &g94_disp_core_mthd_sor }, 50218885Sdim { "PIOR", 3, &nv50_disp_core_mthd_pior }, 51218885Sdim { "HEAD", 2, &g84_disp_core_mthd_head }, 52218885Sdim {} 53218885Sdim } 54218885Sdim}; 55218885Sdim 56218885Sdimint 57218885Sdimg94_disp_core_new(const struct nvkm_oclass *oclass, void *argv, u32 argc, 58218885Sdim struct nv50_disp *disp, struct nvkm_object **pobject) 59218885Sdim{ 60218885Sdim return nv50_disp_core_new_(&nv50_disp_core_func, &g94_disp_core_mthd, 61218885Sdim disp, 0, oclass, argv, argc, pobject); 62218885Sdim} 63218885Sdim