m68knommu: use container_of in mcf.c
[wrt350n-kernel.git] / drivers / serial / cpm_uart / cpm_uart_cpm1.h
blobddf46d3c964b0aefa131e3860671f3304c6881c1
1 /*
2 * linux/drivers/serial/cpm_uart/cpm_uart_cpm1.h
4 * Driver for CPM (SCC/SMC) serial ports
5 *
6 * definitions for cpm1
8 */
10 #ifndef CPM_UART_CPM1_H
11 #define CPM_UART_CPM1_H
13 #include <asm/cpm1.h>
15 /* defines for IRQs */
16 #ifndef CONFIG_PPC_CPM_NEW_BINDING
17 #define SMC1_IRQ (CPM_IRQ_OFFSET + CPMVEC_SMC1)
18 #define SMC2_IRQ (CPM_IRQ_OFFSET + CPMVEC_SMC2)
19 #define SCC1_IRQ (CPM_IRQ_OFFSET + CPMVEC_SCC1)
20 #define SCC2_IRQ (CPM_IRQ_OFFSET + CPMVEC_SCC2)
21 #define SCC3_IRQ (CPM_IRQ_OFFSET + CPMVEC_SCC3)
22 #define SCC4_IRQ (CPM_IRQ_OFFSET + CPMVEC_SCC4)
23 #endif
25 static inline void cpm_set_brg(int brg, int baud)
27 cpm_setbrg(brg, baud);
30 static inline void cpm_set_scc_fcr(scc_uart_t __iomem * sup)
32 out_8(&sup->scc_genscc.scc_rfcr, SMC_EB);
33 out_8(&sup->scc_genscc.scc_tfcr, SMC_EB);
36 static inline void cpm_set_smc_fcr(smc_uart_t __iomem * up)
38 out_8(&up->smc_rfcr, SMC_EB);
39 out_8(&up->smc_tfcr, SMC_EB);
42 #define DPRAM_BASE ((u8 __iomem __force *)cpm_dpram_addr(0))
44 #endif