public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Mark Jackson <mpfj-list@mimc.co.uk>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/1 v2] Setup extra MIMC200 chip selects
Date: Fri, 13 Feb 2009 15:48:18 +0000	[thread overview]
Message-ID: <49959642.5070304@mimc.co.uk> (raw)

Added code to setup the extra Flash and FRAM chip selects as used on the 
MIMC200 board.

V2 moves the init code from the common "cpu.c" file into the board specific 
setup file.

Signed-off-by: Mark Jackson <mpfj@mimc.co.uk>
---
  board/mimc/mimc200/mimc200.c |   14 ++++++++++++++
  1 files changed, 14 insertions(+), 0 deletions(-)

diff --git a/board/mimc/mimc200/mimc200.c b/board/mimc/mimc200/mimc200.c
index 8516dcb..423238b 100644
--- a/board/mimc/mimc200/mimc200.c
+++ b/board/mimc/mimc200/mimc200.c
@@ -29,6 +29,8 @@
  #include <asm/arch/hmatrix.h>
  #include <lcd.h>

+#include "../../../cpu/at32ap/hsmc3.h"
+
  #define SM_PM_GCCTRL				0x0060

  DECLARE_GLOBAL_DATA_PTR;
@@ -98,6 +100,18 @@ int board_early_init_f(void)
  	/* release phys reset */
  	gpio_set_value(GPIO_PIN_PC18, 0);	/* PHY RESET (Release)	*/

+	/* setup Data Flash chip select (NCS2) */
+	hsmc3_writel(MODE2, 0x20121003);
+	hsmc3_writel(CYCLE2, 0x000a0009);
+	hsmc3_writel(PULSE2, 0x0a060806);
+	hsmc3_writel(SETUP2, 0x00030102);
+
+	/* setup FRAM chip select (NCS3) */
+	hsmc3_writel(MODE3, 0x10120001);
+	hsmc3_writel(CYCLE3, 0x001e001d);
+	hsmc3_writel(PULSE3, 0x08040704);
+	hsmc3_writel(SETUP3, 0x02050204);
+
  #if defined(CONFIG_MACB)
  	/* init macb0 pins */
  	gpio_select_periph_A(GPIO_PIN_PC3,  0);	/* TXD0	*/

             reply	other threads:[~2009-02-13 15:48 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-13 15:48 Mark Jackson [this message]
2009-02-23 10:18 ` [U-Boot] [PATCH 1/1 v2] Setup extra MIMC200 chip selects Haavard Skinnemoen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=49959642.5070304@mimc.co.uk \
    --to=mpfj-list@mimc.co.uk \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox