diff options
Diffstat (limited to 'arch/powerpc/include/asm/fsl_guts.h')
| -rw-r--r-- | arch/powerpc/include/asm/fsl_guts.h | 38 | 
1 files changed, 15 insertions, 23 deletions
diff --git a/arch/powerpc/include/asm/fsl_guts.h b/arch/powerpc/include/asm/fsl_guts.h index bebd12463ec..77ced0b3d81 100644 --- a/arch/powerpc/include/asm/fsl_guts.h +++ b/arch/powerpc/include/asm/fsl_guts.h @@ -4,7 +4,7 @@   * Authors: Jeff Brown   *          Timur Tabi <timur@freescale.com>   * - * Copyright 2004,2007 Freescale Semiconductor, Inc + * Copyright 2004,2007,2012 Freescale Semiconductor, Inc   *   * This program is free software; you can redistribute  it and/or modify it   * under  the terms of  the GNU General  Public License as published by the @@ -16,15 +16,6 @@  #define __ASM_POWERPC_FSL_GUTS_H__  #ifdef __KERNEL__ -/* - * These #ifdefs are safe because it's not possible to build a kernel that - * runs on e500 and e600 cores. - */ - -#if !defined(CONFIG_PPC_85xx) && !defined(CONFIG_PPC_86xx) -#error Only 85xx and 86xx SOCs are supported -#endif -  /**   * Global Utility Registers.   * @@ -36,11 +27,7 @@   * different names.  In these cases, one name is chosen to avoid extraneous   * #ifdefs.   */ -#ifdef CONFIG_PPC_85xx -struct ccsr_guts_85xx { -#else -struct ccsr_guts_86xx { -#endif +struct ccsr_guts {  	__be32	porpllsr;	/* 0x.0000 - POR PLL Ratio Status Register */  	__be32	porbmsr;	/* 0x.0004 - POR Boot Mode Status Register */  	__be32	porimpscr;	/* 0x.0008 - POR I/O Impedance Status and Control Register */ @@ -61,6 +48,8 @@ struct ccsr_guts_86xx {          __be32  dmuxcr;		/* 0x.0068 - DMA Mux Control Register */          u8	res06c[0x70 - 0x6c];  	__be32	devdisr;	/* 0x.0070 - Device Disable Control */ +#define CCSR_GUTS_DEVDISR_TB1	0x00001000 +#define CCSR_GUTS_DEVDISR_TB0	0x00004000  	__be32	devdisr2;	/* 0x.0074 - Device Disable Control 2 */  	u8	res078[0x7c - 0x78];  	__be32  pmjcr;		/* 0x.007c - 4 Power Management Jog Control Register */ @@ -77,15 +66,14 @@ struct ccsr_guts_86xx {  	u8	res0a8[0xb0 - 0xa8];  	__be32	rstcr;		/* 0x.00b0 - Reset Control Register */  	u8	res0b4[0xc0 - 0xb4]; -#ifdef CONFIG_PPC_85xx -	__be32  iovselsr;	/* 0x.00c0 - I/O voltage select status register */ -#else -	__be32	elbcvselcr;	/* 0x.00c0 - eLBC Voltage Select Ctrl Reg */ -#endif +	__be32  iovselsr;	/* 0x.00c0 - I/O voltage select status register +					     Called 'elbcvselcr' on 86xx SOCs */  	u8	res0c4[0x224 - 0xc4];  	__be32  iodelay1;	/* 0x.0224 - IO delay control register 1 */  	__be32  iodelay2;	/* 0x.0228 - IO delay control register 2 */ -	u8	res22c[0x800 - 0x22c]; +	u8	res22c[0x604 - 0x22c]; +	__be32	pamubypenr; 	/* 0x.604 - PAMU bypass enable register */ +	u8	res608[0x800 - 0x608];  	__be32	clkdvdr;	/* 0x.0800 - Clock Divide Register */  	u8	res804[0x900 - 0x804];  	__be32	ircr;		/* 0x.0900 - Infrared Control Register */ @@ -114,6 +102,10 @@ struct ccsr_guts_86xx {  	__be32	srds2cr1;	/* 0x.0f44 - SerDes2 Control Register 0 */  } __attribute__ ((packed)); + +/* Alternate function signal multiplex control */ +#define MPC85xx_PMUXCR_QE(x) (0x8000 >> (x)) +  #ifdef CONFIG_PPC_86xx  #define CCSR_GUTS_DMACR_DEV_SSI	0	/* DMA controller/channel set to SSI */ @@ -132,7 +124,7 @@ struct ccsr_guts_86xx {   * ch: The channel on the DMA controller (0, 1, 2, or 3)   * device: The device to set as the source (CCSR_GUTS_DMACR_DEV_xx)   */ -static inline void guts_set_dmacr(struct ccsr_guts_86xx __iomem *guts, +static inline void guts_set_dmacr(struct ccsr_guts __iomem *guts,  	unsigned int co, unsigned int ch, unsigned int device)  {  	unsigned int shift = 16 + (8 * (1 - co) + 2 * (3 - ch)); @@ -168,7 +160,7 @@ static inline void guts_set_dmacr(struct ccsr_guts_86xx __iomem *guts,   * ch: The channel on the DMA controller (0, 1, 2, or 3)   * value: the new value for the bit (0 or 1)   */ -static inline void guts_set_pmuxcr_dma(struct ccsr_guts_86xx __iomem *guts, +static inline void guts_set_pmuxcr_dma(struct ccsr_guts __iomem *guts,  	unsigned int co, unsigned int ch, unsigned int value)  {  	if ((ch == 0) || (ch == 3)) {  | 
