From mboxrd@z Thu Jan 1 00:00:00 1970 From: Igor Grinberg Date: Wed, 02 Nov 2011 11:32:09 +0200 Subject: [U-Boot] [PATCH v2] at91: Add support for Bluewater Systems Snapper 9G45 module In-Reply-To: <1320160968-3954-1-git-send-email-sglass@bluewatersys.com> References: <1319339348-2959-1-git-send-email-sglass@bluewatersys.com> <1320160968-3954-1-git-send-email-sglass@bluewatersys.com> Message-ID: <4EB10E19.2010805@compulab.co.il> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Simon, On 11/01/11 17:22, Simon Glass wrote: > Snapper 9G45 is a ARM9-based CPU module with 1GB NAND and 128MB > DDR SDRAM. This patch includes NAND and Ethernet support. > > Signed-off-by: Simon Glass > --- > Changes in v2: > - Removed unneeded i2c config > - Added machine type define > > board/bluewater/snapper9g45/Makefile | 43 +++++++ > board/bluewater/snapper9g45/snapper9g45.c | 155 ++++++++++++++++++++++++ > boards.cfg | 1 + > include/configs/snapper9g45.h | 185 +++++++++++++++++++++++++++++ > 4 files changed, 384 insertions(+), 0 deletions(-) > create mode 100644 board/bluewater/snapper9g45/Makefile > create mode 100644 board/bluewater/snapper9g45/snapper9g45.c > create mode 100644 include/configs/snapper9g45.h [...] > diff --git a/board/bluewater/snapper9g45/snapper9g45.c b/board/bluewater/snapper9g45/snapper9g45.c > new file mode 100644 > index 0000000..f057e59 > --- /dev/null > +++ b/board/bluewater/snapper9g45/snapper9g45.c [...] > + > +int board_init(void) > +{ > + struct at91_pmc *pmc = (struct at91_pmc *)ATMEL_BASE_PMC; > + > + /* Enable PIO clocks */ > + writel((1 << ATMEL_ID_PIOA) | > + (1 << ATMEL_ID_PIOB) | > + (1 << ATMEL_ID_PIOC | > + (1 << ATMEL_ID_PIODE)), &pmc->pcer); > + > + gd->bd->bi_arch_number = MACH_TYPE_SNAPPER9G45; Please, use common code facilities (check CONFIG_MACH_TYPE in README). > + > + /* Address of boot parameters */ > + gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100; > + > + /* Initialise peripherals */ > + at91_seriald_hw_init(); > + i2c_init(CONFIG_SYS_I2C_SPEED, CONFIG_SYS_I2C_SLAVE); Why do you need the additional i2c_init() call here? It is already called in the init_sequence[] array. > + nand_hw_init(); > + > + macb_hw_init(); > + > + return 0; > +} > + [...] -- Regards, Igor.