On Thu, Jan 24, 2002 at 04:25:59PM +0100, Anoulak Kictiraz wrote:
> I'm trying to port linux into Roger-Board, but i don't know why linux not 
> booting on this board.would somebody help me with some hints and tips about 
> porting ?.
> I'm using linux 2.4.17 kernel with patch 2.4.17-rmk3. The Roger-board have 
> following feature:
> SA1110 cpu stepping 4
> 64 MB SDRAM samsung
> 32 MB StrataFlash memory (2 * 28F128J3A,with 16 bit data width, on modules 
> with one flash memory bank)
> JTag Interface
> LCD Hitachi
> 3 Serial Ports
> ....
> I have port the bootloader blob-2.0.5-pre2 on the Roger and it works 
> fein!(i think),

I'm always willing to include your port in the current blob CVS tree.

> it can download kernel and ramdisk images, than write to 
> flash memory. when i give the kommand "boot", i see following messages on 
> the console and the system hang up:
> 
> Starting kernel ...
> 
> Uncompressing Linux........................... done, booting the kernel.
> 
> 
> I have copy the file nanoengine.c to roger.c and modified the code as 
> follow:
> 
> static void __init
> fixup_roger(struct machine_desc *desc, struct param_struct *params,
>                char **cmdline, struct meminfo *mi)
> {
>       SET_BANK( 0, 0xc0000000, 32*1024*1024 );
>       SET_BANK( 1, 0xc8000000, 32*1024*1024 );
>       mi->nr_banks = 2;

You don't need that, blob will tell the kernel about the memory setup.

>       ROOT_DEV = MKDEV(RAMDISK_MAJOR,0);
>       setup_ramdisk( 1, 0, 0, 8192 );
>       setup_initrd( __phys_to_virt(0xc0800000), 4*1024*1024 );
>       //setup_initrd(0xc0800000, 4*1024*1024 );

Same over here, blob will tell the kernel about the ramdisk.

>       /* Get command line parameters passed from the loader (if any) */
>       if( *((char*)0xc0000100) )
>               *cmdline = ((char *)0xc0000100);

Ehm, that's not the way to do it, blob passes ATAG nodes to the kernel,
not a cmdline. This will fail.

> }

You actually don't need a fixup function at all because blob gives the
kernel all information it needs.

> static struct map_desc roger_io_desc[] __initdata = {
> /* virtual     physical    length      domain     r  w  c  b */
>  { 0xe8000000, 0x00000000, 0x02000000, DOMAIN_IO, 1, 1, 0, 0 }, /* Flash 
> bank 0 */
>  LAST_DESC
> };
> 
> static void __init roger_map_io(void)
> {
>       sa1100_map_io();
>       iotable_init(roger_io_desc);
> 
>       sa1100_register_uart(0, 1);
>       sa1100_register_uart(1, 2);
>       sa1100_register_uart(2, 3);
>       Ser1SDCR0 |= SDCR0_UART;

Already fixed up in blob.

>       /* disable IRDA -- UART2 is used as a normal serial port */
>       Ser2UTCR4=0;
>       Ser2HSCR0 = 0;

Not necessary, UART2 defaults to RS232.

> }
> 
> MACHINE_START(ROGER, "Roger SD")
>       BOOT_MEM(0xc0000000, 0x80000000, 0xf8000000)
>       FIXUP(fixup_roger)

Remove the FIXUP() line and add:

        BOOT_PARAMS(0xc0000100)

>       MAPIO(roger_map_io)
>       INITIRQ(sa1100_init_irq)
> MACHINE_END
> Memory map on Roger:
> 
> 0x0000 0000       static bank select 0

Eh, so how does it boot? Isn't there flash at 0x00000000, or are you
using blob-chain?

> 0x0800 0000       module flash bank1
> 0x1000 0000       static bank select 2
> 0x8000 0000       peripheral control module registers

Standard SA11x0, already mapped.

> 0x9000 0000       system control module registers

Also mapped.

> 0xc000 0000       module SDRAM bank

Blob will take care of this.

> 
> who can i configured true memory map and memory timing ?
> any ideas?

To compute the memory timings, there is a link to Intel's SDRAM
configurator on http://www.arm.linux.org.uk/developer/ .


Erik

-- 
J.A.K. (Erik) Mouw, Information and Communication Theory Group, Faculty
of Information Technology and Systems, Delft University of Technology,
PO BOX 5031, 2600 GA Delft, The Netherlands  Phone: +31-15-2783635
Fax: +31-15-2781843  Email: [EMAIL PROTECTED]
WWW: http://www-ict.its.tudelft.nl/~erik/

_______________________________________________
http://lists.arm.linux.org.uk/mailman/listinfo/linux-arm
Please visit the above address for information on this list.

Reply via email to