diff options
| -rw-r--r-- | board/freescale/m54455evb/m54455evb.c | 2 | ||||
| -rw-r--r-- | cpu/mcf5227x/cpu_init.c | 12 | ||||
| -rw-r--r-- | cpu/mcf52x2/cpu_init.c | 14 | ||||
| -rw-r--r-- | cpu/mcf532x/cpu_init.c | 12 | ||||
| -rw-r--r-- | cpu/mcf532x/speed.c | 2 | ||||
| -rw-r--r-- | cpu/mcf5445x/cpu_init.c | 4 | ||||
| -rw-r--r-- | include/asm-m68k/m520x.h | 89 | ||||
| -rw-r--r-- | include/asm-m68k/m5227x.h | 108 | ||||
| -rw-r--r-- | include/asm-m68k/m5235.h | 4 | ||||
| -rw-r--r-- | include/asm-m68k/m5301x.h | 112 | ||||
| -rw-r--r-- | include/asm-m68k/m5445x.h | 56 | 
11 files changed, 206 insertions, 209 deletions
| diff --git a/board/freescale/m54455evb/m54455evb.c b/board/freescale/m54455evb/m54455evb.c index 293b5b0e4..866694fb0 100644 --- a/board/freescale/m54455evb/m54455evb.c +++ b/board/freescale/m54455evb/m54455evb.c @@ -107,7 +107,7 @@ int ide_preinit(void)  {  	volatile gpio_t *gpio = (gpio_t *) MMAP_GPIO; -	gpio->par_fec |= (gpio->par_fec & GPIO_PAR_FEC_FEC1_MASK) | 0x10; +	gpio->par_fec |= (gpio->par_fec & GPIO_PAR_FEC_FEC1_UNMASK) | 0x10;  	gpio->par_feci2c |=  	    (gpio->par_feci2c & 0xF0FF) | (GPIO_PAR_FECI2C_MDC1_ATA_DIOR |  					   GPIO_PAR_FECI2C_MDIO1_ATA_DIOW); diff --git a/cpu/mcf5227x/cpu_init.c b/cpu/mcf5227x/cpu_init.c index e160ee1af..d336857ed 100644 --- a/cpu/mcf5227x/cpu_init.c +++ b/cpu/mcf5227x/cpu_init.c @@ -133,19 +133,19 @@ void uart_port_conf(void)  	switch (CONFIG_SYS_UART_PORT) {  	case 0:  		gpio->par_uart &= -		    (GPIO_PAR_UART_U0TXD_MASK & GPIO_PAR_UART_U0RXD_MASK); +		    (GPIO_PAR_UART_U0TXD_UNMASK & GPIO_PAR_UART_U0RXD_UNMASK);  		gpio->par_uart |=  		    (GPIO_PAR_UART_U0TXD_U0TXD | GPIO_PAR_UART_U0RXD_U0RXD);  		break;  	case 1:  		gpio->par_uart &= -		    (GPIO_PAR_UART_U1TXD_MASK & GPIO_PAR_UART_U1RXD_MASK); +		    (GPIO_PAR_UART_U1TXD_UNMASK & GPIO_PAR_UART_U1RXD_UNMASK);  		gpio->par_uart |=  		    (GPIO_PAR_UART_U1TXD_U1TXD | GPIO_PAR_UART_U1RXD_U1RXD);  		break;  	case 2:  		gpio->par_dspi &= -		    (GPIO_PAR_DSPI_SIN_MASK & GPIO_PAR_DSPI_SOUT_MASK); +		    (GPIO_PAR_DSPI_SIN_UNMASK & GPIO_PAR_DSPI_SOUT_UNMASK);  		gpio->par_dspi =  		    (GPIO_PAR_DSPI_SIN_U2RXD | GPIO_PAR_DSPI_SOUT_U2TXD);  		break; @@ -175,11 +175,11 @@ int cfspi_claim_bus(uint bus, uint cs)  	switch (cs) {  	case 0: -		gpio->par_dspi &= ~GPIO_PAR_DSPI_PCS0_MASK; +		gpio->par_dspi &= ~GPIO_PAR_DSPI_PCS0_UNMASK;  		gpio->par_dspi |= GPIO_PAR_DSPI_PCS0_PCS0;  		break;  	case 2: -		gpio->par_timer &= GPIO_PAR_TIMER_T2IN_MASK; +		gpio->par_timer &= GPIO_PAR_TIMER_T2IN_UNMASK;  		gpio->par_timer |= GPIO_PAR_TIMER_T2IN_DSPIPCS2;  		break;  	} @@ -199,7 +199,7 @@ void cfspi_release_bus(uint bus, uint cs)  		gpio->par_dspi &= ~GPIO_PAR_DSPI_PCS0_PCS0;  		break;  	case 2: -		gpio->par_timer &= GPIO_PAR_TIMER_T2IN_MASK; +		gpio->par_timer &= GPIO_PAR_TIMER_T2IN_UNMASK;  		break;  	}  } diff --git a/cpu/mcf52x2/cpu_init.c b/cpu/mcf52x2/cpu_init.c index 5b06930df..747c1cf90 100644 --- a/cpu/mcf52x2/cpu_init.c +++ b/cpu/mcf52x2/cpu_init.c @@ -142,29 +142,29 @@ void uart_port_conf(void)  	/* Setup Ports: */  	switch (CONFIG_SYS_UART_PORT) {  	case 0: -		gpio->par_uart &= GPIO_PAR_UART0_MASK; +		gpio->par_uart &= GPIO_PAR_UART0_UNMASK;  		gpio->par_uart |= (GPIO_PAR_UART_U0TXD | GPIO_PAR_UART_U0RXD);  		break;  	case 1: -		gpio->par_uart &= GPIO_PAR_UART0_MASK; +		gpio->par_uart &= GPIO_PAR_UART0_UNMASK;  		gpio->par_uart |= (GPIO_PAR_UART_U1TXD | GPIO_PAR_UART_U1RXD);  		break;  	case 2:  #ifdef CONFIG_SYS_UART2_PRI_GPIO  		gpio->par_timer &= -		    (GPIO_PAR_TMR_TIN0_MASK | GPIO_PAR_TMR_TIN1_MASK); +		    (GPIO_PAR_TMR_TIN0_UNMASK | GPIO_PAR_TMR_TIN1_UNMASK);  		gpio->par_timer |=  		    (GPIO_PAR_TMR_TIN0_U2TXD | GPIO_PAR_TMR_TIN1_U2RXD);  #endif  #ifdef CONFIG_SYS_UART2_ALT1_GPIO  		gpio->par_feci2c &= -		    (GPIO_PAR_FECI2C_MDC_MASK | GPIO_PAR_FECI2C_MDIO_MASK); +		    (GPIO_PAR_FECI2C_MDC_UNMASK | GPIO_PAR_FECI2C_MDIO_UNMASK);  		gpio->par_feci2c |=  		    (GPIO_PAR_FECI2C_MDC_U2TXD | GPIO_PAR_FECI2C_MDIO_U2RXD);  #endif  #ifdef CONFIG_SYS_UART2_ALT1_GPIO  		gpio->par_feci2c &= -		    (GPIO_PAR_FECI2C_SDA_MASK | GPIO_PAR_FECI2C_SCL_MASK); +		    (GPIO_PAR_FECI2C_SDA_UNMASK | GPIO_PAR_FECI2C_SCL_UNMASK);  		gpio->par_feci2c |=  		    (GPIO_PAR_FECI2C_SDA_U2TXD | GPIO_PAR_FECI2C_SCL_U2RXD);  #endif @@ -184,8 +184,8 @@ int fecpin_setclear(struct eth_device *dev, int setclear)  		    GPIO_PAR_FECI2C_MDC_MDC | GPIO_PAR_FECI2C_MDIO_MDIO;  	} else {  		gpio->par_fec &= -		    (GPIO_PAR_FEC_7W_MASK & GPIO_PAR_FEC_MII_MASK); -		gpio->par_feci2c &= GPIO_PAR_FECI2C_RMII_MASK; +		    (GPIO_PAR_FEC_7W_UNMASK & GPIO_PAR_FEC_MII_UNMASK); +		gpio->par_feci2c &= GPIO_PAR_FECI2C_RMII_UNMASK;  	}  	return 0;  } diff --git a/cpu/mcf532x/cpu_init.c b/cpu/mcf532x/cpu_init.c index 4f1695cef..04160a829 100644 --- a/cpu/mcf532x/cpu_init.c +++ b/cpu/mcf532x/cpu_init.c @@ -145,12 +145,12 @@ void uart_port_conf(void)  	case 1:  #ifdef CONFIG_SYS_UART1_ALT1_GPIO  		gpio->par_simp1h &= -		    ~(GPIO_PAR_SIMP1H_DATA1_MASK | GPIO_PAR_SIMP1H_VEN1_MASK); +		    ~(GPIO_PAR_SIMP1H_DATA1_UNMASK | GPIO_PAR_SIMP1H_VEN1_UNMASK);  		gpio->par_simp1h |=  		    (GPIO_PAR_SIMP1H_DATA1_U1TXD | GPIO_PAR_SIMP1H_VEN1_U1RXD);  #elif defined(CONFIG_SYS_UART1_ALT2_GPIO)  		gpio->par_ssih &= -		    ~(GPIO_PAR_SSIH_RXD_MASK | GPIO_PAR_SSIH_TXD_MASK); +		    ~(GPIO_PAR_SSIH_RXD_UNMASK | GPIO_PAR_SSIH_TXD_UNMASK);  		gpio->par_ssih |=  		    (GPIO_PAR_SSIH_RXD_U1RXD | GPIO_PAR_SSIH_TXD_U1TXD);  #endif @@ -160,12 +160,12 @@ void uart_port_conf(void)  		gpio->par_uart |= (GPIO_PAR_UART_U2TXD | GPIO_PAR_UART_U2RXD);  #elif defined(CONFIG_SYS_UART2_ALT1_GPIO)  		gpio->par_dspih &= -		    ~(GPIO_PAR_DSPIH_SIN_MASK | GPIO_PAR_DSPIH_SOUT_MASK); +		    ~(GPIO_PAR_DSPIH_SIN_UNMASK | GPIO_PAR_DSPIH_SOUT_UNMASK);  		gpio->par_dspih |=  		    (GPIO_PAR_DSPIH_SIN_U2RXD | GPIO_PAR_DSPIH_SOUT_U2TXD);  #elif defined(CONFIG_SYS_UART2_ALT2_GPIO)  		gpio->par_feci2c &= -		    ~(GPIO_PAR_FECI2C_SDA_MASK | GPIO_PAR_FECI2C_SCL_MASK); +		    ~(GPIO_PAR_FECI2C_SDA_UNMASK | GPIO_PAR_FECI2C_SCL_UNMASK);  		gpio->par_feci2c |=  		    (GPIO_PAR_FECI2C_SDA_U2TXD | GPIO_PAR_FECI2C_SCL_U2RXD);  #endif @@ -195,11 +195,11 @@ int fecpin_setclear(struct eth_device *dev, int setclear)  		if (info->iobase == CONFIG_SYS_FEC0_IOBASE) {  			gpio->par_fec &=  			    ~(GPIO_PAR_FEC0_7W_FEC | GPIO_PAR_FEC0_RMII_FEC); -			gpio->par_feci2c &= GPIO_PAR_FECI2C_RMII0_MASK; +			gpio->par_feci2c &= GPIO_PAR_FECI2C_RMII0_UNMASK;  		} else {  			gpio->par_fec &=  			    ~(GPIO_PAR_FEC1_7W_FEC | GPIO_PAR_FEC1_RMII_FEC); -			gpio->par_feci2c &= GPIO_PAR_FECI2C_RMII1_MASK; +			gpio->par_feci2c &= GPIO_PAR_FECI2C_RMII1_UNMASK;  		}  	}  	return 0; diff --git a/cpu/mcf532x/speed.c b/cpu/mcf532x/speed.c index 67f08c760..5a29e2567 100644 --- a/cpu/mcf532x/speed.c +++ b/cpu/mcf532x/speed.c @@ -229,7 +229,7 @@ int clock_pll(int fsys, int flags)  	    PLL_PDR_OUTDIV3((BUSDIV / 2) - 1)	|  	    PLL_PDR_OUTDIV4(USBDIV - 1); -	pll->pcr &= PLL_PCR_FBDIV_MASK; +	pll->pcr &= PLL_PCR_FBDIV_UNMASK;  	pll->pcr |= PLL_PCR_FBDIV(mfd - 1);  #endif  #ifdef CONFIG_MCF532x diff --git a/cpu/mcf5445x/cpu_init.c b/cpu/mcf5445x/cpu_init.c index 48b37dfe7..00b7910cc 100644 --- a/cpu/mcf5445x/cpu_init.c +++ b/cpu/mcf5445x/cpu_init.c @@ -164,9 +164,9 @@ int fecpin_setclear(struct eth_device *dev, int setclear)  		    ~(GPIO_PAR_FECI2C_MDC0_MDC0 | GPIO_PAR_FECI2C_MDIO0_MDIO0);  		if (info->iobase == CONFIG_SYS_FEC0_IOBASE) -			gpio->par_fec &= GPIO_PAR_FEC_FEC0_MASK; +			gpio->par_fec &= GPIO_PAR_FEC_FEC0_UNMASK;  		else -			gpio->par_fec &= GPIO_PAR_FEC_FEC1_MASK; +			gpio->par_fec &= GPIO_PAR_FEC_FEC1_UNMASK;  	}  	return 0;  } diff --git a/include/asm-m68k/m520x.h b/include/asm-m68k/m520x.h index 267bfd994..71f147e75 100644 --- a/include/asm-m68k/m520x.h +++ b/include/asm-m68k/m520x.h @@ -70,7 +70,6 @@  #define PACR_TP	1  #define SCM_BMT_BME			(0x00000008) -#define SCM_BMT_BMT_MASK		(0x07)  #define SCM_BMT_BMT(x)			((x) & 0x07)  #define SCM_BMT_BMT1024			(0x0000)  #define SCM_BMT_BMT512			(0x0001) @@ -179,7 +178,7 @@  #define CCM_CCR_PLL_MODE		(0x0002)  #define CCM_CCR_RESERVED		(0x0001) -#define CCM_CIR_PIN(x)			(((x) & 0x03FF) << 6) +#define CCM_CIR_PIN(x)			(((x) & 0xFFC0) >> 6)  #define CCM_CIR_PRN(x)			((x) & 0x003F)  /* *** General Purpose I/O (GPIO) *** */ @@ -196,7 +195,7 @@  #define GPIO_PAR_FBCTL_OE		(0x10)  #define GPIO_PAR_FBCTL_TA		(0x08)  #define GPIO_PAR_FBCTL_RWB		(0x04) -#define GPIO_PAR_FBCTL_TS_MASK		(0xFC) +#define GPIO_PAR_FBCTL_TS_UNMASK	(0xFC)  #define GPIO_PAR_FBCTL_TS_TS		(0x03)  #define GPIO_PAR_FBCTL_TS_DMA		(0x02) @@ -207,39 +206,39 @@  #define GPIO_PAR_CS3			(0x08)  #define GPIO_PAR_CS2			(0x04) -#define GPIO_PAR_CS1_MASK		(0xFC) +#define GPIO_PAR_CS1_UNMASK		(0xFC)  #define GPIO_PAR_CS1_CS1		(0x03)  #define GPIO_PAR_CS1_SDCS1		(0x02) -#define GPIO_PAR_FECI2C_RMII_MASK	(0x0F) -#define GPIO_PAR_FECI2C_MDC_MASK	(0x3F) +#define GPIO_PAR_FECI2C_RMII_UNMASK	(0x0F) +#define GPIO_PAR_FECI2C_MDC_UNMASK	(0x3F)  #define GPIO_PAR_FECI2C_MDC_MDC		(0xC0)  #define GPIO_PAR_FECI2C_MDC_SCL		(0x80)  #define GPIO_PAR_FECI2C_MDC_U2TXD	(0x40) -#define GPIO_PAR_FECI2C_MDIO_MASK	(0xCF) +#define GPIO_PAR_FECI2C_MDIO_UNMASK	(0xCF)  #define GPIO_PAR_FECI2C_MDIO_MDIO	(0x30)  #define GPIO_PAR_FECI2C_MDIO_SDA	(0x20)  #define GPIO_PAR_FECI2C_MDIO_U2RXD	(0x10) -#define GPIO_PAR_FECI2C_I2C_MASK	(0xF0) -#define GPIO_PAR_FECI2C_SCL_MASK	(0xF3) +#define GPIO_PAR_FECI2C_I2C_UNMASK	(0xF0) +#define GPIO_PAR_FECI2C_SCL_UNMASK	(0xF3)  #define GPIO_PAR_FECI2C_SCL_SCL		(0x0C)  #define GPIO_PAR_FECI2C_SCL_U2RXD	(0x04) -#define GPIO_PAR_FECI2C_SDA_MASK	(0xFC) +#define GPIO_PAR_FECI2C_SDA_UNMASK	(0xFC)  #define GPIO_PAR_FECI2C_SDA_SDA		(0x03)  #define GPIO_PAR_FECI2C_SDA_U2TXD	(0x01) -#define GPIO_PAR_QSPI_PCS2_MASK		(0x3F) +#define GPIO_PAR_QSPI_PCS2_UNMASK	(0x3F)  #define GPIO_PAR_QSPI_PCS2_PCS2		(0xC0)  #define GPIO_PAR_QSPI_PCS2_DACK0	(0x80)  #define GPIO_PAR_QSPI_PCS2_U2RTS	(0x40) -#define GPIO_PAR_QSPI_DIN_MASK		(0xCF) +#define GPIO_PAR_QSPI_DIN_UNMASK	(0xCF)  #define GPIO_PAR_QSPI_DIN_DIN		(0x30)  #define GPIO_PAR_QSPI_DIN_DREQ0		(0x20)  #define GPIO_PAR_QSPI_DIN_U2CTS		(0x10) -#define GPIO_PAR_QSPI_DOUT_MASK		(0xF3) +#define GPIO_PAR_QSPI_DOUT_UNMASK	(0xF3)  #define GPIO_PAR_QSPI_DOUT_DOUT		(0x0C)  #define GPIO_PAR_QSPI_DOUT_SDA		(0x08) -#define GPIO_PAR_QSPI_SCK_MASK		(0xFC) +#define GPIO_PAR_QSPI_SCK_UNMASK	(0xFC)  #define GPIO_PAR_QSPI_SCK_SCK		(0x03)  #define GPIO_PAR_QSPI_SCK_SCL		(0x02) @@ -247,50 +246,50 @@  #define GPIO_PAR_TMR_TIN2(x)		(((x) & 0x03) << 4)  #define GPIO_PAR_TMR_TIN1(x)		(((x) & 0x03) << 2)  #define GPIO_PAR_TMR_TIN0(x)		((x) & 0x03) -#define GPIO_PAR_TMR_TIN3_MASK		(0x3F) +#define GPIO_PAR_TMR_TIN3_UNMASK	(0x3F)  #define GPIO_PAR_TMR_TIN3_TIN3		(0xC0)  #define GPIO_PAR_TMR_TIN3_TOUT3		(0x80)  #define GPIO_PAR_TMR_TIN3_U2CTS		(0x40) -#define GPIO_PAR_TMR_TIN2_MASK		(0xCF) +#define GPIO_PAR_TMR_TIN2_UNMASK	(0xCF)  #define GPIO_PAR_TMR_TIN2_TIN2		(0x30)  #define GPIO_PAR_TMR_TIN2_TOUT2		(0x20)  #define GPIO_PAR_TMR_TIN2_U2RTS		(0x10) -#define GPIO_PAR_TMR_TIN1_MASK		(0xF3) +#define GPIO_PAR_TMR_TIN1_UNMASK	(0xF3)  #define GPIO_PAR_TMR_TIN1_TIN1		(0x0C)  #define GPIO_PAR_TMR_TIN1_TOUT1		(0x08)  #define GPIO_PAR_TMR_TIN1_U2RXD		(0x04) -#define GPIO_PAR_TMR_TIN0_MASK		(0xFC) +#define GPIO_PAR_TMR_TIN0_UNMASK	(0xFC)  #define GPIO_PAR_TMR_TIN0_TIN0		(0x03)  #define GPIO_PAR_TMR_TIN0_TOUT0		(0x02)  #define GPIO_PAR_TMR_TIN0_U2TXD		(0x01) -#define GPIO_PAR_UART1_MASK		(0xF03F) -#define GPIO_PAR_UART0_MASK		(0xFFC0) -#define GPIO_PAR_UART_U1CTS_MASK	(0xF3FF) +#define GPIO_PAR_UART1_UNMASK		(0xF03F) +#define GPIO_PAR_UART0_UNMASK		(0xFFC0) +#define GPIO_PAR_UART_U1CTS_UNMASK	(0xF3FF)  #define GPIO_PAR_UART_U1CTS_U1CTS	(0x0C00)  #define GPIO_PAR_UART_U1CTS_TIN1	(0x0800)  #define GPIO_PAR_UART_U1CTS_PCS1	(0x0400) -#define GPIO_PAR_UART_U1RTS_MASK	(0xFCFF) +#define GPIO_PAR_UART_U1RTS_UNMASK	(0xFCFF)  #define GPIO_PAR_UART_U1RTS_U1RTS	(0x0300)  #define GPIO_PAR_UART_U1RTS_TOUT1	(0x0200)  #define GPIO_PAR_UART_U1RTS_PCS1	(0x0100)  #define GPIO_PAR_UART_U1TXD		(0x0080)  #define GPIO_PAR_UART_U1RXD		(0x0040) -#define GPIO_PAR_UART_U0CTS_MASK	(0xFFCF) +#define GPIO_PAR_UART_U0CTS_UNMASK	(0xFFCF)  #define GPIO_PAR_UART_U0CTS_U0CTS	(0x0030)  #define GPIO_PAR_UART_U0CTS_TIN0	(0x0020)  #define GPIO_PAR_UART_U0CTS_PCS0	(0x0010) -#define GPIO_PAR_UART_U0RTS_MASK	(0xFFF3) +#define GPIO_PAR_UART_U0RTS_UNMASK	(0xFFF3)  #define GPIO_PAR_UART_U0RTS_U0RTS	(0x000C)  #define GPIO_PAR_UART_U0RTS_TOUT0	(0x0008)  #define GPIO_PAR_UART_U0RTS_PCS0	(0x0004)  #define GPIO_PAR_UART_U0TXD		(0x0002)  #define GPIO_PAR_UART_U0RXD		(0x0001) -#define GPIO_PAR_FEC_7W_MASK		(0xF3) +#define GPIO_PAR_FEC_7W_UNMASK		(0xF3)  #define GPIO_PAR_FEC_7W_FEC		(0x0C)  #define GPIO_PAR_FEC_7W_U1RTS		(0x04) -#define GPIO_PAR_FEC_MII_MASK		(0xFC) +#define GPIO_PAR_FEC_MII_UNMASK		(0xFC)  #define GPIO_PAR_FEC_MII_FEC		(0x03)  #define GPIO_PAR_FEC_MII_UnCTS		(0x01) @@ -300,17 +299,17 @@  #define GPIO_MSCR_FB_DUP(x)		(((x) & 0x03) << 4)  #define GPIO_MSCR_FB_DLO(x)		(((x) & 0x03) << 2)  #define GPIO_MSCR_FB_ADRCTL(x)		((x) & 0x03) -#define GPIO_MSCR_FB_FBCLK_MASK		(0x3F) -#define GPIO_MSCR_FB_DUP_MASK		(0xCF) -#define GPIO_MSCR_FB_DLO_MASK		(0xF3) -#define GPIO_MSCR_FB_ADRCTL_MASK	(0xFC) +#define GPIO_MSCR_FB_FBCLK_UNMASK	(0x3F) +#define GPIO_MSCR_FB_DUP_UNMASK		(0xCF) +#define GPIO_MSCR_FB_DLO_UNMASK		(0xF3) +#define GPIO_MSCR_FB_ADRCTL_UNMASK	(0xFC)  #define GPIO_MSCR_SDR_SDCLKB(x)		(((x) & 0x03) << 4)  #define GPIO_MSCR_SDR_SDCLK(x)		(((x) & 0x03) << 2)  #define GPIO_MSCR_SDR_SDRAM(x)		((x) & 0x03) -#define GPIO_MSCR_SDR_SDCLKB_MASK	(0xCF) -#define GPIO_MSCR_SDR_SDCLK_MASK	(0xF3) -#define GPIO_MSCR_SDR_SDRAM_MASK	(0xFC) +#define GPIO_MSCR_SDR_SDCLKB_UNMASK	(0xCF) +#define GPIO_MSCR_SDR_SDCLK_UNMASK	(0xF3) +#define GPIO_MSCR_SDR_SDRAM_UNMASK	(0xFC)  #define MSCR_25VDDR			(0x03)  #define MSCR_18VDDR_FULL		(0x02) @@ -318,27 +317,27 @@  #define MSCR_18VDDR_HALF		(0x00)  #define GPIO_DSCR_I2C(x)		((x) & 0x03) -#define GPIO_DSCR_I2C_MASK		(0xFC) +#define GPIO_DSCR_I2C_UNMASK		(0xFC)  #define GPIO_DSCR_MISC_DBG(x)		(((x) & 0x03) << 4) -#define GPIO_DSCR_MISC_DBG_MASK		(0xCF) +#define GPIO_DSCR_MISC_DBG_UNMASK	(0xCF)  #define GPIO_DSCR_MISC_RSTOUT(x)	(((x) & 0x03) << 2) -#define GPIO_DSCR_MISC_RSTOUT_MASK	(0xF3) +#define GPIO_DSCR_MISC_RSTOUT_UNMASK	(0xF3)  #define GPIO_DSCR_MISC_TIMER(x)		((x) & 0x03) -#define GPIO_DSCR_MISC_TIMER_MASK	(0xFC) +#define GPIO_DSCR_MISC_TIMER_UNMASK	(0xFC)  #define GPIO_DSCR_FEC(x)		((x) & 0x03) -#define GPIO_DSCR_FEC_MASK		(0xFC) +#define GPIO_DSCR_FEC_UNMASK		(0xFC)  #define GPIO_DSCR_UART_UART1(x)		(((x) & 0x03) << 4) -#define GPIO_DSCR_UART_UART1_MASK	(0xCF) +#define GPIO_DSCR_UART_UART1_UNMASK	(0xCF)  #define GPIO_DSCR_UART_UART0(x)		(((x) & 0x03) << 2) -#define GPIO_DSCR_UART_UART0_MASK	(0xF3) +#define GPIO_DSCR_UART_UART0_UNMASK	(0xF3)  #define GPIO_DSCR_UART_IRQ(x)		((x) & 0x03) -#define GPIO_DSCR_UART_IRQ_MASK		(0xFC) +#define GPIO_DSCR_UART_IRQ_UNMASK	(0xFC)  #define GPIO_DSCR_QSPI(x)		((x) & 0x03) -#define GPIO_DSCR_QSPI_MASK		(0xFC) +#define GPIO_DSCR_QSPI_UNMASK		(0xFC)  #define DSCR_50PF			(0x03)  #define DSCR_30PF			(0x02) @@ -347,12 +346,12 @@  /* *** Phase Locked Loop (PLL) *** */  #define PLL_PODR_CPUDIV(x)		(((x) & 0x0F) << 4) -#define PLL_PODR_CPUDIV_MASK		(0x0F) +#define PLL_PODR_CPUDIV_UNMASK		(0x0F)  #define PLL_PODR_BUSDIV(x)		((x) & 0x0F) -#define PLL_PODR_BUSDIV_MASK		(0xF0) +#define PLL_PODR_BUSDIV_UNMASK		(0xF0)  #define PLL_PCR_DITHEN			(0x80)  #define PLL_PCR_DITHDEV(x)		((x) & 0x07) -#define PLL_PCR_DITHDEV_MASK		(0xF8) +#define PLL_PCR_DITHDEV_UNMASK		(0xF8)  #endif				/* __M520X__ */ diff --git a/include/asm-m68k/m5227x.h b/include/asm-m68k/m5227x.h index 824d33311..c77d5dd65 100644 --- a/include/asm-m68k/m5227x.h +++ b/include/asm-m68k/m5227x.h @@ -117,36 +117,34 @@  /* Bit definitions and macros for CCR */  #define CCM_CCR_DRAMSEL			(0x0100) -#define CCM_CCR_CSC_MASK		(0xFF3F) +#define CCM_CCR_CSC_UNMASK		(0xFF3F)  #define CCM_CCR_CSC_FBCS5_CS4		(0x00C0)  #define CCM_CCR_CSC_FBCS5_A22		(0x0080)  #define CCM_CCR_CSC_FB_A23_A22		(0x0040)  #define CCM_CCR_LIMP			(0x0020)  #define CCM_CCR_LOAD			(0x0010) -#define CCM_CCR_BOOTPS_MASK		(0xFFF3) +#define CCM_CCR_BOOTPS_UNMASK		(0xFFF3)  #define CCM_CCR_BOOTPS_PS16		(0x0008)  #define CCM_CCR_BOOTPS_PS8		(0x0004)  #define CCM_CCR_BOOTPS_PS32		(0x0000)  #define CCM_CCR_OSCMODE_OSCBYPASS	(0x0002)  /* Bit definitions and macros for RCON */ -#define CCM_RCON_CSC_MASK		(0xFF3F) +#define CCM_RCON_CSC_UNMASK		(0xFF3F)  #define CCM_RCON_CSC_FBCS5_CS4		(0x00C0)  #define CCM_RCON_CSC_FBCS5_A22		(0x0080)  #define CCM_RCON_CSC_FB_A23_A22		(0x0040)  #define CCM_RCON_LIMP			(0x0020)  #define CCM_RCON_LOAD			(0x0010) -#define CCM_RCON_BOOTPS_MASK		(0xFFF3) +#define CCM_RCON_BOOTPS_UNMASK		(0xFFF3)  #define CCM_RCON_BOOTPS_PS16		(0x0008)  #define CCM_RCON_BOOTPS_PS8		(0x0004)  #define CCM_RCON_BOOTPS_PS32		(0x0000)  #define CCM_RCON_OSCMODE_OSCBYPASS	(0x0002)  /* Bit definitions and macros for CIR */ -#define CCM_CIR_PRN(x)			(((x)&0x003F))	/* Part revision number */ -#define CCM_CIR_PIN(x)			(((x)&0x03FF)<<6)	/* Part identification number */ -#define CCM_CIR_PIN_MASK		(0xFFC0) -#define CCM_CIR_PRN_MASK		(0x003F) +#define CCM_CIR_PIN(x)			(((x) & 0xFFC0) >> 6) +#define CCM_CIR_PRN(x)			((x) & 0x003F)  #define CCM_CIR_PIN_MCF52277		(0x0000)  /* Bit definitions and macros for MISCCR */ @@ -195,7 +193,7 @@  * General Purpose I/O Module (GPIO)  *********************************************************************/  /* Bit definitions and macros for PAR_BE */ -#define GPIO_PAR_BE_MASK		(0x0F) +#define GPIO_PAR_BE_UNMASK		(0x0F)  #define GPIO_PAR_BE_BE3_BE3		(0x08)  #define GPIO_PAR_BE_BE3_GPIO		(0x00)  #define GPIO_PAR_BE_BE2_BE2		(0x04) @@ -217,111 +215,111 @@  #define GPIO_PAR_FBCTL_OE		(0x80)  #define GPIO_PAR_FBCTL_TA		(0x40)  #define GPIO_PAR_FBCTL_RW		(0x20) -#define GPIO_PAR_FBCTL_TS_MASK		(0xE7) +#define GPIO_PAR_FBCTL_TS_UNMASK	(0xE7)  #define GPIO_PAR_FBCTL_TS_FBTS		(0x18)  #define GPIO_PAR_FBCTL_TS_DMAACK	(0x10)  #define GPIO_PAR_FBCTL_TS_GPIO		(0x00)  /* Bit definitions and macros for PAR_FECI2C */ -#define GPIO_PAR_I2C_SCL_MASK		(0xF3) +#define GPIO_PAR_I2C_SCL_UNMASK		(0xF3)  #define GPIO_PAR_I2C_SCL_SCL		(0x0C)  #define GPIO_PAR_I2C_SCL_CANTXD		(0x08)  #define GPIO_PAR_I2C_SCL_U2TXD		(0x04)  #define GPIO_PAR_I2C_SCL_GPIO		(0x00) -#define GPIO_PAR_I2C_SDA_MASK		(0xFC) +#define GPIO_PAR_I2C_SDA_UNMASK		(0xFC)  #define GPIO_PAR_I2C_SDA_SDA		(0x03)  #define GPIO_PAR_I2C_SDA_CANRXD		(0x02)  #define GPIO_PAR_I2C_SDA_U2RXD		(0x01)  #define GPIO_PAR_I2C_SDA_GPIO		(0x00)  /* Bit definitions and macros for PAR_UART */ -#define GPIO_PAR_UART_U1CTS_MASK	(0x3FFF) +#define GPIO_PAR_UART_U1CTS_UNMASK	(0x3FFF)  #define GPIO_PAR_UART_U1CTS_U1CTS	(0xC000)  #define GPIO_PAR_UART_U1CTS_SSIBCLK	(0x8000)  #define GPIO_PAR_UART_U1CTS_LCDCLS	(0x4000)  #define GPIO_PAR_UART_U1CTS_GPIO	(0x0000) -#define GPIO_PAR_UART_U1RTS_MASK	(0xCFFF) +#define GPIO_PAR_UART_U1RTS_UNMASK	(0xCFFF)  #define GPIO_PAR_UART_U1RTS_U1RTS	(0x3000)  #define GPIO_PAR_UART_U1RTS_SSIFS	(0x2000)  #define GPIO_PAR_UART_U1RTS_LCDPS	(0x1000)  #define GPIO_PAR_UART_U1RTS_GPIO	(0x0000) -#define GPIO_PAR_UART_U1RXD_MASK	(0xF3FF) +#define GPIO_PAR_UART_U1RXD_UNMASK	(0xF3FF)  #define GPIO_PAR_UART_U1RXD_U1RXD	(0x0C00)  #define GPIO_PAR_UART_U1RXD_SSIRXD	(0x0800)  #define GPIO_PAR_UART_U1RXD_GPIO	(0x0000) -#define GPIO_PAR_UART_U1TXD_MASK	(0xFCFF) +#define GPIO_PAR_UART_U1TXD_UNMASK	(0xFCFF)  #define GPIO_PAR_UART_U1TXD_U1TXD	(0x0300)  #define GPIO_PAR_UART_U1TXD_SSITXD	(0x0200)  #define GPIO_PAR_UART_U1TXD_GPIO	(0x0000) -#define GPIO_PAR_UART_U0CTS_MASK	(0xFF3F) +#define GPIO_PAR_UART_U0CTS_UNMASK	(0xFF3F)  #define GPIO_PAR_UART_U0CTS_U0CTS	(0x00C0)  #define GPIO_PAR_UART_U0CTS_T1OUT	(0x0080)  #define GPIO_PAR_UART_U0CTS_USBVBUSEN	(0x0040)  #define GPIO_PAR_UART_U0CTS_GPIO	(0x0000) -#define GPIO_PAR_UART_U0RTS_MASK	(0xFFCF) +#define GPIO_PAR_UART_U0RTS_UNMASK	(0xFFCF)  #define GPIO_PAR_UART_U0RTS_U0RTS	(0x0030)  #define GPIO_PAR_UART_U0RTS_T1IN	(0x0020)  #define GPIO_PAR_UART_U0RTS_USBVBUSOC	(0x0010)  #define GPIO_PAR_UART_U0RTS_GPIO	(0x0000) -#define GPIO_PAR_UART_U0RXD_MASK	(0xFFF3) +#define GPIO_PAR_UART_U0RXD_UNMASK	(0xFFF3)  #define GPIO_PAR_UART_U0RXD_U0RXD	(0x000C)  #define GPIO_PAR_UART_U0RXD_CANRX	(0x0008)  #define GPIO_PAR_UART_U0RXD_GPIO	(0x0000) -#define GPIO_PAR_UART_U0TXD_MASK	(0xFFFC) +#define GPIO_PAR_UART_U0TXD_UNMASK	(0xFFFC)  #define GPIO_PAR_UART_U0TXD_U0TXD	(0x0003)  #define GPIO_PAR_UART_U0TXD_CANTX	(0x0002)  #define GPIO_PAR_UART_U0TXD_GPIO	(0x0000)  /* Bit definitions and macros for PAR_DSPI */ -#define GPIO_PAR_DSPI_PCS0_MASK		(0x3F) +#define GPIO_PAR_DSPI_PCS0_UNMASK	(0x3F)  #define GPIO_PAR_DSPI_PCS0_PCS0		(0xC0)  #define GPIO_PAR_DSPI_PCS0_U2RTS	(0x80)  #define GPIO_PAR_DSPI_PCS0_GPIO		(0x00) -#define GPIO_PAR_DSPI_SIN_MASK		(0xCF) +#define GPIO_PAR_DSPI_SIN_UNMASK	(0xCF)  #define GPIO_PAR_DSPI_SIN_SIN		(0x30)  #define GPIO_PAR_DSPI_SIN_U2RXD		(0x20)  #define GPIO_PAR_DSPI_SIN_GPIO		(0x00) -#define GPIO_PAR_DSPI_SOUT_MASK		(0xF3) +#define GPIO_PAR_DSPI_SOUT_UNMASK	(0xF3)  #define GPIO_PAR_DSPI_SOUT_SOUT		(0x0C)  #define GPIO_PAR_DSPI_SOUT_U2TXD	(0x08)  #define GPIO_PAR_DSPI_SOUT_GPIO		(0x00) -#define GPIO_PAR_DSPI_SCK_MASK		(0xFC) +#define GPIO_PAR_DSPI_SCK_UNMASK	(0xFC)  #define GPIO_PAR_DSPI_SCK_SCK		(0x03)  #define GPIO_PAR_DSPI_SCK_U2CTS		(0x02)  #define GPIO_PAR_DSPI_SCK_GPIO		(0x00)  /* Bit definitions and macros for PAR_TIMER */ -#define GPIO_PAR_TIMER_T3IN_MASK	(0x3F) +#define GPIO_PAR_TIMER_T3IN_UNMASK	(0x3F)  #define GPIO_PAR_TIMER_T3IN_T3IN	(0xC0)  #define GPIO_PAR_TIMER_T3IN_T3OUT	(0x80)  #define GPIO_PAR_TIMER_T3IN_SSIMCLK	(0x40)  #define GPIO_PAR_TIMER_T3IN_GPIO	(0x00) -#define GPIO_PAR_TIMER_T2IN_MASK	(0xCF) +#define GPIO_PAR_TIMER_T2IN_UNMASK	(0xCF)  #define GPIO_PAR_TIMER_T2IN_T2IN	(0x30)  #define GPIO_PAR_TIMER_T2IN_T2OUT	(0x20)  #define GPIO_PAR_TIMER_T2IN_DSPIPCS2	(0x10)  #define GPIO_PAR_TIMER_T2IN_GPIO	(0x00) -#define GPIO_PAR_TIMER_T1IN_MASK	(0xF3) +#define GPIO_PAR_TIMER_T1IN_UNMASK	(0xF3)  #define GPIO_PAR_TIMER_T1IN_T1IN	(0x0C)  #define GPIO_PAR_TIMER_T1IN_T1OUT	(0x08)  #define GPIO_PAR_TIMER_T1IN_LCDCONTRAST	(0x04)  #define GPIO_PAR_TIMER_T1IN_GPIO	(0x00) -#define GPIO_PAR_TIMER_T0IN_MASK	(0xFC) +#define GPIO_PAR_TIMER_T0IN_UNMASK	(0xFC)  #define GPIO_PAR_TIMER_T0IN_T0IN	(0x03)  #define GPIO_PAR_TIMER_T0IN_T0OUT	(0x02)  #define GPIO_PAR_TIMER_T0IN_LCDREV	(0x01)  #define GPIO_PAR_TIMER_T0IN_GPIO	(0x00)  /* Bit definitions and macros for GPIO_PAR_LCDCTL */ -#define GPIO_PAR_LCDCTL_ACDOE_MASK	(0xE7) +#define GPIO_PAR_LCDCTL_ACDOE_UNMASK	(0xE7)  #define GPIO_PAR_LCDCTL_ACDOE_ACDOE	(0x18)  #define GPIO_PAR_LCDCTL_ACDOE_SPLSPR	(0x10)  #define GPIO_PAR_LCDCTL_ACDOE_GPIO	(0x00) @@ -330,141 +328,141 @@  #define GPIO_PAR_LCDCTL_LSCLK		(0x01)  /* Bit definitions and macros for PAR_IRQ */ -#define GPIO_PAR_IRQ_IRQ4_MASK		(0xF3) +#define GPIO_PAR_IRQ_IRQ4_UNMASK	(0xF3)  #define GPIO_PAR_IRQ_IRQ4_SSIINPCLK	(0x0C)  #define GPIO_PAR_IRQ_IRQ4_DMAREQ0	(0x08)  #define GPIO_PAR_IRQ_IRQ4_GPIO		(0x00) -#define GPIO_PAR_IRQ_IRQ1_MASK		(0xFC) +#define GPIO_PAR_IRQ_IRQ1_UNMASK	(0xFC)  #define GPIO_PAR_IRQ_IRQ1_PCIINT	(0x03)  #define GPIO_PAR_IRQ_IRQ1_USBCLKIN	(0x02)  #define GPIO_PAR_IRQ_IRQ1_SSICLKIN	(0x01)  #define GPIO_PAR_IRQ_IRQ1_GPIO		(0x00)  /* Bit definitions and macros for GPIO_PAR_LCDH */ -#define GPIO_PAR_LCDH_LD17_MASK		(0xFFFFF3FF) +#define GPIO_PAR_LCDH_LD17_UNMASK	(0xFFFFF3FF)  #define GPIO_PAR_LCDH_LD17_LD17		(0x00000C00)  #define GPIO_PAR_LCDH_LD17_LD11		(0x00000800)  #define GPIO_PAR_LCDH_LD17_GPIO		(0x00000000) -#define GPIO_PAR_LCDH_LD16_MASK		(0xFFFFFCFF) +#define GPIO_PAR_LCDH_LD16_UNMASK	(0xFFFFFCFF)  #define GPIO_PAR_LCDH_LD16_LD16		(0x00000300)  #define GPIO_PAR_LCDH_LD16_LD10		(0x00000200)  #define GPIO_PAR_LCDH_LD16_GPIO		(0x00000000) -#define GPIO_PAR_LCDH_LD15_MASK		(0xFFFFFF3F) +#define GPIO_PAR_LCDH_LD15_UNMASK	(0xFFFFFF3F)  #define GPIO_PAR_LCDH_LD15_LD15		(0x000000C0)  #define GPIO_PAR_LCDH_LD15_LD9		(0x00000080)  #define GPIO_PAR_LCDH_LD15_GPIO		(0x00000000) -#define GPIO_PAR_LCDH_LD14_MASK		(0xFFFFFFCF) +#define GPIO_PAR_LCDH_LD14_UNMASK	(0xFFFFFFCF)  #define GPIO_PAR_LCDH_LD14_LD14		(0x00000030)  #define GPIO_PAR_LCDH_LD14_LD8		(0x00000020)  #define GPIO_PAR_LCDH_LD14_GPIO		(0x00000000) -#define GPIO_PAR_LCDH_LD13_MASK		(0xFFFFFFF3) +#define GPIO_PAR_LCDH_LD13_UNMASK	(0xFFFFFFF3)  #define GPIO_PAR_LCDH_LD13_LD13		(0x0000000C)  #define GPIO_PAR_LCDH_LD13_CANTX	(0x00000008)  #define GPIO_PAR_LCDH_LD13_GPIO		(0x00000000) -#define GPIO_PAR_LCDH_LD12_MASK		(0xFFFFFFFC) +#define GPIO_PAR_LCDH_LD12_UNMASK	(0xFFFFFFFC)  #define GPIO_PAR_LCDH_LD12_LD12		(0x00000003)  #define GPIO_PAR_LCDH_LD12_CANRX	(0x00000002)  #define GPIO_PAR_LCDH_LD12_GPIO		(0x00000000)  /* Bit definitions and macros for GPIO_PAR_LCDL */ -#define GPIO_PAR_LCDL_LD11_MASK		(0x3FFFFFFF) +#define GPIO_PAR_LCDL_LD11_UNMASK	(0x3FFFFFFF)  #define GPIO_PAR_LCDL_LD11_LD11		(0xC0000000)  #define GPIO_PAR_LCDL_LD11_LD7		(0x80000000)  #define GPIO_PAR_LCDL_LD11_GPIO		(0x00000000) -#define GPIO_PAR_LCDL_LD10_MASK		(0xCFFFFFFF) +#define GPIO_PAR_LCDL_LD10_UNMASK	(0xCFFFFFFF)  #define GPIO_PAR_LCDL_LD10_LD10		(0x30000000)  #define GPIO_PAR_LCDL_LD10_LD6		(0x20000000)  #define GPIO_PAR_LCDL_LD10_GPIO		(0x00000000) -#define GPIO_PAR_LCDL_LD9_MASK		(0xF3FFFFFF) +#define GPIO_PAR_LCDL_LD9_UNMASK	(0xF3FFFFFF)  #define GPIO_PAR_LCDL_LD9_LD9		(0x0C000000)  #define GPIO_PAR_LCDL_LD9_LD5		(0x08000000)  #define GPIO_PAR_LCDL_LD9_GPIO		(0x00000000) -#define GPIO_PAR_LCDL_LD8_MASK		(0xFCFFFFFF) +#define GPIO_PAR_LCDL_LD8_UNMASK	(0xFCFFFFFF)  #define GPIO_PAR_LCDL_LD8_LD8		(0x03000000)  #define GPIO_PAR_LCDL_LD8_LD4		(0x02000000)  #define GPIO_PAR_LCDL_LD8_GPIO		(0x00000000) -#define GPIO_PAR_LCDL_LD7_MASK		(0xFF3FFFFF) +#define GPIO_PAR_LCDL_LD7_UNMASK	(0xFF3FFFFF)  #define GPIO_PAR_LCDL_LD7_LD7		(0x00C00000)  #define GPIO_PAR_LCDL_LD7_PWM7		(0x00800000)  #define GPIO_PAR_LCDL_LD7_GPIO		(0x00000000) -#define GPIO_PAR_LCDL_LD6_MASK		(0xFFCFFFFF) +#define GPIO_PAR_LCDL_LD6_UNMASK	(0xFFCFFFFF)  #define GPIO_PAR_LCDL_LD6_LD6		(0x00300000)  #define GPIO_PAR_LCDL_LD6_PWM5		(0x00200000)  #define GPIO_PAR_LCDL_LD6_GPIO		(0x00000000) -#define GPIO_PAR_LCDL_LD5_MASK		(0xFFF3FFFF) +#define GPIO_PAR_LCDL_LD5_UNMASK	(0xFFF3FFFF)  #define GPIO_PAR_LCDL_LD5_LD5		(0x000C0000)  #define GPIO_PAR_LCDL_LD5_LD3		(0x00080000)  #define GPIO_PAR_LCDL_LD5_GPIO		(0x00000000) -#define GPIO_PAR_LCDL_LD4_MASK		(0xFFFCFFFF) +#define GPIO_PAR_LCDL_LD4_UNMASK	(0xFFFCFFFF)  #define GPIO_PAR_LCDL_LD4_LD4		(0x00030000)  #define GPIO_PAR_LCDL_LD4_LD2		(0x00020000)  #define GPIO_PAR_LCDL_LD4_GPIO		(0x00000000) -#define GPIO_PAR_LCDL_LD3_MASK		(0xFFFF3FFF) +#define GPIO_PAR_LCDL_LD3_UNMASK	(0xFFFF3FFF)  #define GPIO_PAR_LCDL_LD3_LD3		(0x0000C000)  #define GPIO_PAR_LCDL_LD3_LD1		(0x00008000)  #define GPIO_PAR_LCDL_LD3_GPIO		(0x00000000) -#define GPIO_PAR_LCDL_LD2_MASK		(0xFFFFCFFF) +#define GPIO_PAR_LCDL_LD2_UNMASK	(0xFFFFCFFF)  #define GPIO_PAR_LCDL_LD2_LD2		(0x00003000)  #define GPIO_PAR_LCDL_LD2_LD0		(0x00002000)  #define GPIO_PAR_LCDL_LD2_GPIO		(0x00000000) -#define GPIO_PAR_LCDL_LD1_MASK		(0xFFFFF3FF) +#define GPIO_PAR_LCDL_LD1_UNMASK	(0xFFFFF3FF)  #define GPIO_PAR_LCDL_LD1_LD1		(0x00000C00)  #define GPIO_PAR_LCDL_LD1_PWM3		(0x00000800)  #define GPIO_PAR_LCDL_LD1_GPIO		(0x00000000) -#define GPIO_PAR_LCDL_LD0_MASK		(0xFFFFFCFF) +#define GPIO_PAR_LCDL_LD0_UNMASK	(0xFFFFFCFF)  #define GPIO_PAR_LCDL_LD0_LD0		(0x00000300)  #define GPIO_PAR_LCDL_LD0_PWM1		(0x00000200)  #define GPIO_PAR_LCDL_LD0_GPIO		(0x00000000)  /* Bit definitions and macros for MSCR_FB */ -#define GPIO_MSCR_FB_DUPPER_MASK	(0xCF) +#define GPIO_MSCR_FB_DUPPER_UNMASK	(0xCF)  #define GPIO_MSCR_FB_DUPPER_25V_33V	(0x30)  #define GPIO_MSCR_FB_DUPPER_FULL_18V	(0x20)  #define GPIO_MSCR_FB_DUPPER_OD		(0x10)  #define GPIO_MSCR_FB_DUPPER_HALF_18V	(0x00) -#define GPIO_MSCR_FB_DLOWER_MASK	(0xF3) +#define GPIO_MSCR_FB_DLOWER_UNMASK	(0xF3)  #define GPIO_MSCR_FB_DLOWER_25V_33V	(0x0C)  #define GPIO_MSCR_FB_DLOWER_FULL_18V	(0x08)  #define GPIO_MSCR_FB_DLOWER_OD		(0x04)  #define GPIO_MSCR_FB_DLOWER_HALF_18V	(0x00) -#define GPIO_MSCR_FB_ADDRCTL_MASK	(0xFC) +#define GPIO_MSCR_FB_ADDRCTL_UNMASK	(0xFC)  #define GPIO_MSCR_FB_ADDRCTL_25V_33V	(0x03)  #define GPIO_MSCR_FB_ADDRCTL_FULL_18V	(0x02)  #define GPIO_MSCR_FB_ADDRCTL_OD		(0x01)  #define GPIO_MSCR_FB_ADDRCTL_HALF_18V	(0x00)  /* Bit definitions and macros for MSCR_SDRAM */ -#define GPIO_MSCR_SDRAM_SDCLKB_MASK	(0xCF) +#define GPIO_MSCR_SDRAM_SDCLKB_UNMASK	(0xCF)  #define GPIO_MSCR_SDRAM_SDCLKB_25V_33V	(0x30)  #define GPIO_MSCR_SDRAM_SDCLKB_FULL_18V	(0x20)  #define GPIO_MSCR_SDRAM_SDCLKB_OD	(0x10)  #define GPIO_MSCR_SDRAM_SDCLKB_HALF_18V	(0x00) -#define GPIO_MSCR_SDRAM_SDCLK_MASK	(0xF3) +#define GPIO_MSCR_SDRAM_SDCLK_UNMASK	(0xF3)  #define GPIO_MSCR_SDRAM_SDCLK_25V_33V	(0x0C)  #define GPIO_MSCR_SDRAM_SDCLK_FULL_18V	(0x08)  #define GPIO_MSCR_SDRAM_SDCLK_OPD	(0x04)  #define GPIO_MSCR_SDRAM_SDCLK_HALF_18V	(0x00) -#define GPIO_MSCR_SDRAM_SDCTL_MASK	(0xFC) +#define GPIO_MSCR_SDRAM_SDCTL_UNMASK	(0xFC)  #define GPIO_MSCR_SDRAM_SDCTL_25V_33V	(0x03)  #define GPIO_MSCR_SDRAM_SDCTL_FULL_18V	(0x02)  #define GPIO_MSCR_SDRAM_SDCTL_OPD	(0x01) diff --git a/include/asm-m68k/m5235.h b/include/asm-m68k/m5235.h index 22987ac77..71a40d33d 100644 --- a/include/asm-m68k/m5235.h +++ b/include/asm-m68k/m5235.h @@ -557,8 +557,8 @@  #define CCM_RCON_MODE			(0x0001)  /* Bit definitions and macros for CCM_CIR */ -#define CCM_CIR_PIN(x)			(((x)&0x03FF)<<6) -#define CCM_CIR_PRN(x)			((x)&0x003F) +#define CCM_CIR_PIN(x)			(((x) & 0xFFC0) >> 6) +#define CCM_CIR_PRN(x)			((x) & 0x003F)  /*********************************************************************  * PLL Clock Module diff --git a/include/asm-m68k/m5301x.h b/include/asm-m68k/m5301x.h index 80cefc40a..0920a0dc2 100644 --- a/include/asm-m68k/m5301x.h +++ b/include/asm-m68k/m5301x.h @@ -254,7 +254,7 @@  #define CCM_MISCCR_PLL_LOCK		(0x2000)  #define CCM_MISCCR_LIMP			(0x1000)  #define CCM_MISCCR_BME			(0x8000) -#define CCM_MISCCR_BMT_MASK		(0xF8FF) +#define CCM_MISCCR_BMT_UNMASK		(0xF8FF)  #define CCM_MISCCR_BMT(x)		(((x) & 0x0007) << 8)  #define CCM_MISCCR_BMT_512		(0x0700)  #define CCM_MISCCR_BMT_1024		(0x0600) @@ -330,32 +330,32 @@  #define GPIO_PAR_CS5			(0x40)  #define GPIO_PAR_CS4			(0x10) -#define GPIO_PAR_CS1_MASK		(0xF3) +#define GPIO_PAR_CS1_UNMASK		(0xF3)  #define GPIO_PAR_CS1_CS1		(0x0C)  #define GPIO_PAR_CS1_SDCS1		(0x08) -#define GPIO_PAR_CS0_MASK		(0xFC) +#define GPIO_PAR_CS0_UNMASK		(0xFC)  #define GPIO_PAR_CS0_CS0		(0x03)  #define GPIO_PAR_CS0_CS4		(0x02) -#define GPIO_PAR_DSPIH_SIN_MASK		(0x3F) +#define GPIO_PAR_DSPIH_SIN_UNMASK	(0x3F)  #define GPIO_PAR_DSPIH_SIN		(0xC0)  #define GPIO_PAR_DSPIH_SIN_U2RXD	(0x80) -#define GPIO_PAR_DSPIH_SOUT_MASK	(0xCF) +#define GPIO_PAR_DSPIH_SOUT_UNMASK	(0xCF)  #define GPIO_PAR_DSPIH_SOUT		(0x30)  #define GPIO_PAR_DSPIH_SOUT_U2TXD	(0x20) -#define GPIO_PAR_DSPIH_SCK_MASK		(0xF3) +#define GPIO_PAR_DSPIH_SCK_UNMASK	(0xF3)  #define GPIO_PAR_DSPIH_SCK		(0x0C)  #define GPIO_PAR_DSPIH_SCK_U2CTS	(0x08) -#define GPIO_PAR_DSPIH_PCS0_MASK	(0xFC) +#define GPIO_PAR_DSPIH_PCS0_UNMASK	(0xFC)  #define GPIO_PAR_DSPIH_PCS0		(0x03)  #define GPIO_PAR_DSPIH_PCS0_U2RTS	(0x02) -#define GPIO_PAR_DSPIL_PCS1_MASK	(0x3F) +#define GPIO_PAR_DSPIL_PCS1_UNMASK	(0x3F)  #define GPIO_PAR_DSPIL_PCS1		(0xC0) -#define GPIO_PAR_DSPIL_PCS2_MASK	(0xCF) +#define GPIO_PAR_DSPIL_PCS2_UNMASK	(0xCF)  #define GPIO_PAR_DSPIL_PCS2		(0x30)  #define GPIO_PAR_DSPIL_PCS2_USBH_OC	(0x20) -#define GPIO_PAR_DSPIL_PCS3_MASK	(0xF3) +#define GPIO_PAR_DSPIL_PCS3_UNMASK	(0xF3)  #define GPIO_PAR_DSPIL_PCS3		(0x0C)  #define GPIO_PAR_DSPIL_PCS3_USBH_EN	(0x08) @@ -365,30 +365,30 @@  #define GPIO_PAR_FEC0_RMII_FEC		(0x01)  /* GPIO_PAR_FECI2C */ -#define GPIO_PAR_FECI2C_RMII0_MASK	(0x3F) +#define GPIO_PAR_FECI2C_RMII0_UNMASK	(0x3F)  #define GPIO_PAR_FECI2C_MDC0		(0x80)  #define GPIO_PAR_FECI2C_MDIO0		(0x40) -#define GPIO_PAR_FECI2C_RMII1_MASK	(0xCF) +#define GPIO_PAR_FECI2C_RMII1_UNMASK	(0xCF)  #define GPIO_PAR_FECI2C_MDC1		(0x20)  #define GPIO_PAR_FECI2C_MDIO1		(0x10) -#define GPIO_PAR_FECI2C_SDA_MASK	(0xF3) +#define GPIO_PAR_FECI2C_SDA_UNMASK	(0xF3)  #define GPIO_PAR_FECI2C_SDA(x)		(((x) & 0x03) << 2)  #define GPIO_PAR_FECI2C_SDA_SDA		(0x0C)  #define GPIO_PAR_FECI2C_SDA_U2TXD	(0x08)  #define GPIO_PAR_FECI2C_SDA_MDIO1	(0x04) -#define GPIO_PAR_FECI2C_SCL_MASK	(0xFC) +#define GPIO_PAR_FECI2C_SCL_UNMASK	(0xFC)  #define GPIO_PAR_FECI2C_SCL(x)		((x) & 0x03)  #define GPIO_PAR_FECI2C_SCL_SCL		(0x03)  #define GPIO_PAR_FECI2C_SCL_U2RXD	(0x02)  #define GPIO_PAR_FECI2C_SCL_MDC1	(0x01) -#define GPIO_PAR_IRQ0H_IRQ07_MASK	(0x3F) -#define GPIO_PAR_IRQ0H_IRQ06_MASK	(0xCF) +#define GPIO_PAR_IRQ0H_IRQ07_UNMASK	(0x3F) +#define GPIO_PAR_IRQ0H_IRQ06_UNMASK	(0xCF)  #define GPIO_PAR_IRQ0H_IRQ06_USBCLKIN	(0x10) -#define GPIO_PAR_IRQ0H_IRQ04_MASK	(0xFC) +#define GPIO_PAR_IRQ0H_IRQ04_UNMASK	(0xFC)  #define GPIO_PAR_IRQ0H_IRQ04_DREQ0	(0x02) -#define GPIO_PAR_IRQ0L_IRQ01_MASK	(0xF3) +#define GPIO_PAR_IRQ0L_IRQ01_UNMASK	(0xF3)  #define GPIO_PAR_IRQ0L_IRQ01_DREQ1	(0x08)  #define GPIO_PAR_IRQ1H_IRQ17_DDATA3	(0x40) @@ -401,24 +401,24 @@  #define GPIO_PAR_IRQ1L_IRQ11_PST1	(0x04)  #define GPIO_PAR_IRQ1L_IRQ10_PST0	(0x01) -#define GPIO_PAR_SIMP1H_DATA1_MASK	(0x3F) +#define GPIO_PAR_SIMP1H_DATA1_UNMASK	(0x3F)  #define GPIO_PAR_SIMP1H_DATA1_SIMDATA1	(0xC0)  #define GPIO_PAR_SIMP1H_DATA1_SSITXD	(0x80)  #define GPIO_PAR_SIMP1H_DATA1_U1TXD	(0x40) -#define GPIO_PAR_SIMP1H_VEN1_MASK	(0xCF) +#define GPIO_PAR_SIMP1H_VEN1_UNMASK	(0xCF)  #define GPIO_PAR_SIMP1H_VEN1_SIMVEN1	(0x30)  #define GPIO_PAR_SIMP1H_VEN1_SSIRXD	(0x20)  #define GPIO_PAR_SIMP1H_VEN1_U1RXD	(0x10) -#define GPIO_PAR_SIMP1H_RST1_MASK	(0xF3) +#define GPIO_PAR_SIMP1H_RST1_UNMASK	(0xF3)  #define GPIO_PAR_SIMP1H_RST1_SIMRST1	(0x0C)  #define GPIO_PAR_SIMP1H_RST1_SSIFS	(0x08)  #define GPIO_PAR_SIMP1H_RST1_U1RTS	(0x04) -#define GPIO_PAR_SIMP1H_PD1_MASK	(0xFC) +#define GPIO_PAR_SIMP1H_PD1_UNMASK	(0xFC)  #define GPIO_PAR_SIMP1H_PD1_SIMPD1	(0x03)  #define GPIO_PAR_SIMP1H_PD1_SSIBCLK	(0x02)  #define GPIO_PAR_SIMP1H_PD1_U1CTS	(0x01) -#define GPIO_PAR_SIMP1L_CLK_MASK	(0x3F) +#define GPIO_PAR_SIMP1L_CLK_UNMASK	(0x3F)  #define GPIO_PAR_SIMP1L_CLK_CLK1	(0xC0)  #define GPIO_PAR_SIMP1L_CLK_SSIMCLK	(0x80) @@ -432,19 +432,19 @@  #define GPIO_PAR_TIN2(x)		(((x) & 0x03) << 4)  #define GPIO_PAR_TIN1(x)		(((x) & 0x03) << 2)  #define GPIO_PAR_TIN0(x)		((x) & 0x03) -#define GPIO_PAR_TIN3_MASK		(0x3F) +#define GPIO_PAR_TIN3_UNMASK		(0x3F)  #define GPIO_PAR_TIN3_TIN3		(0xC0)  #define GPIO_PAR_TIN3_TOUT3		(0x80)  #define GPIO_PAR_TIN3_IRQ03		(0x40) -#define GPIO_PAR_TIN2_MASK		(0xCF) +#define GPIO_PAR_TIN2_UNMASK		(0xCF)  #define GPIO_PAR_TIN2_TIN2		(0x30)  #define GPIO_PAR_TIN2_TOUT2		(0x20)  #define GPIO_PAR_TIN2_IRQ02		(0x10) -#define GPIO_PAR_TIN1_MASK		(0xF3) +#define GPIO_PAR_TIN1_UNMASK		(0xF3)  #define GPIO_PAR_TIN1_TIN1		(0x0C)  #define GPIO_PAR_TIN1_TOUT1		(0x08)  #define GPIO_PAR_TIN1_DACK1		(0x04) -#define GPIO_PAR_TIN0_MASK		(0xFC) +#define GPIO_PAR_TIN0_UNMASK		(0xFC)  #define GPIO_PAR_TIN0_TIN0		(0x03)  #define GPIO_PAR_TIN0_TOUT0		(0x02)  #define GPIO_PAR_TIN0_CODEC_ALTCLK	(0x01) @@ -455,10 +455,10 @@  #define GPIO_PAR_UART_U0RXD		(0x10)  #define GPIO_PAR_UART_RTS0(x)		(((x) & 0x03) << 2)  #define GPIO_PAR_UART_CTS0(x)		((x) & 0x03) -#define GPIO_PAR_UART_RTS0_MASK		(0xF3) +#define GPIO_PAR_UART_RTS0_UNMASK	(0xF3)  #define GPIO_PAR_UART_RTS0_U0RTS	(0x0C)  #define GPIO_PAR_UART_RTS0_USBO_VBOC	(0x08) -#define GPIO_PAR_UART_CTS0_MASK		(0xFC) +#define GPIO_PAR_UART_CTS0_UNMASK	(0xFC)  #define GPIO_PAR_UART_CTS0_U0CTS	(0x03)  #define GPIO_PAR_UART_CTS0_USB0_VBEN	(0x02)  #define GPIO_PAR_UART_CTS0_USB_PULLUP	(0x01) @@ -476,20 +476,20 @@  #define GPIO_PAR_SSIH_TXD(x)		(((x) & 0x03) << 4)  #define GPIO_PAR_SSIH_FS(x)		(((x) & 0x03) << 2)  #define GPIO_PAR_SSIH_MCLK(x)		((x) & 0x03) -#define GPIO_PAR_SSIH_RXD_MASK		(0x3F) +#define GPIO_PAR_SSIH_RXD_UNMASK	(0x3F)  #define GPIO_PAR_SSIH_RXD_SSIRXD	(0xC0)  #define GPIO_PAR_SSIH_RXD_U1RXD		(0x40) -#define GPIO_PAR_SSIH_TXD_MASK		(0xCF) +#define GPIO_PAR_SSIH_TXD_UNMASK	(0xCF)  #define GPIO_PAR_SSIH_TXD_SSIRXD	(0x30)  #define GPIO_PAR_SSIH_TXD_U1TXD		(0x10) -#define GPIO_PAR_SSIH_FS_MASK		(0xF3) +#define GPIO_PAR_SSIH_FS_UNMASK		(0xF3)  #define GPIO_PAR_SSIH_FS_SSIFS		(0x0C)  #define GPIO_PAR_SSIH_FS_U1RTS		(0x04) -#define GPIO_PAR_SSIH_MCLK_MASK		(0xFC) +#define GPIO_PAR_SSIH_MCLK_UNMASK	(0xFC)  #define GPIO_PAR_SSIH_MCLK_SSIMCLK	(0x03)  #define GPIO_PAR_SSIH_MCLK_SSICLKIN	(0x01) -#define GPIO_PAR_SSIL_MASK		(0x3F) +#define GPIO_PAR_SSIL_UNMASK		(0x3F)  #define GPIO_PAR_SSIL_BCLK		(0xC0)  #define GPIO_PAR_SSIL_U1CTS		(0x40) @@ -497,40 +497,40 @@  #define GPIO_MSCR_MSCR2(x)		(((x) & 0x07) << 5)  #define GPIO_MSCR_MSCR3(x)		(((x) & 0x07) << 5)  #define GPIO_MSCR_MSCR4(x)		(((x) & 0x07) << 5) -#define GPIO_MSCR_MSCRn_MASK		(0x1F) +#define GPIO_MSCR_MSCRn_UNMASK		(0x1F)  #define GPIO_MSCR_MSCRn_SDR		(0xE0)  #define GPIO_MSCR_MSCRn_25VDDR		(0x60)  #define GPIO_MSCR_MSCRn_18VDDR_FULL	(0x20)  #define GPIO_MSCR_MSCRn_18VDDR_HALF	(0x00)  #define GPIO_MSCR_MSCR5(x)		(((x) & 0x07) << 2) -#define GPIO_MSCR_MSCR5_MASK		(0xE3) +#define GPIO_MSCR_MSCR5_UNMASK		(0xE3)  #define GPIO_MSCR_MSCR5_SDR		(0x1C)  #define GPIO_MSCR_MSCR5_25VDDR		(0x0C)  #define GPIO_MSCR_MSCR5_18VDDR_FULL	(0x04)  #define GPIO_MSCR_MSCR5_18VDDR_HALF	(0x00) -#define GPIO_SRCR_DSPI_MASK		(0xFC) +#define GPIO_SRCR_DSPI_UNMASK		(0xFC)  #define GPIO_SRCR_DSPI(x)		((x) & 0x03) -#define GPIO_SRCR_I2C_MASK		(0xFC) +#define GPIO_SRCR_I2C_UNMASK		(0xFC)  #define GPIO_SRCR_I2C(x)		((x) & 0x03) -#define GPIO_SRCR_IRQ_IRQ0_MASK		(0xF3) +#define GPIO_SRCR_IRQ_IRQ0_UNMASK	(0xF3)  #define GPIO_SRCR_IRQ_IRQ0(x)		(((x) & 0x03) << 2) -#define GPIO_SRCR_IRQ_IRQ1DBG_MASK	(0xFC) +#define GPIO_SRCR_IRQ_IRQ1DBG_UNMASK	(0xFC)  #define GPIO_SRCR_IRQ_IRQ1DBG(x)	((x) & 0x03) -#define GPIO_SRCR_SIM_SIMP0_MASK	(0xF3) +#define GPIO_SRCR_SIM_SIMP0_UNMASK	(0xF3)  #define GPIO_SRCR_SIM_SIMP0(x)		(((x) & 0x03) << 2) -#define GPIO_SRCR_SIM_SIMP1_MASK	(0xFC) +#define GPIO_SRCR_SIM_SIMP1_UNMASK	(0xFC)  #define GPIO_SRCR_SIM_SIMP1(x)		((x) & 0x03) -#define GPIO_SRCR_TIMER_MASK		(0xFC) +#define GPIO_SRCR_TIMER_UNMASK		(0xFC)  #define GPIO_SRCR_TIMER(x)		((x) & 0x03) -#define GPIO_SRCR_UART2_MASK		(0xF3) +#define GPIO_SRCR_UART2_UNMASK		(0xF3)  #define GPIO_SRCR_UART2(x)		(((x) & 0x03) << 2) -#define GPIO_SRCR_UART0_MASK		(0xFC) +#define GPIO_SRCR_UART0_UNMASK		(0xFC)  #define GPIO_SRCR_UART0(x)		((x) & 0x03) -#define GPIO_SRCR_SDHC_MASK		(0xFC) +#define GPIO_SRCR_SDHC_UNMASK		(0xFC)  #define GPIO_SRCR_SDHC(x)		((x) & 0x03) -#define GPIO_SRCR_SSI_MASK		(0xFC) +#define GPIO_SRCR_SSI_UNMASK		(0xFC)  #define GPIO_SRCR_SSI(x)		((x) & 0x03)  #define SRCR_HIGHEST			(0x03) @@ -538,11 +538,11 @@  #define SRCR_LOW			(0x01)  #define SRCR_LOWEST			(0x00) -#define GPIO_DSCR_FEC_RMIICLK_MASK	(0xCF) +#define GPIO_DSCR_FEC_RMIICLK_UNMASK	(0xCF)  #define GPIO_DSCR_FEC_RMIICLK(x)	(((x) & 0x03) << 4) -#define GPIO_DSCR_FEC_RMII0_MASK	(0xF3) +#define GPIO_DSCR_FEC_RMII0_UNMASK	(0xF3)  #define GPIO_DSCR_FEC_RMII0(x)		(((x) & 0x03) << 2) -#define GPIO_DSCR_FEC_RMII1_MASK	(0xFC) +#define GPIO_DSCR_FEC_RMII1_UNMASK	(0xFC)  #define GPIO_DSCR_FEC_RMII1(x)		((x) & 0x03)  #define DSCR_50PF			(0x03) @@ -572,18 +572,18 @@  #define PLL_PCR_LOL_IRQ			(0x00004000)  #define PLL_PCR_LOL_RE			(0x00002000)  #define PLL_PCR_LOL_EN			(0x00001000) -#define PLL_PCR_REFDIV_MASK		(0xFFFFF8FF) +#define PLL_PCR_REFDIV_UNMASK		(0xFFFFF8FF)  #define PLL_PCR_REFDIV(x)		(((x) & 0x07) << 8) -#define PLL_PCR_FBDIV_MASK		(0xFFFFFFC0) +#define PLL_PCR_FBDIV_UNMASK		(0xFFFFFFC0)  #define PLL_PCR_FBDIV(x)		((x) & 0x3F) -#define PLL_PDR_OUTDIV4_MASK		(0x0FFF) +#define PLL_PDR_OUTDIV4_UNMASK		(0x0FFF)  #define PLL_PDR_OUTDIV4(x)		(((x) & 0x0000000F) << 12) -#define PLL_PDR_OUTDIV3_MASK		(0xF0FF) +#define PLL_PDR_OUTDIV3_UNMASK		(0xF0FF)  #define PLL_PDR_OUTDIV3(x)		(((x) & 0x0000000F) << 8) -#define PLL_PDR_OUTDIV2_MASK		(0xFF0F) +#define PLL_PDR_OUTDIV2_UNMASK		(0xFF0F)  #define PLL_PDR_OUTDIV2(x)		(((x) & 0x0000000F) << 4) -#define PLL_PDR_OUTDIV1_MASK		(0xFFF0) +#define PLL_PDR_OUTDIV1_UNMASK		(0xFFF0)  #define PLL_PDR_OUTDIV1(x)		((x) & 0x0000000F)  #define PLL_PDR_USB(x)			PLL_PDR_OUTDIV4(x)  #define PLL_PDR_SDRAM(x)		PLL_PDR_OUTDIV3(x) diff --git a/include/asm-m68k/m5445x.h b/include/asm-m68k/m5445x.h index 596662191..dfddde62a 100644 --- a/include/asm-m68k/m5445x.h +++ b/include/asm-m68k/m5445x.h @@ -286,13 +286,13 @@  /* Bit definitions and macros for PAR_FEC */  #define GPIO_PAR_FEC_FEC0(x)		(((x)&0x07))  #define GPIO_PAR_FEC_FEC1(x)		(((x)&0x07)<<4) -#define GPIO_PAR_FEC_FEC1_MASK		(0x8F) +#define GPIO_PAR_FEC_FEC1_UNMASK	(0x8F)  #define GPIO_PAR_FEC_FEC1_MII		(0x70)  #define GPIO_PAR_FEC_FEC1_RMII_GPIO	(0x30)  #define GPIO_PAR_FEC_FEC1_RMII_ATA	(0x20)  #define GPIO_PAR_FEC_FEC1_ATA		(0x10)  #define GPIO_PAR_FEC_FEC1_GPIO		(0x00) -#define GPIO_PAR_FEC_FEC0_MASK		(0xF8) +#define GPIO_PAR_FEC_FEC0_UNMASK	(0xF8)  #define GPIO_PAR_FEC_FEC0_MII		(0x07)  #define GPIO_PAR_FEC_FEC0_RMII_GPIO	(0x03)  #define GPIO_PAR_FEC_FEC0_RMII_ULPI	(0x02) @@ -304,15 +304,15 @@  #define GPIO_PAR_DMA_DACK0(x)		(((x)&0x03)<<2)  #define GPIO_PAR_DMA_DREQ1(x)		(((x)&0x03)<<4)  #define GPIO_PAR_DMA_DACK1(x)		(((x)&0x03)<<6) -#define GPIO_PAR_DMA_DACK1_MASK		(0x3F) +#define GPIO_PAR_DMA_DACK1_UNMASK	(0x3F)  #define GPIO_PAR_DMA_DACK1_DACK1	(0xC0)  #define GPIO_PAR_DMA_DACK1_ULPI_DIR	(0x40)  #define GPIO_PAR_DMA_DACK1_GPIO		(0x00) -#define GPIO_PAR_DMA_DREQ1_MASK		(0xCF) +#define GPIO_PAR_DMA_DREQ1_UNMASK	(0xCF)  #define GPIO_PAR_DMA_DREQ1_DREQ1	(0x30)  #define GPIO_PAR_DMA_DREQ1_USB_CLKIN	(0x10)  #define GPIO_PAR_DMA_DREQ1_GPIO		(0x00) -#define GPIO_PAR_DMA_DACK0_MASK		(0xF3) +#define GPIO_PAR_DMA_DACK0_UNMASK	(0xF3)  #define GPIO_PAR_DMA_DACK0_DACK1	(0x0C)  #define GPIO_PAR_DMA_DACK0_ULPI_DIR	(0x04)  #define GPIO_PAR_DMA_DACK0_GPIO		(0x00) @@ -330,7 +330,7 @@  #define GPIO_PAR_FBCTL_TA_GPIO		(0x00)  #define GPIO_PAR_FBCTL_RW_RW		(0x20)  #define GPIO_PAR_FBCTL_RW_GPIO		(0x00) -#define GPIO_PAR_FBCTL_TS_MASK		(0xE7) +#define GPIO_PAR_FBCTL_TS_UNMASK	(0xE7)  #define GPIO_PAR_FBCTL_TS_TS		(0x18)  #define GPIO_PAR_FBCTL_TS_ALE		(0x10)  #define GPIO_PAR_FBCTL_TS_TBST		(0x08) @@ -364,11 +364,11 @@  #define GPIO_PAR_BE_BS1			(0x04)  #define GPIO_PAR_BE_BS2(x)		(((x)&0x03)<<4)  #define GPIO_PAR_BE_BS3(x)		(((x)&0x03)<<6) -#define GPIO_PAR_BE_BE3_MASK		(0x3F) +#define GPIO_PAR_BE_BE3_UNMASK		(0x3F)  #define GPIO_PAR_BE_BE3_BE3		(0xC0)  #define GPIO_PAR_BE_BE3_TSIZ1		(0x80)  #define GPIO_PAR_BE_BE3_GPIO		(0x00) -#define GPIO_PAR_BE_BE2_MASK		(0xCF) +#define GPIO_PAR_BE_BE2_UNMASK		(0xCF)  #define GPIO_PAR_BE_BE2_BE2		(0x30)  #define GPIO_PAR_BE_BE2_TSIZ0		(0x20)  #define GPIO_PAR_BE_BE2_GPIO		(0x00) @@ -393,22 +393,22 @@  #define GPIO_PAR_TIMER_T1IN(x)		(((x)&0x03)<<2)  #define GPIO_PAR_TIMER_T2IN(x)		(((x)&0x03)<<4)  #define GPIO_PAR_TIMER_T3IN(x)		(((x)&0x03)<<6) -#define GPIO_PAR_TIMER_T3IN_MASK	(0x3F) +#define GPIO_PAR_TIMER_T3IN_UNMASK	(0x3F)  #define GPIO_PAR_TIMER_T3IN_T3IN	(0xC0)  #define GPIO_PAR_TIMER_T3IN_T3OUT	(0x80)  #define GPIO_PAR_TIMER_T3IN_U2RXD	(0x40)  #define GPIO_PAR_TIMER_T3IN_GPIO	(0x00) -#define GPIO_PAR_TIMER_T2IN_MASK	(0xCF) +#define GPIO_PAR_TIMER_T2IN_UNMASK	(0xCF)  #define GPIO_PAR_TIMER_T2IN_T2IN	(0x30)  #define GPIO_PAR_TIMER_T2IN_T2OUT	(0x20)  #define GPIO_PAR_TIMER_T2IN_U2TXD	(0x10)  #define GPIO_PAR_TIMER_T2IN_GPIO	(0x00) -#define GPIO_PAR_TIMER_T1IN_MASK	(0xF3) +#define GPIO_PAR_TIMER_T1IN_UNMASK	(0xF3)  #define GPIO_PAR_TIMER_T1IN_T1IN	(0x0C)  #define GPIO_PAR_TIMER_T1IN_T1OUT	(0x08)  #define GPIO_PAR_TIMER_T1IN_U2CTS	(0x04)  #define GPIO_PAR_TIMER_T1IN_GPIO	(0x00) -#define GPIO_PAR_TIMER_T0IN_MASK	(0xFC) +#define GPIO_PAR_TIMER_T0IN_UNMASK	(0xFC)  #define GPIO_PAR_TIMER_T0IN_T0IN	(0x03)  #define GPIO_PAR_TIMER_T0IN_T0OUT	(0x02)  #define GPIO_PAR_TIMER_T0IN_U2RTS	(0x01) @@ -417,12 +417,12 @@  /* Bit definitions and macros for PAR_USB */  #define GPIO_PAR_USB_VBUSOC(x)		(((x)&0x03))  #define GPIO_PAR_USB_VBUSEN(x)		(((x)&0x03)<<2) -#define GPIO_PAR_USB_VBUSEN_MASK	(0xF3) +#define GPIO_PAR_USB_VBUSEN_UNMASK	(0xF3)  #define GPIO_PAR_USB_VBUSEN_VBUSEN	(0x0C)  #define GPIO_PAR_USB_VBUSEN_USBPULLUP	(0x08)  #define GPIO_PAR_USB_VBUSEN_ULPI_NXT	(0x04)  #define GPIO_PAR_USB_VBUSEN_GPIO	(0x00) -#define GPIO_PAR_USB_VBUSOC_MASK	(0xFC) +#define GPIO_PAR_USB_VBUSOC_UNMASK	(0xFC)  #define GPIO_PAR_USB_VBUSOC_VBUSOC	(0x03)  #define GPIO_PAR_USB_VBUSOC_ULPI_STP	(0x01)  #define GPIO_PAR_USB_VBUSOC_GPIO	(0x00) @@ -460,11 +460,11 @@  #define GPIO_PAR_FECI2C_MDC0		(0x0040)  #define GPIO_PAR_FECI2C_MDIO1(x)	(((x)&0x0003)<<8)  #define GPIO_PAR_FECI2C_MDC1(x)		(((x)&0x0003)<<10) -#define GPIO_PAR_FECI2C_MDC1_MASK	(0xF3FF) +#define GPIO_PAR_FECI2C_MDC1_UNMASK	(0xF3FF)  #define GPIO_PAR_FECI2C_MDC1_MDC1	(0x0C00)  #define GPIO_PAR_FECI2C_MDC1_ATA_DIOR	(0x0800)  #define GPIO_PAR_FECI2C_MDC1_GPIO	(0x0000) -#define GPIO_PAR_FECI2C_MDIO1_MASK	(0xFCFF) +#define GPIO_PAR_FECI2C_MDIO1_UNMASK	(0xFCFF)  #define GPIO_PAR_FECI2C_MDIO1_MDIO1	(0x0300)  #define GPIO_PAR_FECI2C_MDIO1_ATA_DIOW	(0x0200)  #define GPIO_PAR_FECI2C_MDIO1_GPIO	(0x0000) @@ -472,11 +472,11 @@  #define GPIO_PAR_FECI2C_MDC0_GPIO	(0x0000)  #define GPIO_PAR_FECI2C_MDIO0_MDIO0	(0x0010)  #define GPIO_PAR_FECI2C_MDIO0_GPIO	(0x0000) -#define GPIO_PAR_FECI2C_SCL_MASK	(0xFFF3) +#define GPIO_PAR_FECI2C_SCL_UNMASK	(0xFFF3)  #define GPIO_PAR_FECI2C_SCL_SCL		(0x000C)  #define GPIO_PAR_FECI2C_SCL_U2TXD	(0x0004)  #define GPIO_PAR_FECI2C_SCL_GPIO	(0x0000) -#define GPIO_PAR_FECI2C_SDA_MASK	(0xFFFC) +#define GPIO_PAR_FECI2C_SDA_UNMASK	(0xFFFC)  #define GPIO_PAR_FECI2C_SDA_SDA		(0x0003)  #define GPIO_PAR_FECI2C_SDA_U2RXD	(0x0001)  #define GPIO_PAR_FECI2C_SDA_GPIO	(0x0000) @@ -487,19 +487,19 @@  #define GPIO_PAR_SSI_SRXD(x)		(((x)&0x0003)<<4)  #define GPIO_PAR_SSI_FS(x)		(((x)&0x0003)<<6)  #define GPIO_PAR_SSI_BCLK(x)		(((x)&0x0003)<<8) -#define GPIO_PAR_SSI_BCLK_MASK		(0xFCFF) +#define GPIO_PAR_SSI_BCLK_UNMASK	(0xFCFF)  #define GPIO_PAR_SSI_BCLK_BCLK		(0x0300)  #define GPIO_PAR_SSI_BCLK_U1CTS		(0x0200)  #define GPIO_PAR_SSI_BCLK_GPIO		(0x0000) -#define GPIO_PAR_SSI_FS_MASK		(0xFF3F) +#define GPIO_PAR_SSI_FS_UNMASK		(0xFF3F)  #define GPIO_PAR_SSI_FS_FS		(0x00C0)  #define GPIO_PAR_SSI_FS_U1RTS		(0x0080)  #define GPIO_PAR_SSI_FS_GPIO		(0x0000) -#define GPIO_PAR_SSI_SRXD_MASK		(0xFFCF) +#define GPIO_PAR_SSI_SRXD_UNMASK	(0xFFCF)  #define GPIO_PAR_SSI_SRXD_SRXD		(0x0030)  #define GPIO_PAR_SSI_SRXD_U1RXD		(0x0020)  #define GPIO_PAR_SSI_SRXD_GPIO		(0x0000) -#define GPIO_PAR_SSI_STXD_MASK		(0xFFF3) +#define GPIO_PAR_SSI_STXD_UNMASK	(0xFFF3)  #define GPIO_PAR_SSI_STXD_STXD		(0x000C)  #define GPIO_PAR_SSI_STXD_U1TXD		(0x0008)  #define GPIO_PAR_SSI_STXD_GPIO		(0x0000) @@ -552,7 +552,7 @@  #define GPIO_PAR_PCI_GNT1		(0x0400)  #define GPIO_PAR_PCI_GNT2		(0x1000)  #define GPIO_PAR_PCI_GNT3(x)		(((x)&0x0003)<<14) -#define GPIO_PAR_PCI_GNT3_MASK		(0x3FFF) +#define GPIO_PAR_PCI_GNT3_UNMASK	(0x3FFF)  #define GPIO_PAR_PCI_GNT3_GNT3		(0xC000)  #define GPIO_PAR_PCI_GNT3_ATA_DMACK	(0x8000)  #define GPIO_PAR_PCI_GNT3_GPIO		(0x0000) @@ -562,7 +562,7 @@  #define GPIO_PAR_PCI_GNT1_GPIO		(0x0000)  #define GPIO_PAR_PCI_GNT0_GNT0		(0x0100)  #define GPIO_PAR_PCI_GNT0_GPIO		(0x0000) -#define GPIO_PAR_PCI_REQ3_MASK		(0xFF3F) +#define GPIO_PAR_PCI_REQ3_UNMASK	(0xFF3F)  #define GPIO_PAR_PCI_REQ3_REQ3		(0x00C0)  #define GPIO_PAR_PCI_REQ3_ATA_INTRQ	(0x0080)  #define GPIO_PAR_PCI_REQ3_GPIO		(0x0000) @@ -578,22 +578,22 @@  #define GPIO_MSCR_SDRAM_SDCLK(x)	(((x)&0x03)<<2)  #define GPIO_MSCR_SDRAM_SDDQS(x)	(((x)&0x03)<<4)  #define GPIO_MSCR_SDRAM_SDDATA(x)	(((x)&0x03)<<6) -#define GPIO_MSCR_SDRAM_SDDATA_MASK	(0x3F) +#define GPIO_MSCR_SDRAM_SDDATA_UNMASK	(0x3F)  #define GPIO_MSCR_SDRAM_SDDATA_DDR1	(0xC0)  #define GPIO_MSCR_SDRAM_SDDATA_DDR2	(0x80)  #define GPIO_MSCR_SDRAM_SDDATA_FS_LPDDR	(0x40)  #define GPIO_MSCR_SDRAM_SDDATA_HS_LPDDR	(0x00) -#define GPIO_MSCR_SDRAM_SDDQS_MASK	(0xCF) +#define GPIO_MSCR_SDRAM_SDDQS_UNMASK	(0xCF)  #define GPIO_MSCR_SDRAM_SDDQS_DDR1	(0x30)  #define GPIO_MSCR_SDRAM_SDDQS_DDR2	(0x20)  #define GPIO_MSCR_SDRAM_SDDQS_FS_LPDDR	(0x10)  #define GPIO_MSCR_SDRAM_SDDQS_HS_LPDDR	(0x00) -#define GPIO_MSCR_SDRAM_SDCLK_MASK	(0xF3) +#define GPIO_MSCR_SDRAM_SDCLK_UNMASK	(0xF3)  #define GPIO_MSCR_SDRAM_SDCLK_DDR1	(0x0C)  #define GPIO_MSCR_SDRAM_SDCLK_DDR2	(0x08)  #define GPIO_MSCR_SDRAM_SDCLK_FS_LPDDR	(0x04)  #define GPIO_MSCR_SDRAM_SDCLK_HS_LPDDR	(0x00) -#define GPIO_MSCR_SDRAM_SDCTL_MASK	(0xFC) +#define GPIO_MSCR_SDRAM_SDCTL_UNMASK	(0xFC)  #define GPIO_MSCR_SDRAM_SDCTL_DDR1	(0x03)  #define GPIO_MSCR_SDRAM_SDCTL_DDR2	(0x02)  #define GPIO_MSCR_SDRAM_SDCTL_FS_LPDDR	(0x01) |