<meta http-equiv="Content-Type" content="text/html; charset=GB18030"><div>Hi,</div><div><br></div><div>> Hello,</div><div>> </div><div>> On 06/01/2021 10:04, jameszxj wrote:</div><div>> > Hi,</div><div>> > </div><div>> > I can't find "timer" node in your devicetree. </div><div>> > Function arm_generic_timer_get_config() in file bspstart.c will find </div><div>> > node "/timer"</div><div>> > and get "clock-frequency" value for system tick.</div><div>> </div><div>> note that at least the clock-frequency is added by U-Boot on the i.MX7 </div><div>> during boot and is not in the typical device tree sources.</div><div>> </div><div>> On i.MX6UL/ULL there is still an ugly hack necessary:</div><div>> </div><div>> https://github.com/grisp/rtems/commit/02270d5ec82684007ae9973070a6f29428be1543</div><div>> </div><div>> It's on my TODO-list to avoid that patch, but I haven't done that yet.</div><div>> </div><div><br></div><div>I add the timer_init in bsp, but the tick interrupt still seems pending.</div><div>When I type something in shell, ticks will come.</div><div><br></div><div>> > </div><div>> > ------------------ Original ------------------</div><div>> > *From:* "JunBeom Kim (EmbedCoreTech)" <jbkim@e-coretech.kr>;</div><div>> > *Date:* Wed, Jan 6, 2021 04:46 PM</div><div>> > *To:* "'jameszxj'"<jameszxj@gmail.com>;"'users'"<users@rtems.org>;</div><div>> > *Subject:* RE: RTEMS Fatal Error on IMX7D SABRE Board.</div><div>> > </div><div>> > Dear James,</div><div>> > </div><div>> > As I know before, because this BSP is tested on Phytec¡¯s PhyBOARD-i.MX7 </div><div>> > board, I am considering to purchase this board, too.</div><div>> </div><div>> </div><div>> The last test on that board is some time back because I currently don't </div><div>> have access to it (working from home). So also I would hope it, I </div><div>> wouldn't guarantee that it runs out of the box.</div><div>> </div><div><br></div><div>thanks.</div><div><br></div><div>> </div><div>> > </div><div>> > Best Regards,</div><div>> > </div><div>> > JunBeom</div><div>> > </div><div>> > *From:*JunBeom Kim (EmbedCoreTech) <jbkim@e-coretech.kr></div><div>> > *Sent:* Wednesday, January 6, 2021 5:39 PM</div><div>> > *To:* 'jameszxj' <jameszxj@gmail.com>; 'users' <users@rtems.org></div><div>> > *Subject:* RE: RTEMS Fatal Error on IMX7D SABRE Board.</div><div>> > </div><div>> > Dear James,</div><div>> > </div><div>> > I used two files(imx7d-sdb.dts and imx7d.dtsi) for making imx7d-sdb.dtb.</div><div>> > </div><div>> > There is clock-frequency configuration in imx7d.dtsi.</div><div>> > </div><div>> </div><div>> </div><div>> Again: Normally U-Boot should add that clock-frequency.</div><div>> </div><div>> </div><div>> > Best Regards,</div><div>> > </div><div>> > JunBeom</div><div>> > </div><div>> > *From:*users <users-bounces@rtems.org <mailto:users-bounces@rtems.org>> </div><div>> > *On Behalf Of *jameszxj</div><div>> > *Sent:* Wednesday, January 6, 2021 4:13 PM</div><div>> > *To:* users <users@rtems.org <mailto:users@rtems.org>></div><div>> > *Subject:* Re:RTEMS Fatal Error on IMX7D SABRE Board.</div><div>> > </div><div>> > Hi,</div><div>> > I use IMX7 bsp on my imx6ull board. I have encountered maybe the same </div><div>> > problem. Please check your device-tree, BSP needs "clock-frequency" at </div><div>> > node "timer".</div><div>> </div><div>> Do you use an i.MX6ULL with U-Boot or Barebox? They might have slightly </div><div>> different behavior regarding the timer.</div><div>> </div><div><br></div><div>I use barebox.</div><div><br></div><div>> > </div><div>> > But I encountered another problems, theARMv7-AR Generic Timercan not </div><div>> > generate interrupt.</div><div>> > imx7d has the same core with imx6ull£¬if your board run RTEMS </div><div>> > successfully, please let me know, thanks.</div><div>> </div><div>> As you might have seen above, I'm using the BSP on i.MX6ULL based </div><div>> boards. The board uses Phytec Phycore i.MX6UL/ULL modules (different </div><div>> variants in different projects). One of the projects is an open source </div><div>> one and you can find all sources at:</div><div>> </div><div>>      https://github.com/grisp/grisp2-rtems-toolchain</div><div>> </div><div>> > </div><div>> > ------------------ Original ------------------</div><div>> > </div><div>> > *From:*"JunBeom Kim (EmbedCoreTech)" <jbkim@e-coretech.kr </div><div>> > <mailto:jbkim@e-coretech.kr>>;</div><div>> > </div><div>> > *Date:*Wed, Jan 6, 2021 01:05 PM</div><div>> > </div><div>> > *To:*"users"<users@rtems.org <mailto:users@rtems.org>>;</div><div>> > </div><div>> > *Subject:*RTEMS Fatal Error on IMX7D SABRE Board.</div><div>> > </div><div>> > Hello,</div><div>> > </div><div>> > After I purchased i.MX7D SABRE board, I am trying to test RTEMS kernel using</div><div>> > lastest RTEMS kernel and source builder for RTEMS 6.0</div><div>> > </div><div>> > As I knew before, RTEMS BSP for i.MX7D was not tested for i.MX7D SABRE</div><div>> > board.</div><div>> > </div><div>> > When I tested this, my testing result is in below;</div><div>> > <REMARK> rtems.img is made by calling mkimage.</div><div>> > </div><div>> > At this time, I am trying to debug RTEMS BSP using GDB with J-Link probe.</div><div>> > There is problem for executing start.S assembly code as source code level.</div><div>> </div><div>> Can you try to set a breakpoint on at least _Terminate and do a </div><div>> backtrace (bt in gdb)? I think the _ARM_Exception_default could be a </div><div>> useful one too.</div><div>> </div><div>> Best regards</div><div>> </div><div>> Christian</div><div>> </div><div>> </div><div>> > </div><div>> > Please advise me.</div><div>> > </div><div>> > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~</div><div>> > U-Boot 2020.10 (Jan 05 2021 - 09:44:38 +0900)</div><div>> > </div><div>> > CPU:Freescale i.MX7D rev1.3 1000 MHz (running at 792 MHz)</div><div>> > CPU:Commercial temperature grade (0C to 95C) at 38C</div><div>> > Reset cause: POR</div><div>> > Model: Freescale i.MX7 SabreSD Board</div><div>> > Board: i.MX7D SABRESD in non-secure mode</div><div>> > DRAM:1 GiB</div><div>> > PMIC: PFUZE3000 DEV_ID=0x30 REV_ID=0x11</div><div>> > MMC:FSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2</div><div>> > Loading Environment from MMC... *** Warning - bad CRC, using default</div><div>> > environment</div><div>> > </div><div>> > Video: 480x272x24</div><div>> > In:serial</div><div>> > Out:serial</div><div>> > Err:serial</div><div>> > Hit any key to stop autoboot:0</div><div>> > </div><div>> > => fatload mmc 0 0x80800000 rtems.img</div><div>> > 36463 bytes read in 23 ms (1.5 MiB/s)</div><div>> > </div><div>> > => fatload mmc 0 0x83000000 imx7d-sdb.dtb</div><div>> > 33369 bytes read in 22 ms (1.4 MiB/s)</div><div>> > </div><div>> > => bootm 0x80800000 - 0x83000000</div><div>> > ## Booting kernel from Legacy Image at 80800000 ...</div><div>> > Image Name:RTEMS</div><div>> > Image Type:ARM Linux Kernel Image (gzip compressed)</div><div>> > Data Size:36399 Bytes = 35.5 KiB</div><div>> > Load Address: 80200000</div><div>> > Entry Point:80200000</div><div>> > Verifying Checksum ... OK</div><div>> > ## Flattened Device Tree blob at 83000000</div><div>> > Booting using the fdt blob at 0x83000000</div><div>> > Uncompressing Kernel Image</div><div>> > Using Device Tree in place at 83000000, end 8300b258</div><div>> > </div><div>> > Starting kernel ...</div><div>> > </div><div>> > </div><div>> > *** FATAL ***</div><div>> > fatal source: 6 (RTEMS_FATAL_SOURCE_BSP)</div><div>> > fatal code: 3072 (0x00000c00)</div><div>> > RTEMS version: 6.0.0</div><div>> > RTEMS tools: 10.2.1 20201222 (RTEMS 6, RSB</div><div>> > d3dc0bc3861362978cdf65725e4ba2b64e283d32, Newlib 415fdd4)</div><div>> > Executing thread is NULL</div><div>> > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~</div><div>> > </div><div>> > Best Regards,</div><div>> > JunBeom Kim</div><div>> > </div><div>> > _______________________________________________</div><div>> > users mailing list</div><div>> > users@rtems.org <mailto:users@rtems.org></div><div>> > http://lists.rtems.org/mailman/listinfo/users </div><div>> > <http://lists.rtems.org/mailman/listinfo/users></div><div>> > </div><div>> > </div><div>> > _______________________________________________</div><div>> > users mailing list</div><div>> > users@rtems.org</div><div>> > http://lists.rtems.org/mailman/listinfo/users</div><div>> > </div>