Navigation

    全志在线开发者论坛

    • Register
    • Login
    • Search
    • Categories
    • Tags
    • 在线文档
    • 社区主页
    1. Home
    2. SyntaxSugar
    S
    • Profile
    • Following 0
    • Followers 0
    • my integral 61
    • Topics 0
    • Posts 1
    • Best 0
    • Groups 0

    SyntaxSugarLV 2

    @SyntaxSugar

    61
    integral
    0
    Reputation
    1
    Profile views
    1
    Posts
    0
    Followers
    0
    Following
    Joined Last Online

    SyntaxSugar Unfollow Follow

    Latest posts made by SyntaxSugar

    • Reply: MQ-Quad H616 主线内核编译调试记录(u-boot、kernel、buildroot)

      跟着题主的步骤试了一下,但是遇到了一点问题

      用的 gcc 版本是 12.2.0
      bintuils 版本是 2.39

      第一个是 bintuils 2.39 版本加了个新特性,会出现 LOAD segment with RWX permissions 的警告,这个会导致 ATF 和 Uboot 都编译失败。

      要成功编译,必须修改 Makefile

      对于 ATF:

      # LD = gcc-ld (ld) or llvm-ld (ld.lld) or other
      else
      TF_LDFLAGS		+=	--fatal-warnings -O1
      TF_LDFLAGS		+=	--gc-sections
      

      在底下加一条:

      TF_LDFLAGS		+=	--no-warn-rwx-segments
      

      对于 UBoot

      KBUILD_LDFLAGS  := $(call ld-option, --no-warn-rwx-segments) \
      		   $(call ld-option, --no-warn-execstack)
      

      修改后还有几条 EFI_loader 相关的 LOAD segment with RWX permissions 警告,但是已经可以编译出来了。

      但是通过 sunxi-fel 启动 uboot 会卡在 Trying to boot from FEL,并且报错 usb_bulk_send() ERROR -7: Operation timed out

      $: sudo ../sunxi-tools/sunxi-fel uboot u-boot-sunxi-with-spl.bin 
      usb_bulk_send() ERROR -7: Operation timed out
      

      串口输出如下

      U-Boot SPL 2022.10-00409-g2afa989fbe-dirty (Oct 07 2022 - 23:37:55 +0800)
      pmic id is 0x4b
      DRAM: 1024 MiB
      Trying to boot from FEL
      

      然后就卡住了

      包括使用群里别人编译的 u-boot,也是类似的结果

      U-Boot SPL 2021.10-armbian (Sep 29 2022 - 17:22:28 +0800)
      pmic id is 0x4b
      DRAM: 1024 MiB
      Trying to boot from FEL
      

      关于 usb_bulk_send() ERROR -7

      有说重新编译 sunxi-tools 的,有说要接个 usb2.0 hub 的,有说降级 sunxi-tools 到 1.41版本的。前两个试了没用,最后一个 H616 太新了肯定不能降

      posted in H616系列-OTT
      S
      SyntaxSugar