From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marek Vasut Date: Fri, 20 Apr 2012 18:17:25 +0200 Subject: [U-Boot] [PATCH v3] Add support for MINI2440 (s3c2440). Documentation about the product can be found on: http://www.friendlyarm.net/products/mini2440 In-Reply-To: References: <20120416174633.GA7463@debian> Message-ID: <201204201817.25124.marex@denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Ilya Averyanov, > 2012/4/20 Ilya Averyanov > > > 2012/4/20 Marek Vasut > > > >> Dear Ilya Averyanov, > >> > >> > 2012/4/20 Marek Vasut > >> > > >> > > Dear Ilya Averyanov, > >> > > > >> > > [...] > >> > > > >> > > > > > > > > > .word 0x32 > >> > > > > > > > > > + .word 0x30 > >> > > > > > > > > > + .word 0x30 > >> > > > > > > > > > >> > > > > > > > > What this undocumented stuff? > >> > > > > > > > > >> > > > > > > > SoC specific, I pasted it from smdk2410, it's for > >> > > > > > > > initialize the > >> > > > > > >> > > > > DRAM. > >> > > > > > >> > > > > > > Can't you init DRAM in some more fitting place? Also > >> > > > > > > document this? > >> > > > > > > >> > > > > > I don't know, this part is a bit difficult for me, but I'm > >> > >> going to > >> > >> > > try > >> > > > >> > > > > > to document it with the help of the SoC documentation. > >> > > > > > > >> > > > > > For the place, should I move it to mini2440.c in > >> > >> arch_cpu_init() or > >> > >> > > > > > board_early_init_f() ? I don't really know the difference. > >> > > > > > >> > > > > dram_init() maybe ? > >> > > > > >> > > > You propose to initialize the SDRAM controller in dram_init ()? > >> > > > >> > > Well yes, ain't it more fitting ? > >> > > > >> > > Best regards, > >> > > Marek Vasut > >> > > >> > No. We have to two reasons why this is not the case. > >> > 1) Open u-boot/arch/arm/cpu/arm920t/start.S:328 > >> > cpu_init_crit > >> > ...... > >> > line 346 > >> > > >> > /* > >> > > >> > * before relocating, we have to setup RAM timing > >> > * because memory timing is board-dependend, you will > >> > * find a lowlevel_init.S in your board directory. > >> > */ > >> > >> Well don't setup run in lowlevel_init.S then ? > >> > >> > 2) NAND controller must be initialized before C code run. > >> > >> Why? > >> > >> Best regards, > >> Marek Vasut > > > > mmm... > > Because we need a stack. > > The stack is in RAM. > > > >2) NAND controller must be initialized before C code run. > > Sorry made ??a mistake. SDRAM! Not NAND! Which doesn't matter, either way you need stack ... and you can have the stack in cache ;-) Best regards, Marek Vasut