diff options
author | florian <florian@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2011-06-12 19:17:57 +0000 |
---|---|---|
committer | florian <florian@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2011-06-12 19:17:57 +0000 |
commit | 27e94101def26f60ce5f65835c082f791f6ed641 (patch) | |
tree | 7dcda6dd00b39a1cf0a038df25cca76a1b213a09 /target/linux/adm5120/files/arch/mips | |
parent | 9f0d58cb15d8f345bfacb0b2e6f7aa86e62e1e31 (diff) |
[adm5120] cleanup files using checkpatch.pl
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@27162 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/adm5120/files/arch/mips')
18 files changed, 92 insertions, 87 deletions
diff --git a/target/linux/adm5120/files/arch/mips/adm5120/common/early-printk.c b/target/linux/adm5120/files/arch/mips/adm5120/common/early-printk.c index 6aff1475a9..d900712639 100644 --- a/target/linux/adm5120/files/arch/mips/adm5120/common/early-printk.c +++ b/target/linux/adm5120/files/arch/mips/adm5120/common/early-printk.c @@ -23,7 +23,9 @@ void __init prom_putchar(char ch) { - while ((UART_READ(UART_REG_FLAG) & UART_FLAG_TXFE) == 0); + while ((UART_READ(UART_REG_FLAG) & UART_FLAG_TXFE) == 0) + ; UART_WRITE(UART_REG_DATA, ch); - while ((UART_READ(UART_REG_FLAG) & UART_FLAG_TXFE) == 0); + while ((UART_READ(UART_REG_FLAG) & UART_FLAG_TXFE) == 0) + ; } diff --git a/target/linux/adm5120/files/arch/mips/adm5120/common/gpio.c b/target/linux/adm5120/files/arch/mips/adm5120/common/gpio.c index 855dd90c99..e60ed7ad01 100644 --- a/target/linux/adm5120/files/arch/mips/adm5120/common/gpio.c +++ b/target/linux/adm5120/files/arch/mips/adm5120/common/gpio.c @@ -32,10 +32,10 @@ struct gpio1_desc { u8 mode_shift; /* shift amount for mode bits */ }; -#define GPIO1_DESC(p, l) { \ +#define GPIO1_DESC(p, l) { \ .reg = GPIO_REG(SWITCH_REG_PORT0_LED + ((p) * 4)), \ - .iv_shift = LED0_IV_SHIFT + (l), \ - .mode_shift = (l) * 4 \ + .iv_shift = LED0_IV_SHIFT + (l), \ + .mode_shift = (l) * 4 \ } static struct gpio1_desc gpio1_table[15] = { diff --git a/target/linux/adm5120/files/arch/mips/adm5120/common/irq.c b/target/linux/adm5120/files/arch/mips/adm5120/common/irq.c index 140a7a0e95..9a259b2d11 100644 --- a/target/linux/adm5120/files/arch/mips/adm5120/common/irq.c +++ b/target/linux/adm5120/files/arch/mips/adm5120/common/irq.c @@ -16,10 +16,10 @@ #include <linux/interrupt.h> #include <linux/ioport.h> #include <linux/io.h> +#include <linux/bitops.h> #include <asm/irq_cpu.h> #include <asm/mipsregs.h> -#include <asm/bitops.h> #include <asm/mach-adm5120/adm5120_defs.h> @@ -42,16 +42,16 @@ static inline u32 intc_read_reg(unsigned int reg) } static struct irq_chip adm5120_intc_irq_chip = { - .name = "INTC", - .unmask = adm5120_intc_irq_unmask, - .mask = adm5120_intc_irq_mask, + .name = "INTC", + .unmask = adm5120_intc_irq_unmask, + .mask = adm5120_intc_irq_mask, .mask_ack = adm5120_intc_irq_mask, .set_type = adm5120_intc_irq_set_type }; static struct irqaction adm5120_intc_irq_action = { - .handler = no_action, - .name = "cascade [INTC]" + .handler = no_action, + .name = "cascade [INTC]" }; static void adm5120_intc_irq_unmask(unsigned int irq) @@ -170,7 +170,8 @@ static void __init adm5120_intc_irq_init(void) setup_irq(ADM5120_IRQ_INTC, &adm5120_intc_irq_action); } -void __init arch_init_irq(void) { +void __init arch_init_irq(void) +{ mips_cpu_irq_init(); adm5120_intc_irq_init(); } diff --git a/target/linux/adm5120/files/arch/mips/adm5120/common/prom.c b/target/linux/adm5120/files/arch/mips/adm5120/common/prom.c index 8506366ab1..5c52ea27e2 100644 --- a/target/linux/adm5120/files/arch/mips/adm5120/common/prom.c +++ b/target/linux/adm5120/files/arch/mips/adm5120/common/prom.c @@ -67,7 +67,7 @@ static struct board_desc common_boards[] __initdata = { /* OSBRiDGE boards */ DEFBOARD("OSBRiDGE 5GXi", MACH_ADM5120_5GXI), /* Motorola boards */ - DEFBOARD("Powerline MU Gateway",MACH_ADM5120_PMUGW), + DEFBOARD("Powerline MU Gateway", MACH_ADM5120_PMUGW), /* Generic EB-214A */ DEFBOARD("ADM5120", MACH_ADM5120_EB_214A), }; @@ -249,7 +249,7 @@ static void __init prom_init_cmdline(void) } #else -static void inline prom_init_cmdline(void) {} +static inline void prom_init_cmdline(void) {} #endif /* CONFIG_IMAGE_CMDLINE_HACK */ void __init prom_init(void) diff --git a/target/linux/adm5120/files/arch/mips/adm5120/common/setup.c b/target/linux/adm5120/files/arch/mips/adm5120/common/setup.c index 41956c8f8c..c4be845170 100644 --- a/target/linux/adm5120/files/arch/mips/adm5120/common/setup.c +++ b/target/linux/adm5120/files/arch/mips/adm5120/common/setup.c @@ -20,10 +20,12 @@ #include <linux/init.h> #include <linux/kernel.h> #include <linux/io.h> +#include <linux/reboot.h> +#include <linux/time.h> -#include <asm/bootinfo.h> #include <asm/reboot.h> #include <asm/time.h> +#include <asm/bootinfo.h> #include <asm/mips_machine.h> #include <asm/mach-adm5120/adm5120_info.h> @@ -49,7 +51,7 @@ static void __init adm5120_report(void) { printk(KERN_INFO "SoC : %s\n", adm5120_sys_type); printk(KERN_INFO "Bootdev : %s flash\n", - adm5120_nand_boot ? "NAND":"NOR"); + adm5120_nand_boot ? "NAND" : "NOR"); printk(KERN_INFO "Prom : %s\n", prom_names[adm5120_prom_type]); } diff --git a/target/linux/adm5120/files/arch/mips/adm5120/generic/eb-214a.c b/target/linux/adm5120/files/arch/mips/adm5120/generic/eb-214a.c index 4ebe413a3c..d1d5fa99f4 100644 --- a/target/linux/adm5120/files/arch/mips/adm5120/generic/eb-214a.c +++ b/target/linux/adm5120/files/arch/mips/adm5120/generic/eb-214a.c @@ -103,7 +103,7 @@ static void __init eb214a_setup(void) adm5120_add_device_gpio(EB214A_GPIO_DEV_MASK); adm5120_add_device_uart(0); - //adm5120_add_device_uart(1); + /* adm5120_add_device_uart(1); */ adm5120_add_device_switch(5, eb214a_vlans); @@ -117,7 +117,7 @@ static void __init eb214a_setup(void) adm5120_pci_set_irq_map(ARRAY_SIZE(eb214a_pci_irqs), eb214a_pci_irqs); -// adm5120_add_device_usb(); + /* adm5120_add_device_usb(); */ } MIPS_MACHINE(MACH_ADM5120_EB_214A, "EB-214A", "Generic EB-214A", eb214a_setup); diff --git a/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-11x.c b/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-11x.c index 9adf633dfd..30625c9202 100644 --- a/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-11x.c +++ b/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-11x.c @@ -13,8 +13,8 @@ static struct gpio_led rb11x_gpio_leds[] __initdata = { GPIO_LED_STD(ADM5120_GPIO_PIN3, "user", NULL), - GPIO_LED_INV(ADM5120_GPIO_P0L1, "lan_speed", NULL), - GPIO_LED_INV(ADM5120_GPIO_P0L0, "lan_lnkact", NULL), + GPIO_LED_INV(ADM5120_GPIO_P0L1, "lan_speed", NULL), + GPIO_LED_INV(ADM5120_GPIO_P0L0, "lan_lnkact", NULL), }; static u8 rb11x_vlans[6] __initdata = { diff --git a/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-133.c b/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-133.c index 5045b2b9d0..4d8fae011a 100644 --- a/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-133.c +++ b/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-133.c @@ -14,12 +14,12 @@ static struct gpio_led rb133_gpio_leds[] __initdata = { GPIO_LED_STD(ADM5120_GPIO_PIN6, "power", NULL), GPIO_LED_STD(ADM5120_GPIO_PIN5, "user", NULL), - GPIO_LED_INV(ADM5120_GPIO_P2L1, "lan1_speed", NULL), - GPIO_LED_INV(ADM5120_GPIO_P2L0, "lan1_lnkact", NULL), - GPIO_LED_INV(ADM5120_GPIO_P1L1, "lan2_speed", NULL), - GPIO_LED_INV(ADM5120_GPIO_P1L0, "lan2_lnkact", NULL), - GPIO_LED_INV(ADM5120_GPIO_P0L1, "lan3_speed", NULL), - GPIO_LED_INV(ADM5120_GPIO_P0L0, "lan3_lnkact", NULL), + GPIO_LED_INV(ADM5120_GPIO_P2L1, "lan1_speed", NULL), + GPIO_LED_INV(ADM5120_GPIO_P2L0, "lan1_lnkact", NULL), + GPIO_LED_INV(ADM5120_GPIO_P1L1, "lan2_speed", NULL), + GPIO_LED_INV(ADM5120_GPIO_P1L0, "lan2_lnkact", NULL), + GPIO_LED_INV(ADM5120_GPIO_P0L1, "lan3_speed", NULL), + GPIO_LED_INV(ADM5120_GPIO_P0L0, "lan3_lnkact", NULL), }; static u8 rb133_vlans[6] __initdata = { diff --git a/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-133c.c b/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-133c.c index b5caa485ca..11924c1326 100644 --- a/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-133c.c +++ b/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-133c.c @@ -14,8 +14,8 @@ static struct gpio_led rb133c_gpio_leds[] __initdata = { GPIO_LED_STD(ADM5120_GPIO_PIN6, "power", NULL), GPIO_LED_STD(ADM5120_GPIO_PIN5, "user", NULL), - GPIO_LED_INV(ADM5120_GPIO_P2L1, "lan1_speed", NULL), - GPIO_LED_INV(ADM5120_GPIO_P2L0, "lan1_lnkact", NULL), + GPIO_LED_INV(ADM5120_GPIO_P2L1, "lan1_speed", NULL), + GPIO_LED_INV(ADM5120_GPIO_P2L0, "lan1_lnkact", NULL), }; static u8 rb133c_vlans[6] __initdata = { diff --git a/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-150.c b/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-150.c index 35d4300d29..af9525635e 100644 --- a/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-150.c +++ b/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-150.c @@ -20,7 +20,7 @@ #define RB150_GPIO_NAND_ALE ADM5120_GPIO_P3L2 #define RB150_GPIO_RESET_BUTTON ADM5120_GPIO_PIN1 /* FIXME */ -#define RB150_GPIO_DEV_MASK ( 1 << RB150_GPIO_NAND_READY \ +#define RB150_GPIO_DEV_MASK (1 << RB150_GPIO_NAND_READY \ | 1 << RB150_GPIO_NAND_NCE \ | 1 << RB150_GPIO_NAND_CLE \ | 1 << RB150_GPIO_NAND_ALE) diff --git a/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-153.c b/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-153.c index decf98bb27..b2ebdc7c10 100644 --- a/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-153.c +++ b/target/linux/adm5120/files/arch/mips/adm5120/mikrotik/rb-153.c @@ -11,9 +11,9 @@ #include "rb-1xx.h" -#define RB153_GPIO_DEV_MASK ( 1 << ADM5120_GPIO_PIN0 \ +#define RB153_GPIO_DEV_MASK (1 << ADM5120_GPIO_PIN0 \ | 1 << ADM5120_GPIO_PIN3 \ - | 1 << ADM5120_GPIO_PIN4 ) + | 1 << ADM5120_GPIO_PIN4) static struct resource rb153_cf_resources[] __initdata = { { diff --git a/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_info.h b/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_info.h index 9e72c1b1a1..1d34d80ee6 100644 --- a/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_info.h +++ b/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_info.h @@ -89,7 +89,7 @@ enum { /* * TODO:remove adm5120_eth* variables when the switch driver will be - * converted into a real platform driver + * converted into a real platform driver */ extern unsigned int adm5120_eth_num_ports; extern unsigned char adm5120_eth_macs[6][6]; diff --git a/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_intc.h b/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_intc.h index 52883cf2dc..70dd6bbe85 100644 --- a/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_intc.h +++ b/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_intc.h @@ -48,16 +48,16 @@ /* * INTC register bits */ -#define INTC_INT_TIMER ( 1 << INTC_IRQ_TIMER ) -#define INTC_INT_UART0 ( 1 << INTC_IRQ_UART0 ) -#define INTC_INT_UART1 ( 1 << INTC_IRQ_UART1 ) -#define INTC_INT_USBC ( 1 << INTC_IRQ_USBC ) -#define INTC_INT_INTX0 ( 1 << INTC_IRQ_INTX0 ) -#define INTC_INT_INTX1 ( 1 << INTC_IRQ_INTX1 ) -#define INTC_INT_PCI0 ( 1 << INTC_IRQ_PCI0 ) -#define INTC_INT_PCI1 ( 1 << INTC_IRQ_PCI1 ) -#define INTC_INT_PCI2 ( 1 << INTC_IRQ_PCI2 ) -#define INTC_INT_SWITCH ( 1 << INTC_IRQ_SWITCH ) -#define INTC_INT_ALL (( 1 << INTC_IRQ_COUNT)-1) +#define INTC_INT_TIMER (1 << INTC_IRQ_TIMER) +#define INTC_INT_UART0 (1 << INTC_IRQ_UART0) +#define INTC_INT_UART1 (1 << INTC_IRQ_UART1) +#define INTC_INT_USBC (1 << INTC_IRQ_USBC) +#define INTC_INT_INTX0 (1 << INTC_IRQ_INTX0) +#define INTC_INT_INTX1 (1 << INTC_IRQ_INTX1) +#define INTC_INT_PCI0 (1 << INTC_IRQ_PCI0) +#define INTC_INT_PCI1 (1 << INTC_IRQ_PCI1) +#define INTC_INT_PCI2 (1 << INTC_IRQ_PCI2) +#define INTC_INT_SWITCH (1 << INTC_IRQ_SWITCH) +#define INTC_INT_ALL ((1 << INTC_IRQ_COUNT) - 1) #endif /* _MACH_ADM5120_INTC_H */ diff --git a/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_mpmc.h b/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_mpmc.h index 5383659dbf..c4e9591fb8 100644 --- a/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_mpmc.h +++ b/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_mpmc.h @@ -44,25 +44,25 @@ #define MPMC_REG_SC3 0x0260 /* Control register bits */ -#define MPMC_CTRL_AM ( 1 << 1 ) /* Address Mirror */ -#define MPMC_CTRL_LPM ( 1 << 2 ) /* Low Power Mode */ -#define MPMC_CTRL_DWB ( 1 << 3 ) /* Drain Write Buffers */ +#define MPMC_CTRL_AM (1 << 1) /* Address Mirror */ +#define MPMC_CTRL_LPM (1 << 2) /* Low Power Mode */ +#define MPMC_CTRL_DWB (1 << 3) /* Drain Write Buffers */ /* Status register bits */ -#define MPMC_STATUS_BUSY ( 1 << 0 ) /* Busy */ -#define MPMC_STATUS_WBS ( 1 << 1 ) /* Write Buffer Status */ -#define MPMC_STATUS_SRA ( 1 << 2 ) /* Self-Refresh Acknowledge*/ +#define MPMC_STATUS_BUSY (1 << 0) /* Busy */ +#define MPMC_STATUS_WBS (1 << 1) /* Write Buffer Status */ +#define MPMC_STATUS_SRA (1 << 2) /* Self-Refresh Acknowledge*/ /* Dynamic Control register bits */ -#define MPMC_DC_CE ( 1 << 0 ) -#define MPMC_DC_DMC ( 1 << 1 ) -#define MPMC_DC_SRR ( 1 << 2 ) +#define MPMC_DC_CE (1 << 0) +#define MPMC_DC_DMC (1 << 1) +#define MPMC_DC_SRR (1 << 2) #define MPMC_DC_SI_SHIFT 7 -#define MPMC_DC_SI_MASK ( 3 << 7 ) -#define MPMC_DC_SI_NORMAL ( 0 << 7 ) -#define MPMC_DC_SI_MODE ( 1 << 7 ) -#define MPMC_DC_SI_PALL ( 2 << 7 ) -#define MPMC_DC_SI_NOP ( 3 << 7 ) +#define MPMC_DC_SI_MASK (3 << 7) +#define MPMC_DC_SI_NORMAL (0 << 7) +#define MPMC_DC_SI_MODE (1 << 7) +#define MPMC_DC_SI_PALL (2 << 7) +#define MPMC_DC_SI_NOP (3 << 7) #define SRAM_REG_CONF 0x00 #define SRAM_REG_WWE 0x04 diff --git a/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_nand.h b/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_nand.h index 636d27fecf..1e2f3bd15d 100644 --- a/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_nand.h +++ b/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_nand.h @@ -46,7 +46,7 @@ #define NAND_READ_REG(r) \ readb((void __iomem *)KSEG1ADDR(ADM5120_NAND_BASE) + (r)) #define NAND_WRITE_REG(r, v) \ - writeb((v),(void __iomem *)KSEG1ADDR(ADM5120_NAND_BASE) + (r)) + writeb((v), (void __iomem *)KSEG1ADDR(ADM5120_NAND_BASE) + (r)) /*-------------------------------------------------------------------------*/ diff --git a/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_platform.h b/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_platform.h index 9d2e430cd8..0159301d22 100644 --- a/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_platform.h +++ b/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_platform.h @@ -45,7 +45,7 @@ struct adm5120_pci_irq { unsigned irq; }; -#define PCIIRQ(s,f,p,i) {.slot = (s), .func = (f), .pin = (p), .irq = (i)} +#define PCIIRQ(s, f, p, i) {.slot = (s), .func = (f), .pin = (p), .irq = (i)} #ifdef CONFIG_PCI extern void adm5120_pci_set_irq_map(unsigned int nr_irqs, @@ -73,7 +73,7 @@ extern void adm5120_add_device_gpio_buttons(unsigned nbuttons, #define GPIO_LED_DEF(g, n, t, a) { \ .name = (n), \ - .default_trigger = (t), \ + .default_trigger = (t), \ .gpio = (g), \ .active_low = (a) \ } diff --git a/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_uart.h b/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_uart.h index 6308f6bd18..81d3067da3 100644 --- a/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_uart.h +++ b/target/linux/adm5120/files/arch/mips/include/asm/mach-adm5120/adm5120_uart.h @@ -27,38 +27,38 @@ #define UART_REG_FLAG 0x18 /* Receive Status Register bits */ -#define UART_RSR_FE ( 1 << 0 ) -#define UART_RSR_PE ( 1 << 1 ) -#define UART_RSR_BE ( 1 << 2 ) -#define UART_RSR_OE ( 1 << 3 ) -#define UART_RSR_ERR ( UART_RSR_FE | UART_RSR_PE | UART_RSR_BE ) +#define UART_RSR_FE (1 << 0) +#define UART_RSR_PE (1 << 1) +#define UART_RSR_BE (1 << 2) +#define UART_RSR_OE (1 << 3) +#define UART_RSR_ERR (UART_RSR_FE | UART_RSR_PE | UART_RSR_BE) #define UART_ECR_ALL 0xFF /* Line Control High register bits */ -#define UART_LCRH_BRK ( 1 << 0 ) /* send break */ -#define UART_LCRH_PEN ( 1 << 1 ) /* parity enable */ -#define UART_LCRH_EPS ( 1 << 2 ) /* even parity select */ -#define UART_LCRH_STP1 ( 0 << 3 ) /* one stop bits select */ -#define UART_LCRH_STP2 ( 1 << 3 ) /* two stop bits select */ -#define UART_LCRH_FEN ( 1 << 4 ) /* FIFO enable */ +#define UART_LCRH_BRK (1 << 0) /* send break */ +#define UART_LCRH_PEN (1 << 1) /* parity enable */ +#define UART_LCRH_EPS (1 << 2) /* even parity select */ +#define UART_LCRH_STP1 (0 << 3) /* one stop bits select */ +#define UART_LCRH_STP2 (1 << 3) /* two stop bits select */ +#define UART_LCRH_FEN (1 << 4) /* FIFO enable */ -#define UART_LCRH_WLEN5 ( 0 << 5 ) -#define UART_LCRH_WLEN6 ( 1 << 5 ) -#define UART_LCRH_WLEN7 ( 2 << 5 ) -#define UART_LCRH_WLEN8 ( 3 << 5 ) +#define UART_LCRH_WLEN5 (0 << 5) +#define UART_LCRH_WLEN6 (1 << 5) +#define UART_LCRH_WLEN7 (2 << 5) +#define UART_LCRH_WLEN8 (3 << 5) /* Control register bits */ -#define UART_CTRL_EN ( 1 << 0 ) +#define UART_CTRL_EN (1 << 0) /* Flag register bits */ -#define UART_FLAG_CTS ( 1 << 0 ) -#define UART_FLAG_DSR ( 1 << 1 ) -#define UART_FLAG_DCD ( 1 << 2 ) -#define UART_FLAG_BUSY ( 1 << 3 ) -#define UART_FLAG_RXFE ( 1 << 4 ) -#define UART_FLAG_TXFF ( 1 << 5 ) -#define UART_FLAG_RXFF ( 1 << 6 ) -#define UART_FLAG_TXFE ( 1 << 7 ) +#define UART_FLAG_CTS (1 << 0) +#define UART_FLAG_DSR (1 << 1) +#define UART_FLAG_DCD (1 << 2) +#define UART_FLAG_BUSY (1 << 3) +#define UART_FLAG_RXFE (1 << 4) +#define UART_FLAG_TXFF (1 << 5) +#define UART_FLAG_RXFF (1 << 6) +#define UART_FLAG_TXFE (1 << 7) #endif /* _MACH_ADM5120_UART_H */ diff --git a/target/linux/adm5120/files/arch/mips/pci/pci-adm5120.c b/target/linux/adm5120/files/arch/mips/pci/pci-adm5120.c index 0bef8048ff..86657ce841 100644 --- a/target/linux/adm5120/files/arch/mips/pci/pci-adm5120.c +++ b/target/linux/adm5120/files/arch/mips/pci/pci-adm5120.c @@ -21,12 +21,12 @@ #include <linux/init.h> #include <linux/spinlock.h> #include <linux/io.h> +#include <linux/delay.h> #include <linux/pci.h> #include <linux/pci_ids.h> #include <linux/pci_regs.h> -#include <asm/delay.h> #include <asm/bootinfo.h> #include <asm/mach-adm5120/adm5120_defs.h> @@ -71,8 +71,8 @@ static inline u32 read_cfgdata(void) static inline u32 mkaddr(struct pci_bus *bus, unsigned int devfn, int where) { - return (((bus->number & 0xFF) << 16) | ((devfn & 0xFF) << 8) | \ - (where & 0xFC)); + return ((bus->number & 0xFF) << 16) | ((devfn & 0xFF) << 8) | \ + (where & 0xFC); } /* -------------------------------------------------------------------------*/ |