|
|
|
|
File: [XFree86 CVS] / xc / programs / Xserver / hw / xfree86 / drivers / ati / atiio.h
(download)
Revision: 1.10, Wed Oct 11 21:52:56 2000 UTC (12 years, 8 months ago) by tsi Branch: MAIN CVS Tags: xf-4_0_3b, xf-4_0_3a, xf-4_0_3, xf-4_0_2c, xf-4_0_2b, xf-4_0_2a, xf-4_0_2-branch, xf-4_0_2-bindist, xf-4_0_2, xf-4_0_1h, xf-4_0_1g, xf-4_0_1f, xf-4_0_1e, xf-4_0_1d, xf-4_0_1Zc, xf-4_0_1Zb, xf-4_0_1Za, xf-4_0_1Z Changes since 1.9: +4 -26 lines 751. Fix int10 so that it rejects BIOS's that are not aligned on a 512-byte
boundary (Marc La France).
750. Fix int10 for ISA adapters on Alpha's (Egbert Eich).
749. Fix for ATI ISA adapters on Alpha's or with -configure (Marc La France).
748. Fix stupid clock probe bug in ATI driver (Marc La France).
747. Reorganise ATI driver in preparation for futuure changes
(Marc La France).
746. Formatting changes to hsync/vrefresh messages (Marc La France).
745. Fix spurious free() when using an ISA adapter (Marc La France).
|
/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/ati/atiio.h,v 1.9 2000/08/22 21:54:30 tsi Exp $ */
/*
* Copyright 1997 through 2000 by Marc Aurele La France (TSI @ UQV), tsi@ualberta.ca
*
* Permission to use, copy, modify, distribute, and sell this software and its
* documentation for any purpose is hereby granted without fee, provided that
* the above copyright notice appear in all copies and that both that copyright
* notice and this permission notice appear in supporting documentation, and
* that the name of Marc Aurele La France not be used in advertising or
* publicity pertaining to distribution of the software without specific,
* written prior permission. Marc Aurele La France makes no representations
* about the suitability of this software for any purpose. It is provided
* "as-is" without express or implied warranty.
*
* MARC AURELE LA FRANCE DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO
* EVENT SHALL MARC AURELE LA FRANCE BE LIABLE FOR ANY SPECIAL, INDIRECT OR
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
* DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
* TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
* PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef ___ATIIO_H___
#if !defined(___ATI_H___) && defined(XFree86Module)
# error missing #include "ati.h" before #include "atiio.h"
# undef XFree86Module
#endif
#define ___ATIIO_H___ 1
#include "atiregs.h"
#ifndef NO_COMPILER_H_EXTRAS
# define NO_COMPILER_H_EXTRAS
#endif
#include "compiler.h"
/* I/O decoding definitions */
typedef enum
{
SPARSE_IO,
BLOCK_IO
} ATIIODecodingType;
#ifndef AVOID_CPIO
/* Wait until "n" queue entries are free */
#define ibm8514WaitQueue(_n) \
{ \
while (inw(GP_STAT) & (0x0100U >> (_n))); \
}
#define ATIWaitQueue(_n) \
{ \
while (inw(EXT_FIFO_STATUS) & (0x010000U >> (_n))); \
}
/* Wait until GP is idle and queue is empty */
#define WaitIdleEmpty() \
{ \
while (inw(GP_STAT) & (GPBUSY | 1)); \
}
#define ProbeWaitIdleEmpty() \
{ \
int _i; \
CARD16 _value; \
for (_i = 0; _i < 100000; _i++) \
{ \
_value = inw(GP_STAT); \
if (_value == (CARD16)(-1)) \
break; \
if (!(_value & (GPBUSY | 1))) \
break; \
} \
}
/* Wait until GP has data available */
#define WaitDataReady() \
{ \
while (!(inw(GP_STAT) & DATARDY)); \
}
#endif /* AVOID_CPIO */
#endif /* ___ATIIO_H___ */
|
Powered by ViewCVS 0.9.2 |