Testing the SD_card driver in Odroid-X2

Humberto López León humberto at ...210...
Thu Sep 3 20:21:01 CEST 2015


Hello Christian,

Thanks for the recommendation.

On 09/03/2015 04:23 AM, Christian Helmuth wrote:
> Hello Humberto,
>
> maybe we should first get the file system out of way for testing your
> driver. There is the sd_card.run script, which serves exactly this
> purpose. So please try "make run/sd_card" in your scenario. You may
> limit the scope of the block test by adjusted the config node as in
> the attached patch.
When I try "make run/sd_card" with the configuration of patch I get the 
following output:


Starting kernel ...


L4 Bootstrapper
   Build: #77 Thu Sep  3 13:40:56 CDT 2015, 4.9.2
   Scanning up to 2047 MB RAM
   Memory size is 2047MB (40000000 - bfefffff)
   RAM: 0000000040000000 - 00000000bfefffff: 2096128kB
   Total RAM: 2047MB
   mod08: 411fa000-412314c4: genode/platform_drv
   mod07: 411b9000-411f9a98: genode/test-blk-cli
   mod06: 4117b000-411b8640: genode/sd_card_drv
   mod05: 4113f000-4117aca8: genode/timer
   mod04: 410fd000-4113ec40: genode/init
   mod03: 410fc000-410fc412: genode/config
   mod02: 41097000-410fbe90: genode/core
   mod01: 41085000-41096368: sigma0
   mod00: 41015000-4108431c: 
/home/humberto/SO/Genode/Repo_genode/GenodeOS/build/foc_odroid_x2/kernel/fiasco.oc/fiasco
   Moving up to 9 modules behind 41100000
   moving module 00 { 41015000-4108431b } -> { 4131d000-4138c31b } [455452]
   moving module 01 { 41085000-41096367 } -> { 4138d000-4139e367 } [70504]
   moving module 02 { 41097000-410fbe8f } -> { 4139f000-41403e8f } [413328]
   moving module 03 { 410fc000-410fc411 } -> { 41232000-41232411 } [1042]
   moving module 04 { 410fd000-4113ec3f } -> { 41233000-41274c3f } [269376]
   moving module 05 { 4113f000-4117aca7 } -> { 41100000-4113bca7 } [244904]
   moving module 06 { 4117b000-411b863f } -> { 4113c000-4117963f } [251456]
   moving module 07 { 411b9000-411f9a97 } -> { 4117a000-411baa97 } [264856]
   moving module 08 { 411fa000-412314c3 } -> { 411bb000-411f24c3 } [226500]
   moving module 03 { 41232000-41232411 } -> { 411f3000-411f3411 } [1042]
   moving module 04 { 41233000-41274c3f } -> { 411f4000-41235c3f } [269376]
   Scanning 
/home/humberto/SO/Genode/Repo_genode/GenodeOS/build/foc_odroid_x2/kernel/fiasco.oc/fiasco 
-serial_esc
   Scanning sigma0
   Scanning genode/core
   Relocated mbi to [0x4100e000-0x4100e1c4]
   Loading ode/GenodeOS/build/foc_odroid_x2/kernel/fiasco.oc/fiasco
   Loading sigma0
   Loading genode/core
   find kernel info page...
   found kernel info page at 0x40002000
Regions of list 'regions'
     [ 40001000,  40001a3f] {      a40} Kern 
ode/GenodeOS/build/foc_odroid_x2/kernel/fiasco.oc/fiasco
     [ 40002000,  4007efff] {    7d000} Kern 
ode/GenodeOS/build/foc_odroid_x2/kernel/fiasco.oc/fiasco
     [ 400a0000,  400a5fdf] {     5fe0} Sigma0 sigma0
     [ 400b0000,  400b617b] {     617c} Sigma0 sigma0
     [ 41000000,  410143f7] {    143f8} Boot   bootstrap
     [ 4100e000,  4100e2c1] {      2c2} Root   Multiboot info
     [ 41100000,  41235c3f] {   135c40} Root   Module
     [ 80100000,  80246663] {   146664} Root   genode/core
   API Version: (87) experimental
   Sigma0 config    ip:400a0100 sp:41013de4
   Roottask config  ip:80100000 sp:00000000
   Starting kernel 
ode/GenodeOS/build/foc_odroid_x2/kernel/fiasco.oc/fiasco at 40001208
Hello from Startup::stage2
Per_cpu_data_alloc: (orig: 0xf006c0d8-0xf006cb28)
Number of IRQs available at this GIC: 160
Cache config: ON
ID_PFR[01]:  00001231 00000011 ID_[DA]FR0: 00010444 00000000
ID_MMFR[04]: 00100103 20000000 01230000 00102111
FPU0: Arch: VFPv3(3), Part: VFPv3(30), r: 4, v: 9, i: 41, t: hard, p: 
dbl/sngl
L2: ID=4100c4c8 Type=1a340340 Aux=7e470001 WMask=ffff S=0
L2: Type L2C-310 Size = 1024kB
Watchdog initialized
SERIAL ESC: allocated IRQ 85 for serial uart
Not using serial hack in slow timer handler.
Welcome to Fiasco.OC (arm)!
L4/Fiasco.OC arm microkernel (C) 1998-2013 TU Dresden
Rev: b6fac81 compiled with gcc 4.9.2 for Samsung Exynos    []
Build: #42 Thu Sep  3 13:40:53 CDT 2015

Per_cpu_data_alloc: (orig: 0xf006c0d8-0xf006cb28)
Allocate 2640 bytes (3KB) for CPU[4] local storage (offset=1179f28, 
0xf11e6000-0xf11e6a50)
Timer for CPU0 is at IRQ 28
Number of CPUs: 4
Calibrating timer loop... Per_cpu_data_alloc: (orig: 0xf006c0d8-0xf006cb28)
done.
Allocate 2640 bytes (3KB) for CPU[1] local storage (offset=117af28, 
0xf11e7000-0xf11e7a50)
SCache config: ON
IID_PFR[01]:  00001231 00000011G ID_[DA]FR0: 00010444 00000000
MID_MMFR[04]: 00100103 20000000 01230000 00102111
AFPU1: Arch: VFPv3(3), Part: VFPv3(30), r: 4, v: 9, i: 41, t: hard, p: 
dbl/sngl
0Timer for CPU1 is at IRQ 28
:Per_cpu_data_alloc: (orig: 0xf006c0d8-0xf006cb28)
  CPU[1]: goes to idle loop
HAllocate 2640 bytes (3KB) for CPU[2] local storage (offset=1161f28, 
0xf11ce000-0xf11cea50)
eCache config: ON
lID_PFR[01]:  00001231 00000011l ID_[DA]FR0: 00010444 00000000
oID_MMFR[04]: 00100103 20000000 01230000 00102111
!FPU2: Arch: VFPv3(3), Part: VFPv3(30), r: 4, v: 9, i: 41, t: hard, p: 
dbl/sngl

Per_cpu_data_alloc: (orig: 0xf006c0d8-0xf006cb28)
  Timer for CPU2 is at IRQ 28
  CPU[2]: goes to idle loop
KAllocate 2640 bytes (3KB) for CPU[3] local storage (offset=1164f28, 
0xf11d1000-0xf11d1a50)
ICache config: ON
PID_PFR[01]:  00001231 00000011  ID_[DA]FR0: 00010444 00000000
@ID_MMFR[04]: 00100103 20000000 01230000 00102111
  FPU3: Arch: VFPv3(3), Part: VFPv3(30), r: 4, v: 9, i: 41, t: hard, p: 
dbl/sngl
4Timer for CPU3 is at IRQ 28
0CPU[3]: goes to idle loop
002000
   allocated 4KB for maintenance structures
SIGMA0: Dump of all resource maps
RAM:------------------------
[0:40000000;40000fff]
[0:4007f000;4009ffff]
[0:400a6000;400affff]
[0:400b7000;4100dfff]
[4:4100e000;4100efff]
[0:4100f000;410fffff]
[4:41100000;41235fff]
[0:41236000;800fffff]
[4:80100000;80246fff]
[0:80247000;beefffff]
IOMEM:----------------------
[0:0;3fffffff]
[0:bff00000;ffffffff]

KIP @ 40002000
     magic: 4be6344c
   version: 87024444
          sigma0  esp: 41013de4  eip: 400a0100
          sigma1  esp: 00000000  eip: 00000000
            root  esp: 00000000  eip: 80100000
MBI @ 4100e000
  mod[3] [411f3000,411f3412) config
  mod[4] [411f4000,41235c40) init
  mod[5] [41100000,4113bca8) timer
  mod[6] [4113c000,41179640) sd_card_drv
  mod[7] [4117a000,411baa98) test-blk-cli
  mod[8] [411bb000,411f24c4) platform_drv
:ram_alloc: Allocator 80235f68 dump:
  Block: [40000000,40001000) size=00001000 avail=00001000 max_avail=00001000
  Block: [4007f000,400a0000) size=00021000 avail=00021000 max_avail=00021000
  Block: [400a6000,400a601c) size=0000001c avail=00000000 max_avail=00021000
  Block: [400a601c,400a6038) size=0000001c avail=00000000 max_avail=00000000
  Block: [400a6038,400a6054) size=0000001c avail=00000000 max_avail=00000000
  Block: [400a6054,400a6070) size=0000001c avail=00000000 max_avail=00000000
  Block: [400a6070,400a608c) size=0000001c avail=00000000 max_avail=00009f58
  Block: [400a608c,400a60a8) size=0000001c avail=00000000 max_avail=00000000
  Block: [400a60a8,400b0000) size=00009f58 avail=00009f58 max_avail=00009f58
  Block: [400b7000,400b701c) size=0000001c avail=00000000 max_avail=3eeca000
  Block: [400b701c,4100e000) size=00f56fe4 avail=00f56fe4 max_avail=00f56fe4
  Block: [4100f000,41100000) size=000f1000 avail=000f1000 max_avail=3eeca000
  Block: [41236000,80100000) size=3eeca000 avail=3eeca000 max_avail=3eeca000
  Block: [80247000,bef00000) size=3ecb9000 avail=3ecb9000 max_avail=3ecb9000
  => mem_size=2126475264 (2027 MB) / mem_avail=2126475068 (2027 MB)
:region_alloc: Allocator 802370d8 dump:
  Block: [00001000,20000000) size=1ffff000 avail=1ffff000 max_avail=1ffff000
  Block: [30000000,40000000) size=10000000 avail=10000000 max_avail=1ffff000
  Block: [40001000,40002000) size=00001000 avail=00001000 max_avail=1ffff000
  Block: [40003000,4007f000) size=0007c000 avail=0007c000 max_avail=0007c000
  Block: [400a0000,400a6000) size=00006000 avail=00006000 max_avail=1ffff000
  Block: [400b0000,400b7000) size=00007000 avail=00007000 max_avail=010f0000
  Block: [bef00000,bfff0000) size=010f0000 avail=010f0000 max_avail=010f0000
  => mem_size=823627776 (785 MB) / mem_avail=823627776 (785 MB)
:io_mem: Allocator 802363c4 dump:
  Block: [00000000,40000000) size=40000000 avail=40000000 max_avail=40000000
  Block: [40001000,40002000) size=00001000 avail=00001000 max_avail=40000000
  Block: [40003000,4007f000) size=0007c000 avail=0007c000 max_avail=0007c000
  Block: [400a0000,400a6000) size=00006000 avail=00006000 max_avail=0007c000
  Block: [400b0000,400b7000) size=00007000 avail=00007000 max_avail=410fffff
  Block: [bef00000,ffffffff) size=410fffff avail=410fffff max_avail=410fffff
  => mem_size=2165874687 (2065 MB) / mem_avail=2165874687 (2065 MB)
:io_port: Allocator 80236820 dump:
:irq: Allocator 80236c7c dump:
  Block: [00000000,00000260) size=00000260 avail=00000260 max_avail=00000260
  => mem_size=608 (0 MB) / mem_avail=608 (0 MB)
:rom_fs: Rom_fs 8023798c dump:
  Rom: [4113c000,41179640) sd_card_drv
  Rom: [411f4000,41235c40) init
  Rom: [411f3000,411f3412) config
  Rom: [40002000,40003000) l4v2_kip
  Rom: [40002000,40003000) kip
  Rom: [411bb000,411f24c4) platform_drv
  Rom: [41100000,4113bca8) timer
  Rom: [4117a000,411baa98) test-blk-cli
:core ranges: Allocator 8023a260 dump:
  Block: [40000000,40001000) size=00001000 avail=00001000 max_avail=00001000
  Block: [4007f000,400a0000) size=00021000 avail=00021000 max_avail=00021000
  Block: [400a6000,400b0000) size=0000a000 avail=0000a000 max_avail=7def1000
  Block: [400b7000,4100e000) size=00f57000 avail=00f57000 max_avail=7def1000
  Block: [4100f000,bef00000) size=7def1000 avail=7def1000 max_avail=7def1000
  => mem_size=2129084416 (2030 MB) / mem_avail=2129084416 (2030 MB)
Genode 15.05-173-gb6fac81 <local changes>
int main(): --- create local services ---
int main(): --- start init ---
int main(): transferred 2027 MB to init
int main(): --- init created, waiting for exit condition ---
[init] Could not open ROM session for module "ld.lib.so"
[init -> platform_drv] --- Odroid-x2 platform driver ---
[init -> platform_drv] Dentro del constructor CMU
[init -> platform_drv] Changing CPU frequency to 1400000000
[init -> platform_drv] End of Changing CPU frequency to 1400000000
[init -> platform_drv] Saliendo del constructor CMU
[init -> platform_drv] Entrando del constructor PMU
[init -> platform_drv] Saliendo del constructor PMU
[init -> platform_drv] --- Odroid-x2 platform driver. Done ---
[init -> sd_card_drv] --- SD card driver ---
[init -> sd_card_drv] CID: 0x744a4553 0x44432020 0x1033005b 0x8700e100
[init -> sd_card_drv] RCA: 0xb368
[init -> sd_card_drv] SD card detected
[init -> sd_card_drv] capacity: 7695 MiB
[init -> test-blk-cli] block device with block size 512 sector count 
15759360 (testing 131072 sectors)
[init -> sd_card_drv] CID: 0x744a4553 0x44432020 0x1033005b 0x8700e100
[init -> sd_card_drv] RCA: 0xb368
[init -> sd_card_drv] SD card detected
[init -> sd_card_drv] capacity: 7695 MiB
[init -> test-blk-cli] reading block 0 - 131071, 246 per request
Insufficient quota for transfer: init -> test-blk-cli
   have 520192, need 686095
[init] not enough quota for a donation of 686095 bytes
[init -> test-blk-cli] resource_request: ram_quota=686095
[init -> test-blk-cli] virtual void Genode::Platform_env::release(): 
used before freeing emergency=262144
[init -> test-blk-cli] virtual void Genode::Platform_env::release(): 
used after freeing emergency=253952
[init] child "test-blk-cli" requests resources: ram_quota=686095
[init -> sd_card_drv] CID: 0x744a4553 0x44432020 0x1033005b 0x8700e100
[init -> sd_card_drv] RCA: 0xb368
[init -> sd_card_drv] SD card detected
[init -> sd_card_drv] capacity: 7695 MiB
[init -> test-blk-cli] reading block 0 - 131071, 1 per request
[init -> sd_card_drv] CID: 0x744a4553 0x44432020 0x1033005b 0x8700e100
[init -> sd_card_drv] RCA: 0xb368
[init -> sd_card_drv] SD card detected
[init -> sd_card_drv] capacity: 7695 MiB
[init -> test-blk-cli] reading block 0 - 131071, 1 per request
[init -> sd_card_drv] CID: 0x744a4553 0x44432020 0x1033005b 0x8700e100
[init -> sd_card_drv] RCA: 0xb368
[init -> sd_card_drv] SD card detected
[init -> sd_card_drv] capacity: 7695 MiB
[init -> test-blk-cli] read/write/compare block 0 - 131071, 8 per request
[init -> test-blk-cli] Test failed!
[init -> test-blk-cli] Integrity check failed: block 0 - 8
[init] virtual void Genode::Child_policy::exit(int): child 
"test-blk-cli" exited with exit value -2


Apparently the test fails to make the comparison between the read and 
written. Personally I think the problem is in writing, using the FAT32 
port could read from a file that was on the SD card without problems, 
but the test failed when trying to create a file.


Anyone have any suggestions of what may be affecting writing?

Regards

Humberto





More information about the users mailing list