/*
* Copyright (c) 2002 Steve Rumble
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* 3. The name of the author may not be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
* IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
* NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#define PIC_MEMCFG_BADSIZ 0x0000 /* bad memory size */
#define PIC_MEMCFG_ADDRMASK 0x003f /* memory address mask */
#define PIC_MEMCFG_BADADDR 0x003f /* no memory in bank */
#define PIC_MEMCFG_SIZMASK 0x0f00 /* bank size mask */
/*
* The bank memory address is computed the same way mc's is.
* Size is similar, only having one less bit (max. 64MB per bank).
*/
#define PIC_MEMCFG_ADDR(x) \
((x & PIC_MEMCFG_ADDRMASK) << 22)
#define PIC_MEMCFG_SIZ(x) \
(((x & PIC_MEMCFG_SIZMASK) + 0x100) << 14)
#define PIC_WRONLY_REFRESH 0x10100 /* write only refresh timer */
/*
* GIO slot configuration registers described by the 'GIO BUS Specification'
* apparently no IP20 counterpart on mc.
*/
#define PIC_GIO32ARB_SLOT0 0x20000 /* set slot 0 config */
#define PIC_GIO32ARB_SLOT1 0x20004 /* set slot 1 config */
#define PIC_GIO32ARB_SLOT_SLAVE 0x0001 /* slave only */
#define PIC_GIO32ARB_SLOT_LONG 0x0002 /* long burst */
#define PIC_GIO32ARB_BURST 0x20008 /* set gio burst */
#define PIC_GIO32ARB_DEFBURST 0x0001 /* default burst value */
#define PIC_GIO32ARB_DELAY 0x2000c /* set gio delay */
#define PIC_GIO32ARB_DEFDELAY 0x00f2 /* default delay value */