1193323Sed/*- 2193323Sed * Copyright 2004 The Unichrome Project. All Rights Reserved. 3193323Sed * 4193323Sed * Permission is hereby granted, free of charge, to any person obtaining a 5193323Sed * copy of this software and associated documentation files (the "Software"), 6193323Sed * to deal in the Software without restriction, including without limitation 7193323Sed * the rights to use, copy, modify, merge, publish, distribute, sub license, 8193323Sed * and/or sell copies of the Software, and to permit persons to whom the 9193323Sed * Software is furnished to do so, subject to the following conditions: 10210299Sed * 11198090Srdivacky * The above copyright notice and this permission notice (including the 12193323Sed * next paragraph) shall be included in all copies or substantial portions 13198090Srdivacky * of the Software. 14198090Srdivacky * 15198090Srdivacky * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16198090Srdivacky * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17193323Sed * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL 18193323Sed * THE UNICHROME PROJECT, AND/OR ITS SUPPLIERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 19193323Sed * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 20193323Sed * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 21249423Sdim * DEALINGS IN THE SOFTWARE. 22249423Sdim * 23249423Sdim * Author: Thomas Hellstr��m 2004. 24193323Sed */ 25207618Srdivacky 26249423Sdim#ifndef _VIA_VERIFIER_H_ 27212904Sdim#define _VIA_VERIFIER_H_ 28193323Sed 29198090Srdivackytypedef enum { 30249423Sdim no_sequence = 0, 31249423Sdim z_address, 32249423Sdim dest_address, 33193323Sed tex_address 34193323Sed} drm_via_sequence_t; 35234353Sdim 36212904Sdimtypedef struct { 37212904Sdim unsigned texture; 38218893Sdim uint32_t z_addr; 39193323Sed uint32_t d_addr; 40218893Sdim uint32_t t_addr[2][10]; 41218893Sdim uint32_t pitch[2][10]; 42218893Sdim uint32_t height[2][10]; 43212904Sdim uint32_t tex_level_lo[2]; 44193323Sed uint32_t tex_level_hi[2]; 45198892Srdivacky uint32_t tex_palette_size[2]; 46193323Sed uint32_t tex_npot[2]; 47198090Srdivacky drm_via_sequence_t unfinished; 48218893Sdim int agp_texture; 49198090Srdivacky int multitex; 50207618Srdivacky struct drm_device *dev; 51198090Srdivacky drm_local_map_t *map_cache; 52193323Sed uint32_t vertex_count; 53218893Sdim int agp; 54218893Sdim const uint32_t *buf_start; 55218893Sdim} drm_via_state_t; 56218893Sdim 57193323Sedextern int via_verify_command_stream(const uint32_t * buf, unsigned int size, 58193323Sed struct drm_device * dev, int agp); 59218893Sdimextern int via_parse_command_stream(struct drm_device *dev, const uint32_t *buf, 60218893Sdim unsigned int size); 61218893Sdim 62210299Sed#endif 63193323Sed