Home | History | Annotate | Line # | Download | only in sa11x0
sa11x0_mcpreg.h revision 1.1.132.1
      1  1.1.132.1  yamt /*	$NetBSD: sa11x0_mcpreg.h,v 1.1.132.1 2008/05/18 12:31:40 yamt Exp $	*/
      2        1.1   rjs 
      3        1.1   rjs /*-
      4        1.1   rjs  * Copyright (c) 2001 The NetBSD Foundation, Inc.  All rights reserved.
      5        1.1   rjs  *
      6        1.1   rjs  * This code is derived from software contributed to The NetBSD Foundation
      7        1.1   rjs  * by Ichiro FUKUHARA (ichiro (at) ichiro.org).
      8        1.1   rjs  *
      9        1.1   rjs  * Redistribution and use in source and binary forms, with or without
     10        1.1   rjs  * modification, are permitted provided that the following conditions
     11        1.1   rjs  * are met:
     12        1.1   rjs  * 1. Redistributions of source code must retain the above copyright
     13        1.1   rjs  *    notice, this list of conditions and the following disclaimer.
     14        1.1   rjs  * 2. Redistributions in binary form must reproduce the above copyright
     15        1.1   rjs  *    notice, this list of conditions and the following disclaimer in the
     16        1.1   rjs  *    documentation and/or other materials provided with the distribution.
     17        1.1   rjs  *
     18        1.1   rjs  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
     19        1.1   rjs  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
     20        1.1   rjs  * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
     21        1.1   rjs  * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
     22        1.1   rjs  * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
     23        1.1   rjs  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
     24        1.1   rjs  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
     25        1.1   rjs  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
     26        1.1   rjs  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
     27        1.1   rjs  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
     28        1.1   rjs  * POSSIBILITY OF SUCH DAMAGE.
     29        1.1   rjs  */
     30        1.1   rjs 
     31        1.1   rjs /* SA11[01]0 MCP(Multimedia communications Port) */
     32        1.1   rjs 
     33        1.1   rjs #define SAMCP_NPORTS	7
     34        1.1   rjs 
     35        1.1   rjs #define SAMCP_CR0	0x00	/* MCP control register 0 */
     36        1.1   rjs /* MCP control register 1 locate PPC area */
     37        1.1   rjs 
     38        1.1   rjs #define SAMCP_DR0	0x08	/* MCP data register 0 */
     39        1.1   rjs #define SAMCP_DR1	0x0C	/* MCP data register 1 */
     40        1.1   rjs #define SAMCP_DR2	0x10	/* MCP data register 2 */
     41        1.1   rjs #define SAMCP_SR	0x18	/* MCP status register */
     42        1.1   rjs 
     43        1.1   rjs /* MCP control register 0*/
     44        1.1   rjs #define CR0_ASD
     45        1.1   rjs #define CR0_TSD
     46        1.1   rjs #define CR0_MCE		(1 << 16)	/* MCP enable */
     47        1.1   rjs #define CR0_ECS		(1 << 17)	/* External clock used */
     48        1.1   rjs #define CR0_ADM		(1 << 18)	/* A/D sampling mode */
     49        1.1   rjs #define CR0_TTE		(1 << 19)	/* Telecom tx FIFO intr enable */
     50        1.1   rjs #define CR0_TRE		(1 << 20)	/* Telecom rx FIFO intr enable */
     51        1.1   rjs #define CR0_ATE		(1 << 21) 	/* Audio tx FIFO intr enable */
     52        1.1   rjs #define CR0_ARE		(1 << 22) 	/* Audio rx FIFO intr enable */
     53        1.1   rjs #define CR0_LBM		(1 << 23)	/* Output of serial shifter connect
     54        1.1   rjs 					   to Input of serial shifter internal */
     55        1.1   rjs #define CR0_ECP(x)	((x) << 24)	/* External clock prescaler */
     56        1.1   rjs 
     57        1.1   rjs /* MCP control register 0 */
     58        1.1   rjs #define CR1_CFS		(1 << 20)
     59        1.1   rjs 
     60        1.1   rjs /* MCP status register */
     61        1.1   rjs #define SR_ATS		(1 << 0)	/* Audio transmit FIFO req-flag */
     62        1.1   rjs #define SR_ARS		(1 << 1)	/* Audio receive FIFO req */
     63        1.1   rjs #define SR_TTS		(1 << 2)	/* Telecom transmit FIFO req-flag */
     64        1.1   rjs #define SR_TRS		(1 << 3)	/* Telecom receive FIFO req */
     65        1.1   rjs #define SR_ATU		(1 << 4)	/* Audio transmit FIFO underrun */
     66        1.1   rjs #define SR_ARO		(1 << 5) 	/* Audio receive FIFO overrun */
     67        1.1   rjs #define SR_TTU		(1 << 6)	/* Telecom transmit FIFO underrun */
     68        1.1   rjs #define SR_TRO		(1 << 7)	/* Telecom receive FIFO overrun */
     69        1.1   rjs #define SR_ANF		(1 << 8)	/* Audio transmit FIFO not full */
     70        1.1   rjs #define SR_ANE		(1 << 9)	/* Audio receive FIFO not empty */
     71        1.1   rjs #define SR_TNF		(1 << 10)	/* Telecom transmit FIFO not full */
     72        1.1   rjs #define SR_TNE		(1 << 11)	/* Telecom receive FIFO not empty */
     73        1.1   rjs #define SR_CWC		(1 << 12)	/* Codec write completed */
     74        1.1   rjs #define SR_CRC		(1 << 13)	/* Codec read completed */
     75        1.1   rjs #define SR_ACE		(1 << 14)	/* Audio codec enabled */
     76        1.1   rjs #define SR_TCE		(1 << 15)	/* Telecom codec enabled */
     77        1.1   rjs 
     78