linux/drivers/pcmcia/ricoh.h

/*
 * ricoh.h 1.9 1999/10/25 20:03:34
 *
 * The contents of this file are subject to the Mozilla Public License
 * Version 1.1 (the "License"); you may not use this file except in
 * compliance with the License. You may obtain a copy of the License
 * at http://www.mozilla.org/MPL/
 *
 * Software distributed under the License is distributed on an "AS IS"
 * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
 * the License for the specific language governing rights and
 * limitations under the License. 
 *
 * The initial developer of the original code is David A. Hinds
 * <[email protected]>.  Portions created by David A. Hinds
 * are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
 *
 * Alternatively, the contents of this file may be used under the
 * terms of the GNU General Public License version 2 (the "GPL"), in which
 * case the provisions of the GPL are applicable instead of the
 * above.  If you wish to allow the use of your version of this file
 * only under the terms of the GPL and not to allow others to use
 * your version of this file under the MPL, indicate your decision by
 * deleting the provisions above and replace them with the notice and
 * other provisions required by the GPL.  If you do not delete the
 * provisions above, a recipient may use your version of this file
 * under either the MPL or the GPL.
 */

#ifndef _LINUX_RICOH_H
#define _LINUX_RICOH_H


#define RF5C_MODE_CTL
#define RF5C_PWR_CTL
#define RF5C_CHIP_ID
#define RF5C_MODE_CTL_3

/* I/O window address offset */
#define RF5C_IO_OFF(w)

/* Flags for RF5C_MODE_CTL */
#define RF5C_MODE_ATA
#define RF5C_MODE_LED_ENA
#define RF5C_MODE_CA21
#define RF5C_MODE_CA22
#define RF5C_MODE_CA23
#define RF5C_MODE_CA24
#define RF5C_MODE_CA25
#define RF5C_MODE_3STATE_BIT7

/* Flags for RF5C_PWR_CTL */
#define RF5C_PWR_VCC_3V
#define RF5C_PWR_IREQ_HIGH
#define RF5C_PWR_INPACK_ENA
#define RF5C_PWR_5V_DET
#define RF5C_PWR_TC_SEL
#define RF5C_PWR_DREQ_LOW
#define RF5C_PWR_DREQ_OFF
#define RF5C_PWR_DREQ_INPACK
#define RF5C_PWR_DREQ_SPKR
#define RF5C_PWR_DREQ_IOIS16

/* Values for RF5C_CHIP_ID */
#define RF5C_CHIP_RF5C296
#define RF5C_CHIP_RF5C396

/* Flags for RF5C_MODE_CTL_3 */
#define RF5C_MCTL3_DISABLE
#define RF5C_MCTL3_DMA_ENA

/* Register definitions for Ricoh PCI-to-CardBus bridges */

/* Extra bits in CB_BRIDGE_CONTROL */
#define RL5C46X_BCR_3E0_ENA
#define RL5C46X_BCR_3E2_ENA

/* Bridge Configuration Register */
#define RL5C4XX_CONFIG
#define RL5C4XX_CONFIG_IO_1_MODE
#define RL5C4XX_CONFIG_IO_0_MODE
#define RL5C4XX_CONFIG_PREFETCH

/* Misc Control Register */
#define RL5C4XX_MISC
#define RL5C4XX_MISC_HW_SUSPEND_ENA
#define RL5C4XX_MISC_VCCEN_POL
#define RL5C4XX_MISC_VPPEN_POL
#define RL5C46X_MISC_SUSPEND
#define RL5C46X_MISC_PWR_SAVE_2
#define RL5C46X_MISC_IFACE_BUSY
#define RL5C46X_MISC_B_LOCK
#define RL5C46X_MISC_A_LOCK
#define RL5C46X_MISC_PCI_LOCK
#define RL5C47X_MISC_IFACE_BUSY
#define RL5C47X_MISC_PCI_INT_MASK
#define RL5C47X_MISC_PCI_INT_DIS
#define RL5C47X_MISC_SUBSYS_WR
#define RL5C47X_MISC_SRIRQ_ENA
#define RL5C47X_MISC_5V_DISABLE
#define RL5C47X_MISC_LED_POL

/* 16-bit Interface Control Register */
#define RL5C4XX_16BIT_CTL
#define RL5C4XX_16CTL_IO_TIMING
#define RL5C4XX_16CTL_MEM_TIMING
#define RL5C46X_16CTL_LEVEL_1
#define RL5C46X_16CTL_LEVEL_2

/* 16-bit IO and memory timing registers */
#define RL5C4XX_16BIT_IO_0
#define RL5C4XX_16BIT_MEM_0
#define RL5C4XX_SETUP_MASK
#define RL5C4XX_SETUP_SHIFT
#define RL5C4XX_CMD_MASK
#define RL5C4XX_CMD_SHIFT
#define RL5C4XX_HOLD_MASK
#define RL5C4XX_HOLD_SHIFT
#define RL5C4XX_MISC_CONTROL
#define RL5C4XX_ZV_ENABLE

/* Misc Control 3 Register */
#define RL5C4XX_MISC3
#define RL5C47X_MISC3_CB_CLKRUN_DIS

#ifdef __YENTA_H

#define rl_misc(socket)
#define rl_ctl(socket)
#define rl_io(socket)
#define rl_mem(socket)
#define rl_config(socket)

static void ricoh_zoom_video(struct pcmcia_socket *sock, int onoff)
{}

static void ricoh_set_zv(struct yenta_socket *socket)
{}

static void ricoh_set_clkrun(struct yenta_socket *socket, bool quiet)
{}

static void ricoh_save_state(struct yenta_socket *socket)
{}

static void ricoh_restore_state(struct yenta_socket *socket)
{}


/*
 * Magic Ricoh initialization code..
 */
static int ricoh_override(struct yenta_socket *socket)
{}

#endif /* CONFIG_CARDBUS */

#endif /* _LINUX_RICOH_H */