f78b12e570284aa8291f4ca1add24937fd107403vboxsync/*
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * Copyright (c) 1997-2003 by The XFree86 Project, Inc.
f78b12e570284aa8291f4ca1add24937fd107403vboxsync *
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * Permission is hereby granted, free of charge, to any person obtaining a
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * copy of this software and associated documentation files (the "Software"),
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * to deal in the Software without restriction, including without limitation
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * the rights to use, copy, modify, merge, publish, distribute, sublicense,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * and/or sell copies of the Software, and to permit persons to whom the
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * Software is furnished to do so, subject to the following conditions:
f78b12e570284aa8291f4ca1add24937fd107403vboxsync *
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * The above copyright notice and this permission notice shall be included in
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * all copies or substantial portions of the Software.
f78b12e570284aa8291f4ca1add24937fd107403vboxsync *
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * OTHER DEALINGS IN THE SOFTWARE.
f78b12e570284aa8291f4ca1add24937fd107403vboxsync *
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * Except as contained in this notice, the name of the copyright holder(s)
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * and author(s) shall not be used in advertising or otherwise to promote
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * the sale, use or other dealings in this Software without prior written
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * authorization from the copyright holder(s) and author(s).
f78b12e570284aa8291f4ca1add24937fd107403vboxsync */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync
f78b12e570284aa8291f4ca1add24937fd107403vboxsync/*
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * This file contains definitions of the bus-related data structures/types.
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * Everything contained here is private to xf86Bus.c. In particular the
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * video drivers must not include this file.
f78b12e570284aa8291f4ca1add24937fd107403vboxsync */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#ifdef HAVE_XORG_CONFIG_H
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#include <xorg-config.h>
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#endif
f78b12e570284aa8291f4ca1add24937fd107403vboxsync
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#ifndef _XF86_BUS_H
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#define _XF86_BUS_H
f78b12e570284aa8291f4ca1add24937fd107403vboxsync
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#include "xf86pciBus.h"
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#if defined(__sparc__) || defined(__sparc)
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#include "xf86sbusBus.h"
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#endif
f78b12e570284aa8291f4ca1add24937fd107403vboxsync
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef struct {
f78b12e570284aa8291f4ca1add24937fd107403vboxsync DriverPtr driver;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int chipset;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int entityProp;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync EntityProc entityInit;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync EntityProc entityEnter;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync EntityProc entityLeave;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync pointer private;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync Bool active;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync Bool inUse;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync BusRec bus;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int lastScrnFlag;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync DevUnion * entityPrivates;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int numInstances;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync GDevPtr * devices;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync IOADDRESS domainIO;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync} EntityRec, *EntityPtr;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#define ACCEL_IS_SHARABLE 0x100
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#define IS_SHARED_ACCEL 0x200
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#define SA_PRIM_INIT_DONE 0x400
f78b12e570284aa8291f4ca1add24937fd107403vboxsync
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncextern EntityPtr *xf86Entities;
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncextern int xf86NumEntities;
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncextern BusRec primaryBus;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncint xf86AllocateEntity(void);
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncBusType StringToBusType(const char* busID, const char **retID);
f78b12e570284aa8291f4ca1add24937fd107403vboxsync
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#endif /* _XF86_BUS_H */