AnsweredAssumed Answered

Linux on BF609, strange MMR behavior (CHIPID = 0x0000!?)

Question asked by Mortl on Mar 12, 2014
Latest reply on Mar 16, 2014 by Aaronwu

Hi,

 

I'm currently working on a custom BF609-Board (only DDR-RAM, SPI-Flash, nothing special) and trying to get the Linux Kernel up, but I get some strange behavior in the early stage of the boot, It seems that there is a problem with the MMRs of the DSP. The CPUID is supposed to be 0x0000 and the kernel is not able to inititalize the UART, although it is used by u-boot before!

 

I'm using u-boot 2013.10 as bootloader with a custom config that is an adaption of the bf609-ezkit. U-boot is loaded via LDR from the SPI-FLASH, this works very well. The kernel is also contained in the flash as a uImage file which was created by the buildroot linux 2014.02 scripts and the bf609-ezkit board config. UART0 is used for serial console to access both bootloader an kernel.

 

The boot process is initiated as followed (automatically as boot command):

 

bfin> sf probe 0:1; sf read 0x2000000 0x100000 0x100000; bootm 0x2000000

 

Then u-boot loads und uncompresses the uImage properly, also the CRC is correct.

After that the kernel is started and in the early stage it says (earlyprintk is enabled):

 

...

arch/blackfin/kernel/early_printk.c : 174 [init_early_exception_vectors]

Running on wrong machine type, expected 0x27fe, but running on 0x0000

arch/blackfin/kernel/setup.c : 194 [bfin_relocate_l1_mem]

arch/blackfin/kernel/bfin_dma.c : 267 [blackfin_dma_early_init]

arch/blackfin/kernel/bfin_dma.c : 278 [early_dma_memcpy]

arch/blackfin/kernel/bfin_dma.c : 278 [early_dma_memcpy]

arch/blackfin/kernel/bfin_dma.c : 343 [early_dma_memcpy_done]

arch/blackfin/kernel/setup.c : 1465 [cmdline_init]

arch/blackfin/mm/init.c : 71 [init_pda]

...

 

After the early stage the standard output apears:

 

[    0.000000] Linux version 3.13.5 (mortl@mortllinux) (gcc version 4.3.5 (ADI-2013R1-RC1) ) #8 Wed Mar 12 18:51:24 CET 2014

[    0.000000] register early platform devices

[    0.000000] bootconsole [early_shadow0] enabled

[    0.000000] ERROR: Not running on ADSP-BF609: unknown CPUID 0x0000 Rev 0.0

[    0.000000]  (null): fail to request bfin serial peripherals

[    0.000000] bfin-earlyprintk: unable to probe bfin-uart early.

[    0.000000] Board Memory: 128MB

[    0.000000] Kernel Managed Memory: 128MB

[    0.000000] Memory map:

[    0.000000]   fixedcode = 0x00000400-0x00000490

[    0.000000]   text         = 0x00001000-0x00101ef8

[    0.000000]   rodata     = 0x00101f1c-0x001430ec

[    0.000000]   bss         = 0x00144000-0x00170d1c

[    0.000000]   data        = 0x00170d20-0x00190000

[    0.000000]     stack    = 0x0018e000-0x00190000

[    0.000000]   init          = 0x00190000-0x001a5000

[    0.000000]   available = 0x001a5000-0x07800000

[    0.000000]   DMA Zone  = 0x07800000-0x08000000

[    0.000000] Hardware Trace active and enabled

[    0.000000] Blackfin support (C) 2004-2010 Analog Devices, Inc.

[    0.000000] Compiled for ADSP-BF609 Rev 0.1

[    0.000000] Blackfin Linux support by http://blackfin.uclinux.org/

[    0.000000] Processor Speed: 500 MHz core clock, 125 MHz SCLk, 125 MHz SCLK0, 125 MHz SCLK1 and 250 MHz DCLK

[    0.000000] Instruction Cache Disabled for CPU0

[    0.000000] Data Cache Disabled for CPU0

[    0.000000] Kernel command line: root=/dev/mtdblock0 rw clkin_hz=(25000000) earlyprintk=serial,uart0,115200 console=ttyBF0,115200

[    0.000000]  (null): fail to request bfin serial peripherals

[    0.000000] bfin-earlyprintk: unable to probe bfin-uart early.

[    0.000000] PID hash table entries: 512 (order: -1, 2048 bytes)

[    0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)

[    0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)

[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1

[    0.000000] NR_IRQS:291

[    0.000000] Configuring Blackfin Priority Driven Interrupts

 

And I'm back on the u-boot shell (actually the logbuffer above is printed by u-boot(?) ).

 

If I try to evaluate the CHIPID register manually I only get this:

 

bfin> md 0xffc00014
ffc00014: 00000000 00000000 00000000 00000000    ................
ffc00024: 00000000 00000000 00000000 00000000    ................
ffc00034: 00000000 00000000 00000000 00000000    ................
ffc00044: 00000000 00000000 00000000 00000000    ................
ffc00054: 00000000 00000000 00000000 00000000    ................
ffc00064: 00000000 00000000 00000000 00000000    ................

 

Do you have any idea what is happening here?

 

Best regards

Martin

Outcomes