17c4f87c9SBen Skeggs /* 27c4f87c9SBen Skeggs * Copyright 2016 Red Hat Inc. 37c4f87c9SBen Skeggs * 47c4f87c9SBen Skeggs * Permission is hereby granted, free of charge, to any person obtaining a 57c4f87c9SBen Skeggs * copy of this software and associated documentation files (the "Software"), 67c4f87c9SBen Skeggs * to deal in the Software without restriction, including without limitation 77c4f87c9SBen Skeggs * the rights to use, copy, modify, merge, publish, distribute, sublicense, 87c4f87c9SBen Skeggs * and/or sell copies of the Software, and to permit persons to whom the 97c4f87c9SBen Skeggs * Software is furnished to do so, subject to the following conditions: 107c4f87c9SBen Skeggs * 117c4f87c9SBen Skeggs * The above copyright notice and this permission notice shall be included in 127c4f87c9SBen Skeggs * all copies or substantial portions of the Software. 137c4f87c9SBen Skeggs * 147c4f87c9SBen Skeggs * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 157c4f87c9SBen Skeggs * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 167c4f87c9SBen Skeggs * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 177c4f87c9SBen Skeggs * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR 187c4f87c9SBen Skeggs * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 197c4f87c9SBen Skeggs * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 207c4f87c9SBen Skeggs * OTHER DEALINGS IN THE SOFTWARE. 217c4f87c9SBen Skeggs * 227c4f87c9SBen Skeggs * Authors: Ben Skeggs 237c4f87c9SBen Skeggs */ 247c4f87c9SBen Skeggs #include "gk104.h" 257c4f87c9SBen Skeggs #include "changk104.h" 267c4f87c9SBen Skeggs 2798ac3f06SBen Skeggs static const struct gk104_fifo_func 287c4f87c9SBen Skeggs gm107_fifo = { 2991419acfSBen Skeggs .fault.engine = gk104_fifo_fault_engine, 3091419acfSBen Skeggs .fault.reason = gk104_fifo_fault_reason, 3191419acfSBen Skeggs .fault.hubclient = gk104_fifo_fault_hubclient, 3291419acfSBen Skeggs .fault.gpcclient = gk104_fifo_fault_gpcclient, 337c4f87c9SBen Skeggs .chan = { 347c4f87c9SBen Skeggs &gk110_fifo_gpfifo_oclass, 357c4f87c9SBen Skeggs NULL 367c4f87c9SBen Skeggs }, 377c4f87c9SBen Skeggs }; 387c4f87c9SBen Skeggs 397c4f87c9SBen Skeggs int 407c4f87c9SBen Skeggs gm107_fifo_new(struct nvkm_device *device, int index, struct nvkm_fifo **pfifo) 417c4f87c9SBen Skeggs { 427c4f87c9SBen Skeggs return gk104_fifo_new_(&gm107_fifo, device, index, 2048, pfifo); 437c4f87c9SBen Skeggs } 44