Commit 99121c0d authored by Vitaly Bordug's avatar Vitaly Bordug Committed by Linus Torvalds

powerpc: 8xx: fix whitespace and indentation

Rolling forward PCMCIA driver, it was discovered that the indentation in
existing one, as well as in BSP side are very odd.  This patch is just result
of Lindent run ontop of culprit files.
Signed-off-by: default avatarVitaly Bordug <vitb@kernel.crashing.org>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Olof Johansson <olof@lixom.net>
Cc: Dominik Brodowski <linux@dominikbrodowski.net>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Kumar Gala <galak@gate.crashing.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 2a7326b5
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
#include <asm/prom.h> #include <asm/prom.h>
extern void cpm_reset(void); extern void cpm_reset(void);
extern void mpc8xx_show_cpuinfo(struct seq_file*); extern void mpc8xx_show_cpuinfo(struct seq_file *);
extern void mpc8xx_restart(char *cmd); extern void mpc8xx_restart(char *cmd);
extern void mpc8xx_calibrate_decr(void); extern void mpc8xx_calibrate_decr(void);
extern int mpc8xx_set_rtc_time(struct rtc_time *tm); extern int mpc8xx_set_rtc_time(struct rtc_time *tm);
...@@ -48,9 +48,9 @@ extern void mpc8xx_get_rtc_time(struct rtc_time *tm); ...@@ -48,9 +48,9 @@ extern void mpc8xx_get_rtc_time(struct rtc_time *tm);
extern void m8xx_pic_init(void); extern void m8xx_pic_init(void);
extern unsigned int mpc8xx_get_irq(void); extern unsigned int mpc8xx_get_irq(void);
static void init_smc1_uart_ioports(struct fs_uart_platform_info* fpi); static void init_smc1_uart_ioports(struct fs_uart_platform_info *fpi);
static void init_smc2_uart_ioports(struct fs_uart_platform_info* fpi); static void init_smc2_uart_ioports(struct fs_uart_platform_info *fpi);
static void init_scc3_ioports(struct fs_platform_info* ptr); static void init_scc3_ioports(struct fs_platform_info *ptr);
#ifdef CONFIG_PCMCIA_M8XX #ifdef CONFIG_PCMCIA_M8XX
static void pcmcia_hw_setup(int slot, int enable) static void pcmcia_hw_setup(int slot, int enable)
...@@ -73,7 +73,7 @@ static int pcmcia_set_voltage(int slot, int vcc, int vpp) ...@@ -73,7 +73,7 @@ static int pcmcia_set_voltage(int slot, int vcc, int vpp)
bcsr_io = ioremap(BCSR1, sizeof(unsigned long)); bcsr_io = ioremap(BCSR1, sizeof(unsigned long));
switch(vcc) { switch (vcc) {
case 0: case 0:
break; break;
case 33: case 33:
...@@ -86,12 +86,12 @@ static int pcmcia_set_voltage(int slot, int vcc, int vpp) ...@@ -86,12 +86,12 @@ static int pcmcia_set_voltage(int slot, int vcc, int vpp)
return 1; return 1;
} }
switch(vpp) { switch (vpp) {
case 0: case 0:
break; break;
case 33: case 33:
case 50: case 50:
if(vcc == vpp) if (vcc == vpp)
reg |= BCSR1_PCCVPP1; reg |= BCSR1_PCCVPP1;
else else
return 1; return 1;
...@@ -127,7 +127,7 @@ void __init mpc885ads_board_setup(void) ...@@ -127,7 +127,7 @@ void __init mpc885ads_board_setup(void)
#endif #endif
bcsr_io = ioremap(BCSR1, sizeof(unsigned long)); bcsr_io = ioremap(BCSR1, sizeof(unsigned long));
cp = (cpm8xx_t *)immr_map(im_cpm); cp = (cpm8xx_t *) immr_map(im_cpm);
if (bcsr_io == NULL) { if (bcsr_io == NULL) {
printk(KERN_CRIT "Could not remap BCSR\n"); printk(KERN_CRIT "Could not remap BCSR\n");
...@@ -140,13 +140,13 @@ void __init mpc885ads_board_setup(void) ...@@ -140,13 +140,13 @@ void __init mpc885ads_board_setup(void)
out_8(&(cp->cp_smc[0].smc_smcm), tmpval8); out_8(&(cp->cp_smc[0].smc_smcm), tmpval8);
clrbits16(&cp->cp_smc[0].smc_smcmr, SMCMR_REN | SMCMR_TEN); /* brg1 */ clrbits16(&cp->cp_smc[0].smc_smcmr, SMCMR_REN | SMCMR_TEN); /* brg1 */
#else #else
setbits32(bcsr_io,BCSR1_RS232EN_1); setbits32(bcsr_io, BCSR1_RS232EN_1);
out_be16(&cp->cp_smc[0].smc_smcmr, 0); out_be16(&cp->cp_smc[0].smc_smcmr, 0);
out_8(&cp->cp_smc[0].smc_smce, 0); out_8(&cp->cp_smc[0].smc_smce, 0);
#endif #endif
#ifdef CONFIG_SERIAL_CPM_SMC2 #ifdef CONFIG_SERIAL_CPM_SMC2
clrbits32(bcsr_io,BCSR1_RS232EN_2); clrbits32(bcsr_io, BCSR1_RS232EN_2);
clrbits32(&cp->cp_simode, 0xe0000000 >> 1); clrbits32(&cp->cp_simode, 0xe0000000 >> 1);
setbits32(&cp->cp_simode, 0x20000000 >> 1); /* brg2 */ setbits32(&cp->cp_simode, 0x20000000 >> 1); /* brg2 */
tmpval8 = in_8(&(cp->cp_smc[1].smc_smcm)) | (SMCM_RX | SMCM_TX); tmpval8 = in_8(&(cp->cp_smc[1].smc_smcm)) | (SMCM_RX | SMCM_TX);
...@@ -155,7 +155,7 @@ void __init mpc885ads_board_setup(void) ...@@ -155,7 +155,7 @@ void __init mpc885ads_board_setup(void)
init_smc2_uart_ioports(0); init_smc2_uart_ioports(0);
#else #else
setbits32(bcsr_io,BCSR1_RS232EN_2); setbits32(bcsr_io, BCSR1_RS232EN_2);
out_be16(&cp->cp_smc[1].smc_smcmr, 0); out_be16(&cp->cp_smc[1].smc_smcmr, 0);
out_8(&cp->cp_smc[1].smc_smce, 0); out_8(&cp->cp_smc[1].smc_smce, 0);
#endif #endif
...@@ -164,16 +164,16 @@ void __init mpc885ads_board_setup(void) ...@@ -164,16 +164,16 @@ void __init mpc885ads_board_setup(void)
#ifdef CONFIG_FS_ENET #ifdef CONFIG_FS_ENET
/* use MDC for MII (common) */ /* use MDC for MII (common) */
io_port = (iop8xx_t*)immr_map(im_ioport); io_port = (iop8xx_t *) immr_map(im_ioport);
setbits16(&io_port->iop_pdpar, 0x0080); setbits16(&io_port->iop_pdpar, 0x0080);
clrbits16(&io_port->iop_pddir, 0x0080); clrbits16(&io_port->iop_pddir, 0x0080);
bcsr_io = ioremap(BCSR5, sizeof(unsigned long)); bcsr_io = ioremap(BCSR5, sizeof(unsigned long));
clrbits32(bcsr_io,BCSR5_MII1_EN); clrbits32(bcsr_io, BCSR5_MII1_EN);
clrbits32(bcsr_io,BCSR5_MII1_RST); clrbits32(bcsr_io, BCSR5_MII1_RST);
#ifndef CONFIG_FC_ENET_HAS_SCC #ifndef CONFIG_FC_ENET_HAS_SCC
clrbits32(bcsr_io,BCSR5_MII2_EN); clrbits32(bcsr_io, BCSR5_MII2_EN);
clrbits32(bcsr_io,BCSR5_MII2_RST); clrbits32(bcsr_io, BCSR5_MII2_RST);
#endif #endif
iounmap(bcsr_io); iounmap(bcsr_io);
...@@ -182,17 +182,16 @@ void __init mpc885ads_board_setup(void) ...@@ -182,17 +182,16 @@ void __init mpc885ads_board_setup(void)
#endif #endif
#ifdef CONFIG_PCMCIA_M8XX #ifdef CONFIG_PCMCIA_M8XX
/*Set up board specific hook-ups*/ /*Set up board specific hook-ups */
m8xx_pcmcia_ops.hw_ctrl = pcmcia_hw_setup; m8xx_pcmcia_ops.hw_ctrl = pcmcia_hw_setup;
m8xx_pcmcia_ops.voltage_set = pcmcia_set_voltage; m8xx_pcmcia_ops.voltage_set = pcmcia_set_voltage;
#endif #endif
} }
static void init_fec1_ioports(struct fs_platform_info *ptr)
static void init_fec1_ioports(struct fs_platform_info* ptr)
{ {
cpm8xx_t *cp = (cpm8xx_t *)immr_map(im_cpm); cpm8xx_t *cp = (cpm8xx_t *) immr_map(im_cpm);
iop8xx_t *io_port = (iop8xx_t *)immr_map(im_ioport); iop8xx_t *io_port = (iop8xx_t *) immr_map(im_ioport);
/* configure FEC1 pins */ /* configure FEC1 pins */
setbits16(&io_port->iop_papar, 0xf830); setbits16(&io_port->iop_papar, 0xf830);
...@@ -214,11 +213,10 @@ static void init_fec1_ioports(struct fs_platform_info* ptr) ...@@ -214,11 +213,10 @@ static void init_fec1_ioports(struct fs_platform_info* ptr)
immr_unmap(cp); immr_unmap(cp);
} }
static void init_fec2_ioports(struct fs_platform_info *ptr)
static void init_fec2_ioports(struct fs_platform_info* ptr)
{ {
cpm8xx_t *cp = (cpm8xx_t *)immr_map(im_cpm); cpm8xx_t *cp = (cpm8xx_t *) immr_map(im_cpm);
iop8xx_t *io_port = (iop8xx_t *)immr_map(im_ioport); iop8xx_t *io_port = (iop8xx_t *) immr_map(im_ioport);
/* configure FEC2 pins */ /* configure FEC2 pins */
setbits32(&cp->cp_pepar, 0x0003fffc); setbits32(&cp->cp_pepar, 0x0003fffc);
...@@ -248,15 +246,15 @@ void init_fec_ioports(struct fs_platform_info *fpi) ...@@ -248,15 +246,15 @@ void init_fec_ioports(struct fs_platform_info *fpi)
} }
} }
static void init_scc3_ioports(struct fs_platform_info* fpi) static void init_scc3_ioports(struct fs_platform_info *fpi)
{ {
unsigned *bcsr_io; unsigned *bcsr_io;
iop8xx_t *io_port; iop8xx_t *io_port;
cpm8xx_t *cp; cpm8xx_t *cp;
bcsr_io = ioremap(BCSR_ADDR, BCSR_SIZE); bcsr_io = ioremap(BCSR_ADDR, BCSR_SIZE);
io_port = (iop8xx_t *)immr_map(im_ioport); io_port = (iop8xx_t *) immr_map(im_ioport);
cp = (cpm8xx_t *)immr_map(im_cpm); cp = (cpm8xx_t *) immr_map(im_cpm);
if (bcsr_io == NULL) { if (bcsr_io == NULL) {
printk(KERN_CRIT "Could not remap BCSR\n"); printk(KERN_CRIT "Could not remap BCSR\n");
...@@ -265,9 +263,9 @@ static void init_scc3_ioports(struct fs_platform_info* fpi) ...@@ -265,9 +263,9 @@ static void init_scc3_ioports(struct fs_platform_info* fpi)
/* Enable the PHY. /* Enable the PHY.
*/ */
clrbits32(bcsr_io+4, BCSR4_ETH10_RST); clrbits32(bcsr_io + 4, BCSR4_ETH10_RST);
udelay(1000); udelay(1000);
setbits32(bcsr_io+4, BCSR4_ETH10_RST); setbits32(bcsr_io + 4, BCSR4_ETH10_RST);
/* Configure port A pins for Txd and Rxd. /* Configure port A pins for Txd and Rxd.
*/ */
setbits16(&io_port->iop_papar, PA_ENET_RXD | PA_ENET_TXD); setbits16(&io_port->iop_papar, PA_ENET_RXD | PA_ENET_TXD);
...@@ -283,8 +281,7 @@ static void init_scc3_ioports(struct fs_platform_info* fpi) ...@@ -283,8 +281,7 @@ static void init_scc3_ioports(struct fs_platform_info* fpi)
*/ */
setbits32(&cp->cp_pepar, PE_ENET_TCLK | PE_ENET_RCLK); setbits32(&cp->cp_pepar, PE_ENET_TCLK | PE_ENET_RCLK);
clrbits32(&cp->cp_pepar, PE_ENET_TENA); clrbits32(&cp->cp_pepar, PE_ENET_TENA);
clrbits32(&cp->cp_pedir, clrbits32(&cp->cp_pedir, PE_ENET_TCLK | PE_ENET_RCLK | PE_ENET_TENA);
PE_ENET_TCLK | PE_ENET_RCLK | PE_ENET_TENA);
clrbits32(&cp->cp_peso, PE_ENET_TCLK | PE_ENET_RCLK); clrbits32(&cp->cp_peso, PE_ENET_TCLK | PE_ENET_RCLK);
setbits32(&cp->cp_peso, PE_ENET_TENA); setbits32(&cp->cp_peso, PE_ENET_TENA);
...@@ -308,7 +305,7 @@ static void init_scc3_ioports(struct fs_platform_info* fpi) ...@@ -308,7 +305,7 @@ static void init_scc3_ioports(struct fs_platform_info* fpi)
clrbits32(&cp->cp_pedir, PE_ENET_TENA); clrbits32(&cp->cp_pedir, PE_ENET_TENA);
setbits32(&cp->cp_peso, PE_ENET_TENA); setbits32(&cp->cp_peso, PE_ENET_TENA);
setbits32(bcsr_io+4, BCSR1_ETHEN); setbits32(bcsr_io + 4, BCSR1_ETHEN);
iounmap(bcsr_io); iounmap(bcsr_io);
immr_unmap(io_port); immr_unmap(io_port);
immr_unmap(cp); immr_unmap(cp);
...@@ -328,14 +325,12 @@ void init_scc_ioports(struct fs_platform_info *fpi) ...@@ -328,14 +325,12 @@ void init_scc_ioports(struct fs_platform_info *fpi)
} }
} }
static void init_smc1_uart_ioports(struct fs_uart_platform_info *ptr)
static void init_smc1_uart_ioports(struct fs_uart_platform_info* ptr)
{ {
unsigned *bcsr_io; unsigned *bcsr_io;
cpm8xx_t *cp; cpm8xx_t *cp;
cp = (cpm8xx_t *)immr_map(im_cpm); cp = (cpm8xx_t *) immr_map(im_cpm);
setbits32(&cp->cp_pepar, 0x000000c0); setbits32(&cp->cp_pepar, 0x000000c0);
clrbits32(&cp->cp_pedir, 0x000000c0); clrbits32(&cp->cp_pedir, 0x000000c0);
clrbits32(&cp->cp_peso, 0x00000040); clrbits32(&cp->cp_peso, 0x00000040);
...@@ -348,16 +343,16 @@ static void init_smc1_uart_ioports(struct fs_uart_platform_info* ptr) ...@@ -348,16 +343,16 @@ static void init_smc1_uart_ioports(struct fs_uart_platform_info* ptr)
printk(KERN_CRIT "Could not remap BCSR1\n"); printk(KERN_CRIT "Could not remap BCSR1\n");
return; return;
} }
clrbits32(bcsr_io,BCSR1_RS232EN_1); clrbits32(bcsr_io, BCSR1_RS232EN_1);
iounmap(bcsr_io); iounmap(bcsr_io);
} }
static void init_smc2_uart_ioports(struct fs_uart_platform_info* fpi) static void init_smc2_uart_ioports(struct fs_uart_platform_info *fpi)
{ {
unsigned *bcsr_io; unsigned *bcsr_io;
cpm8xx_t *cp; cpm8xx_t *cp;
cp = (cpm8xx_t *)immr_map(im_cpm); cp = (cpm8xx_t *) immr_map(im_cpm);
setbits32(&cp->cp_pepar, 0x00000c00); setbits32(&cp->cp_pepar, 0x00000c00);
clrbits32(&cp->cp_pedir, 0x00000c00); clrbits32(&cp->cp_pedir, 0x00000c00);
clrbits32(&cp->cp_peso, 0x00000400); clrbits32(&cp->cp_peso, 0x00000400);
...@@ -370,7 +365,7 @@ static void init_smc2_uart_ioports(struct fs_uart_platform_info* fpi) ...@@ -370,7 +365,7 @@ static void init_smc2_uart_ioports(struct fs_uart_platform_info* fpi)
printk(KERN_CRIT "Could not remap BCSR1\n"); printk(KERN_CRIT "Could not remap BCSR1\n");
return; return;
} }
clrbits32(bcsr_io,BCSR1_RS232EN_2); clrbits32(bcsr_io, BCSR1_RS232EN_2);
iounmap(bcsr_io); iounmap(bcsr_io);
} }
...@@ -444,15 +439,11 @@ static int __init mpc885ads_probe(void) ...@@ -444,15 +439,11 @@ static int __init mpc885ads_probe(void)
return 1; return 1;
} }
define_machine(mpc885_ads) { define_machine(mpc885_ads)
.name = "MPC885 ADS", {
.probe = mpc885ads_probe, .name = "MPC885 ADS",.probe = mpc885ads_probe,.setup_arch =
.setup_arch = mpc885ads_setup_arch, mpc885ads_setup_arch,.init_IRQ =
.init_IRQ = m8xx_pic_init, m8xx_pic_init,.show_cpuinfo = mpc8xx_show_cpuinfo,.get_irq =
.show_cpuinfo = mpc8xx_show_cpuinfo, mpc8xx_get_irq,.restart = mpc8xx_restart,.calibrate_decr =
.get_irq = mpc8xx_get_irq, mpc8xx_calibrate_decr,.set_rtc_time =
.restart = mpc8xx_restart, mpc8xx_set_rtc_time,.get_rtc_time = mpc8xx_get_rtc_time,};
.calibrate_decr = mpc8xx_calibrate_decr,
.set_rtc_time = mpc8xx_set_rtc_time,
.get_rtc_time = mpc8xx_get_rtc_time,
};
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment