This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[FAQ] [参考译文] [FAQ] PROCESSOR-SDK-AM65X:构建和刷写 Linux SDK 映像的步骤

Guru**** 1456330 points
请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/processors-group/processors/f/processors-forum/1229591/faq-processor-sdk-am65x-steps-to-build-and-flash-linux-sdk-image

器件型号:PROCESSOR-SDK-AM65X

您能否提供构建和刷写 Linux SDK 映像的步骤(使用 SDK 版本基准+ Github 提交)?

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    要在刷写之前构建 ti-linux-kernel 代码、请遵循以下步骤:

    1.   通过链接  www.ti.com/.../PROCESSOR-SDK-AM65X 下载 PROCESSOR-SDK-LINUX-RT-AM65X --适用于 AM65x 的 Linux -RT Processor SDK for AM65x 各版本、并进行安装

      chmod +x ./ti-processor-sdk-linux-[platform]-<version>-Linux-x86-Install.bin
      ./ti-processor-sdk-linux-[platform]-<version>-Linux-x86-Install.bin


      请访问 
      https://software-dl.ti.com/processor-sdk-linux-rt/esd/AM65X/08_02_00_01/exports/docs/linux/Overview_Getting_Started_Guide.html

    2. 准备 SD 卡
      cd <path>/ti-processor-sdk-linux-rt-am65xx-evm-"$SDK_VERSION"/bin
      sudo ./mksdboot.sh --sdk <path>/ti-processor-sdk-linux-rt-am65xx-evm-"$SDK_VERSION"/ --device /dev/sd<x>
      sync

    3. 如果 从 ti-linux-kernel 闪存代码、而不是可用的默认映像、请从 ti-linux-kernel 克隆并签出至所需的标签
      git clone git.ti.com/.../ti-linux-kernel.git
      //checkout to required tag
      git checkout tags/{specify the tag}


    4. 如果从 ti-linux-kernel 编辑和构建代码、请转至下载的 Git 存储库路径、否则转至下载的 SDK 的路径
      //Go to path of downloaded repository
      cd Downloads/ti-linux-kernel
      
      //if building from SDK
      cd <path of SDK>/board-support/linux-rt...
      


    5. 构建 SDK 并将映像和 DTB 复制到 SD 卡
       //sdk path is the path of the downloaded sdk
      export PATH=<sdk path>/linux-devkit/sysroots/x86_64-arago-linux/usr/bin:$PATH
       
      //Command to clean kernel
      make ARCH=arm64 CROSS_COMPILE=aarch64-none-linux-gnu- distclean
       
      //Build defconfig from kernel git repository 
      //for version before 9.0
      ti_config_fragments/defconfig_builder.sh -t ti_sdk_arm64_release || ti_config_fragments/defconfig_builder.sh
      make ARCH=arm64 CROSS_COMPILE=aarch64-none-linux-gnu- ti_sdk_arm64_rt_release_defconfig
      
      //for 9.0 or later versions
      make ARCH=arm64 CROSS_COMPILE=$V8_CROSS defconfig ti_arm64_prune.config 
       
      //Build Image
      make ARCH=arm64 CROSS_COMPILE=aarch64-none-linux-gnu- Image
       
      //Build device tree binaries
      make ARCH=arm64 CROSS_COMPILE=aarch64-none-linux-gnu- dtbs
       
      //Compiling kernel modules
      make ARCH=arm64 CROSS_COMPILE=aarch64-none-linux-gnu- modules
       
      //Copying kernal image and device tree binaries to rootfs partition of sd card
      cd <kernel sources dir>
      sudo cp arch/arm64/boot/Image /media/rootfs/boot
      sudo cp arch/arm64/boot/dts/ti/*.dtb /media/rootfs/boot
      sudo cp arch/arm64/boot/dts/ti/*.dtbo /media/rootfs/boot
       
      //Installing kernel modules
      sudo make ARCH=arm64 INSTALL_MOD_PATH=/media/rootfs modules_install


    6. 将 SD 卡插入电路板并启动
    7. 重新启动板