Skip to contentSkip to conversation

arm:at91-boards: remove console_init_f where unnecessary

PATCH New Andreas Bießmann 4 participants 6 messages Aug 16, 2012 – Sep 1, 2012 Arm/Microchip (AT91) SoC support

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 arm:at91-boards: remove console_init_f where unnecessary

A lot of at91 boards have the console_init_f in board_init. This is useless cause it was called before by generic code in lib/board.c.

cc Jens Scharsig <[email protected]>
cc Stelian Pop <[email protected]>
cc Sedji Gaouaou<[email protected]>
cc Albin Tonnerre <[email protected]>
cc Eric Benard <[email protected]>
---
 board/BuS/eb_cpux9k2/cpux9k2.c                  |    2 --
 board/BuS/vl_ma2sc/vl_ma2sc.c                   |    3 ---
 board/atmel/at91sam9261ek/at91sam9261ek.c       |    3 ---
 board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c |    3 ---
 board/atmel/at91sam9rlek/at91sam9rlek.c         |    3 ---
 board/calao/sbc35_a9g20/sbc35_a9g20.c           |    3 ---
 board/calao/tny_a9260/tny_a9260.c               |    3 ---
 board/eukrea/cpuat91/cpuat91.c                  |    2 --
 8 files changed, 22 deletions(-)
board/BuS/eb_cpux9k2/cpux9k2.c +0 -2
index 54f9b64..776226f 100644
@@ -59,8 +59,6 @@ DECLARE_GLOBAL_DATA_PTR;
 int board_init(void)
 {
 	at91_pio_t *pio	= (at91_pio_t *) ATMEL_BASE_PIO;
-	/* Enable Ctrlc */
-	console_init_f();
 
 	/* Correct IRDA resistor problem / Set PA23_TXD in Output */
 	writel(ATMEL_PMX_AA_TXD2, &pio->pioa.oer);
board/BuS/vl_ma2sc/vl_ma2sc.c +0 -3
index 62ed6fb..84b2060 100644
@@ -244,9 +244,6 @@ int board_init(void)
 	writel(pin, &pio->piod.odr);
 	writel(pin, &pio->piod.owdr);
 
-	/* Enable Ctrlc */
-	console_init_f();
-
 	gd->bd->bi_arch_number = MACH_TYPE_VL_MA2SC;
 	/* adress of boot parameters */
 	gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
board/atmel/at91sam9261ek/at91sam9261ek.c +0 -3
index 47ab839..d30a1ee 100644
@@ -242,9 +242,6 @@ void lcd_show_board_info(void)
 
 int board_init(void)
 {
-	/* Enable Ctrlc */
-	console_init_f();
-
 #ifdef CONFIG_AT91SAM9G10EK
 	/* arch number of AT91SAM9G10EK-Board */
 	gd->bd->bi_arch_number = MACH_TYPE_AT91SAM9G10EK;
board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c +0 -3
index 5a04274..d02312c 100644
@@ -258,9 +258,6 @@ int board_early_init_f(void)
 
 int board_init(void)
 {
-	/* Enable Ctrlc */
-	console_init_f();
-
 	/* arch number of AT91SAM9M10G45EK-Board */
 #ifdef CONFIG_AT91SAM9M10G45EK
 	gd->bd->bi_arch_number = MACH_TYPE_AT91SAM9M10G45EK;
board/atmel/at91sam9rlek/at91sam9rlek.c +0 -3
index ef0ddd7..e92ec6e 100644
@@ -192,9 +192,6 @@ int board_early_init_f(void)
 
 int board_init(void)
 {
-	/* Enable Ctrlc */
-	console_init_f();
-
 	/* arch number of AT91SAM9RLEK-Board */
 	gd->bd->bi_arch_number = MACH_TYPE_AT91SAM9RLEK;
 	/* adress of boot parameters */
board/calao/sbc35_a9g20/sbc35_a9g20.c +0 -3
index b6c8791..d3b3684 100644
@@ -149,9 +149,6 @@ static void sbc35_a9g20_macb_hw_init(void)
 
 int board_init(void)
 {
-	/* Enable Ctrlc */
-	console_init_f();
-
 	/* adress of boot parameters */
 	gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
 
board/calao/tny_a9260/tny_a9260.c +0 -3
index 31074d0..86e7e65 100644
@@ -83,9 +83,6 @@ static void tny_a9260_nand_hw_init(void)
 
 int board_init(void)
 {
-	/* Enable Ctrlc */
-	console_init_f();
-
 	/* adress of boot parameters */
 	gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
 
board/eukrea/cpuat91/cpuat91.c +0 -2
index f654f87..c74c3fc 100644
@@ -43,8 +43,6 @@ DECLARE_GLOBAL_DATA_PTR;
 
 int board_init(void)
 {
-	/* Enable Ctrlc */
-	console_init_f();
 	/* arch number of CPUAT91-Board */
 	gd->bd->bi_arch_number = MACH_TYPE_CPUAT91;
 	/* adress of boot parameters */
Signature · 1 line
1.7.10.4
#1 lore raw

PATCH 1/1 arm:at91-boards: remove console_init_f where unnecessary

Quoted 52 lines · Andreas Bie?mann

A lot of at91 boards have the console_init_f in board_init. This is useless cause it was called before by generic code in lib/board.c.

cc Jens Scharsig <[email protected]>
cc Stelian Pop <[email protected]>
cc Sedji Gaouaou<[email protected]>
cc Albin Tonnerre <[email protected]>
cc Eric Benard <[email protected]>
---
  board/BuS/eb_cpux9k2/cpux9k2.c                  |    2 --
  board/BuS/vl_ma2sc/vl_ma2sc.c                   |    3 ---
  board/atmel/at91sam9261ek/at91sam9261ek.c       |    3 ---
  board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c |    3 ---
  board/atmel/at91sam9rlek/at91sam9rlek.c         |    3 ---
  board/calao/sbc35_a9g20/sbc35_a9g20.c           |    3 ---
  board/calao/tny_a9260/tny_a9260.c               |    3 ---
  board/eukrea/cpuat91/cpuat91.c                  |    2 --
  8 files changed, 22 deletions(-)
board/BuS/eb_cpux9k2/cpux9k2.c +0 -2
index 54f9b64..776226f 100644
@@ -59,8 +59,6 @@ DECLARE_GLOBAL_DATA_PTR;
  int board_init(void)
  {
  	at91_pio_t *pio	= (at91_pio_t *) ATMEL_BASE_PIO;
-	/* Enable Ctrlc */
-	console_init_f();
 
  	/* Correct IRDA resistor problem / Set PA23_TXD in Output */
  	writel(ATMEL_PMX_AA_TXD2, &pio->pioa.oer);
board/BuS/vl_ma2sc/vl_ma2sc.c +0 -3
index 62ed6fb..84b2060 100644
@@ -244,9 +244,6 @@ int board_init(void)
  	writel(pin, &pio->piod.odr);
  	writel(pin, &pio->piod.owdr);
 
-	/* Enable Ctrlc */
-	console_init_f();
-
  	gd->bd->bi_arch_number = MACH_TYPE_VL_MA2SC;
  	/* adress of boot parameters */
  	gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
board/atmel/at91sam9261ek/at91sam9261ek.c +0 -0
index 47ab839..d30a1ee 100644

board/atmel/at91sam9261ek/at91sam9261ek.c void lcd_show_board_info(void) · line 247

Quoted 6 lines
board/atmel/at91sam9261ek/at91sam9261ek.c +0 -3
@@ -242,9 +242,6 @@ void lcd_show_board_info(void)
 
  int board_init(void)
  {
-	/* Enable Ctrlc */
-	console_init_f();
-

Tested on at91sam9g10ek board. It works well without this.

Quoted 8 lines
board/atmel/at91sam9261ek/at91sam9261ek.c +0 -0
  #ifdef CONFIG_AT91SAM9G10EK
  	/* arch number of AT91SAM9G10EK-Board */
  	gd->bd->bi_arch_number = MACH_TYPE_AT91SAM9G10EK;
board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c +0 -0
index 5a04274..d02312c 100644

board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c int board_early_init_f(void) · line 263

Quoted 6 lines
board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c +0 -3
@@ -258,9 +258,6 @@ int board_early_init_f(void)
 
  int board_init(void)
  {
-	/* Enable Ctrlc */
-	console_init_f();
-

Tested on at91sam9m10g45ek board. It works well without this.

Quoted 59 lines
board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c +0 -0
  	/* arch number of AT91SAM9M10G45EK-Board */
  #ifdef CONFIG_AT91SAM9M10G45EK
  	gd->bd->bi_arch_number = MACH_TYPE_AT91SAM9M10G45EK;
board/atmel/at91sam9rlek/at91sam9rlek.c +0 -3
index ef0ddd7..e92ec6e 100644
@@ -192,9 +192,6 @@ int board_early_init_f(void)
 
  int board_init(void)
  {
-	/* Enable Ctrlc */
-	console_init_f();
-
  	/* arch number of AT91SAM9RLEK-Board */
  	gd->bd->bi_arch_number = MACH_TYPE_AT91SAM9RLEK;
  	/* adress of boot parameters */
board/calao/sbc35_a9g20/sbc35_a9g20.c +0 -3
index b6c8791..d3b3684 100644
@@ -149,9 +149,6 @@ static void sbc35_a9g20_macb_hw_init(void)
 
  int board_init(void)
  {
-	/* Enable Ctrlc */
-	console_init_f();
-
  	/* adress of boot parameters */
  	gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
 
board/calao/tny_a9260/tny_a9260.c +0 -3
index 31074d0..86e7e65 100644
@@ -83,9 +83,6 @@ static void tny_a9260_nand_hw_init(void)
 
  int board_init(void)
  {
-	/* Enable Ctrlc */
-	console_init_f();
-
  	/* adress of boot parameters */
  	gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
 
board/eukrea/cpuat91/cpuat91.c +0 -2
index f654f87..c74c3fc 100644
@@ -43,8 +43,6 @@ DECLARE_GLOBAL_DATA_PTR;
 
  int board_init(void)
  {
-	/* Enable Ctrlc */
-	console_init_f();
  	/* arch number of CPUAT91-Board */
  	gd->bd->bi_arch_number = MACH_TYPE_CPUAT91;
  	/* adress of boot parameters */
#2 lore raw

PATCH 1/1 arm:at91-boards: remove console_init_f where unnecessary

Dear Bo Shen,

Am Dienstag, 21. August 2012 schrieb Bo Shen :

Quoted 59 lines · Andreas Bie?mann
Quoted 58 lines

A lot of at91 boards have the console_init_f in board_init. This is useless
cause it was called before by generic code in lib/board.c.

cc Jens Scharsig <[email protected]>
cc Stelian Pop <[email protected]>
cc Sedji Gaouaou<[email protected]>
cc Albin Tonnerre <[email protected]>
cc Eric Benard <[email protected]>
---
  board/BuS/eb_cpux9k2/cpux9k2.c                  |    2 --
  board/BuS/vl_ma2sc/vl_ma2sc.c                   |    3 ---
  board/atmel/at91sam9261ek/**at91sam9261ek.c       |    3 ---
  board/atmel/at91sam9m10g45ek/**at91sam9m10g45ek.c |    3 ---
  board/atmel/at91sam9rlek/**at91sam9rlek.c         |    3 ---
  board/calao/sbc35_a9g20/sbc35_**a9g20.c           |    3 ---
  board/calao/tny_a9260/tny_**a9260.c               |    3 ---
  board/eukrea/cpuat91/cpuat91.c                  |    2 --
  8 files changed, 22 deletions(-)
board/BuS/eb_cpux9k2/** renamed from board/BuS/eb_cpux9k2/**cpux9k2.c +0 -0

cpux9k2.c
index 54f9b64..776226f 100644

board/BuS/eb_cpux9k2/**cpux9k2.c +0 -2
@@ -59,8 +59,6 @@ DECLARE_GLOBAL_DATA_PTR;
  int board_init(void)
  {
        at91_pio_t *pio = (at91_pio_t *) ATMEL_BASE_PIO;
-       /* Enable Ctrlc */
-       console_init_f();
 
        /* Correct IRDA resistor problem / Set PA23_TXD in Output */
        writel(ATMEL_PMX_AA_TXD2, &pio->pioa.oer);
board/BuS/vl_ma2sc/vl_ma2sc.**c +0 -3
index 62ed6fb..84b2060 100644
@@ -244,9 +244,6 @@ int board_init(void)
        writel(pin, &pio->piod.odr);
        writel(pin, &pio->piod.owdr);
 
-       /* Enable Ctrlc */
-       console_init_f();
-
        gd->bd->bi_arch_number = MACH_TYPE_VL_MA2SC;
        /* adress of boot parameters */
        gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
board/atmel/at91sam9261ek/**at91sam9261ek.c +0 -0
index 47ab839..d30a1ee 100644
@@ -242,9 +242,6 @@ void lcd_show_board_info(void)
 
Quoted 10 lines

board/atmel/at91sam9261ek/**at91sam9261ek.c void lcd_show_board_info(void) · line 245

Quoted 6 lines
board/atmel/at91sam9261ek/**at91sam9261ek.c +0 -3
  int board_init(void)
  {
-       /* Enable Ctrlc */
-       console_init_f();
-
 

Tested on at91sam9g10ek board. It works well without this.

FYI: If you had used the well known git 'tag' Tested-by this would be added automagically to patchworks patch. Please read
http://www.denx.de/wiki/view/U-Boot/Patches#Review_Process_Git_Tags
However, thanks for your test report.

Best regards

Andreas Bie?mann

Quoted 1 line
#3 lore raw

PATCH 1/1 arm:at91-boards: remove console_init_f where unnecessary

In reply to Andreas Bießmann

Hi Andreas,

Quoted 52 lines · Andreas Bie?mann

A lot of at91 boards have the console_init_f in board_init. This is useless cause it was called before by generic code in lib/board.c.

cc Jens Scharsig <[email protected]>
cc Stelian Pop <[email protected]>
cc Sedji Gaouaou<[email protected]>
cc Albin Tonnerre <[email protected]>
cc Eric Benard <[email protected]>
---
  board/BuS/eb_cpux9k2/cpux9k2.c                  |    2 --
  board/BuS/vl_ma2sc/vl_ma2sc.c                   |    3 ---
  board/atmel/at91sam9261ek/at91sam9261ek.c       |    3 ---
  board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c |    3 ---
  board/atmel/at91sam9rlek/at91sam9rlek.c         |    3 ---
  board/calao/sbc35_a9g20/sbc35_a9g20.c           |    3 ---
  board/calao/tny_a9260/tny_a9260.c               |    3 ---
  board/eukrea/cpuat91/cpuat91.c                  |    2 --
  8 files changed, 22 deletions(-)
board/BuS/eb_cpux9k2/cpux9k2.c +0 -2
index 54f9b64..776226f 100644
@@ -59,8 +59,6 @@ DECLARE_GLOBAL_DATA_PTR;
  int board_init(void)
  {
  	at91_pio_t *pio	= (at91_pio_t *) ATMEL_BASE_PIO;
-	/* Enable Ctrlc */
-	console_init_f();
 
  	/* Correct IRDA resistor problem / Set PA23_TXD in Output */
  	writel(ATMEL_PMX_AA_TXD2, &pio->pioa.oer);
board/BuS/vl_ma2sc/vl_ma2sc.c +0 -3
index 62ed6fb..84b2060 100644
@@ -244,9 +244,6 @@ int board_init(void)
  	writel(pin, &pio->piod.odr);
  	writel(pin, &pio->piod.owdr);
 
-	/* Enable Ctrlc */
-	console_init_f();
-
  	gd->bd->bi_arch_number = MACH_TYPE_VL_MA2SC;
  	/* adress of boot parameters */
  	gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
board/atmel/at91sam9261ek/at91sam9261ek.c +0 -0
index 47ab839..d30a1ee 100644

board/atmel/at91sam9261ek/at91sam9261ek.c void lcd_show_board_info(void) · line 247

Quoted 6 lines
board/atmel/at91sam9261ek/at91sam9261ek.c +0 -3
@@ -242,9 +242,6 @@ void lcd_show_board_info(void)
 
  int board_init(void)
  {
-	/* Enable Ctrlc */
-	console_init_f();
-

Tested on at91sam9g10ek board. It works well without this.

Tested-by voice.shen at atmel.com
Quoted 8 lines
board/atmel/at91sam9261ek/at91sam9261ek.c +0 -0
  #ifdef CONFIG_AT91SAM9G10EK
  	/* arch number of AT91SAM9G10EK-Board */
  	gd->bd->bi_arch_number = MACH_TYPE_AT91SAM9G10EK;
board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c +0 -0
index 5a04274..d02312c 100644

board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c int board_early_init_f(void) · line 263

Quoted 6 lines
board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c +0 -3
@@ -258,9 +258,6 @@ int board_early_init_f(void)
 
  int board_init(void)
  {
-	/* Enable Ctrlc */
-	console_init_f();
-

Tested on at91sam9m10g45ek board. It works well without this.

Tested-by voice.shen at atmel.com
Quoted 59 lines
board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c +0 -0
  	/* arch number of AT91SAM9M10G45EK-Board */
  #ifdef CONFIG_AT91SAM9M10G45EK
  	gd->bd->bi_arch_number = MACH_TYPE_AT91SAM9M10G45EK;
board/atmel/at91sam9rlek/at91sam9rlek.c +0 -3
index ef0ddd7..e92ec6e 100644
@@ -192,9 +192,6 @@ int board_early_init_f(void)
 
  int board_init(void)
  {
-	/* Enable Ctrlc */
-	console_init_f();
-
  	/* arch number of AT91SAM9RLEK-Board */
  	gd->bd->bi_arch_number = MACH_TYPE_AT91SAM9RLEK;
  	/* adress of boot parameters */
board/calao/sbc35_a9g20/sbc35_a9g20.c +0 -3
index b6c8791..d3b3684 100644
@@ -149,9 +149,6 @@ static void sbc35_a9g20_macb_hw_init(void)
 
  int board_init(void)
  {
-	/* Enable Ctrlc */
-	console_init_f();
-
  	/* adress of boot parameters */
  	gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
 
board/calao/tny_a9260/tny_a9260.c +0 -3
index 31074d0..86e7e65 100644
@@ -83,9 +83,6 @@ static void tny_a9260_nand_hw_init(void)
 
  int board_init(void)
  {
-	/* Enable Ctrlc */
-	console_init_f();
-
  	/* adress of boot parameters */
  	gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
 
board/eukrea/cpuat91/cpuat91.c +0 -2
index f654f87..c74c3fc 100644
@@ -43,8 +43,6 @@ DECLARE_GLOBAL_DATA_PTR;
 
  int board_init(void)
  {
-	/* Enable Ctrlc */
-	console_init_f();
  	/* arch number of CPUAT91-Board */
  	gd->bd->bi_arch_number = MACH_TYPE_CPUAT91;
  	/* adress of boot parameters */
#4 lore raw

PATCH 1/1 arm:at91-boards: remove console_init_f where unnecessary

In reply to Andreas Bießmann
Quoted 4 lines

A lot of at91 boards have the console_init_f in board_init. This is useless cause it was called before by generic code in lib/board.c.

I have successfully tested this patch for eb_cpux9k2 and vl_ma2sc, so:

#5 lore raw

PATCH 1/1 arm:at91-boards: remove console_init_f where unnecessary

In reply to Andreas Bießmann

Dear Andreas Bie?mann,

Quoted 10 lines · Andreas Bie?mann

A lot of at91 boards have the console_init_f in board_init. This is useless cause it was called before by generic code in lib/board.c.

cc Jens Scharsig <[email protected]>
cc Stelian Pop <[email protected]>
cc Sedji Gaouaou<[email protected]>
cc Albin Tonnerre <[email protected]>
cc Eric Benard <[email protected]>

---

applied to u-boot-atmel/master, thanks!

Best regards

Andreas Bie?mann