1/* 2 * Platform specific SBUS and OpenPROM access declarations. 3 * 4 * Copyright (C) 2000 Jakub Jelinek (jakub@redhat.com) 5 * 6 * Permission is hereby granted, free of charge, to any person obtaining a copy 7 * of this software and associated documentation files (the "Software"), to deal 8 * in the Software without restriction, including without limitation the rights 9 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 * copies of the Software, and to permit persons to whom the Software is 11 * furnished to do so, subject to the following conditions: 12 * 13 * The above copyright notice and this permission notice shall be included in 14 * all copies or substantial portions of the Software. 15 * 16 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 19 * JAKUB JELINEK BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 20 * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 21 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 22 */ 23 24#ifdef HAVE_XORG_CONFIG_H 25#include <xorg-config.h> 26#endif 27 28#ifndef _XF86_SBUS_H 29#define _XF86_SBUS_H 30 31#if defined(linux) 32#include <asm/types.h> 33#include <linux/fb.h> 34#include <asm/fbio.h> 35#include <asm/openpromio.h> 36#elif defined(SVR4) 37#include <sys/fbio.h> 38#include <sys/openpromio.h> 39#elif defined(__OpenBSD__) && defined(__sparc64__) 40/* XXX */ 41#elif defined(CSRG_BASED) 42#if defined(__FreeBSD__) 43#include <sys/types.h> 44#include <sys/fbio.h> 45#include <dev/ofw/openpromio.h> 46#elif defined(__NetBSD__) 47#include <dev/sun/fbio.h> 48#include <dev/ofw/openfirmio.h> 49#else 50#include <machine/fbio.h> 51#endif 52#else 53#include <sun/fbio.h> 54#endif 55 56#ifdef __NetBSD__ 57#ifndef FBTYPE_SUN2BW 58# define FBTYPE_SUN2BW 2 59#endif 60 61#ifndef FBTYPE_SUN2COLOR 62# define FBTYPE_SUN2COLOR 3 63#endif 64 65#ifndef FBTYPE_SUN3COLOR 66# define FBTYPE_SUN3COLOR 6 67#endif 68 69#ifndef FBTYPE_SUNFAST_COLOR 70# define FBTYPE_SUNFAST_COLOR 12 71#endif 72 73#ifndef FBTYPE_SUNGP3 74# define FBTYPE_SUNGP3 17 75#endif 76 77#ifndef FBTYPE_SUNGT 78# define FBTYPE_SUNGT 18 79#endif 80 81#ifndef FBTYPE_SUNLEO 82# define FBTYPE_SUNLEO 19 83#endif 84 85#ifndef FBTYPE_MDICOLOR 86# ifdef CSRG_BASED 87# define FBTYPE_MDICOLOR 28 88# else 89# define FBTYPE_MDICOLOR 20 90# endif 91#endif 92 93#ifndef FBTYPE_TCXCOLOR 94# ifdef CSRG_BASED 95# define FBTYPE_TCXCOLOR 29 96# else 97# define FBTYPE_TCXCOLOR 21 98# endif 99#endif 100 101#ifndef FBTYPE_CREATOR 102# define FBTYPE_CREATOR 22 103#endif 104 105#ifndef FBTYPE_P9100 106#define FBTYPE_P9100 21 107#endif 108 109#ifndef FBTYPE_AG10E 110#define FBTYPE_AG10E 24 111#endif 112 113#else /* !__NetBSD__ */ 114 115#ifndef FBTYPE_SUNGP3 116#define FBTYPE_SUNGP3 -1 117#endif 118#ifndef FBTYPE_MDICOLOR 119#define FBTYPE_MDICOLOR -1 120#endif 121#ifndef FBTYPE_SUNLEO 122#define FBTYPE_SUNLEO -1 123#endif 124#ifndef FBTYPE_TCXCOLOR 125#define FBTYPE_TCXCOLOR -1 126#endif 127#ifndef FBTYPE_CREATOR 128#define FBTYPE_CREATOR -1 129#endif 130 131#endif /* __NetBSD__ */ 132 133#endif /* _XF86_SBUS_H */ 134