From 9e021f4e7c22df35828c36977a34c6dfb80e1c81 Mon Sep 17 00:00:00 2001 From: Stanislav Bolshakov Date: Thu, 7 Sep 2023 18:57:48 +0100 Subject: [PATCH 1/2] ARCv3: Add missing dependency for uImage Using clean build of uImage target by "make uImage" resulted in an error "'arch/arc/boot/loader': No such file". This was because of "loader" is not dependancy for "uImage". With this fix "make clean"+"make uImage" generate "loader" and "uImage" binaries in "arch/arc/boot/". --- arch/arc/boot/Makefile | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/arch/arc/boot/Makefile b/arch/arc/boot/Makefile index 48633d8b182b1f..4a0a2903356822 100644 --- a/arch/arc/boot/Makefile +++ b/arch/arc/boot/Makefile @@ -35,13 +35,25 @@ $(obj)/vmlinux.bin.gz: $(obj)/vmlinux.bin FORCE $(obj)/vmlinux.bin.lzma: $(obj)/vmlinux.bin FORCE $(call if_changed,lzma) +ifeq ($(CONFIG_ISA_ARCV3),y) +$(obj)/uImage.bin: $(obj)/vmlinux.bin $(obj)/loader FORCE +else $(obj)/uImage.bin: $(obj)/vmlinux.bin FORCE +endif $(call if_changed,uimage,none) +ifeq ($(CONFIG_ISA_ARCV3),y) +$(obj)/uImage.gz: $(obj)/vmlinux.bin.gz $(obj)/loader FORCE +else $(obj)/uImage.gz: $(obj)/vmlinux.bin.gz FORCE +endif $(call if_changed,uimage,gzip) +ifeq ($(CONFIG_ISA_ARCV3),y) +$(obj)/uImage.lzma: $(obj)/vmlinux.bin.lzma $(obj)/loader FORCE +else $(obj)/uImage.lzma: $(obj)/vmlinux.bin.lzma FORCE +endif $(call if_changed,uimage,lzma) $(obj)/loader.o: $(src)/loader.S $(obj)/vmlinux.bin From cba4d85f42d2f18b92e22c9402f060eeb45fb5f8 Mon Sep 17 00:00:00 2001 From: Stanislav Bolshakov Date: Mon, 11 Sep 2023 12:31:55 +0100 Subject: [PATCH 2/2] ARC: Github CI: Add uImage binaries building Add a GitHub CI test builds to ci.yml for automated testing of uImage building. This adds uImage artifacts files in addition to vmlinux files. --- .github/workflows/ci.yml | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c985b185881f6f..4926cfb33a8f9c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -71,6 +71,7 @@ jobs: libelf-dev \ libncurses5-dev \ libssl-dev \ + u-boot-tools \ make - name: Download toolchain @@ -146,16 +147,15 @@ jobs: ;; esac + make -j $(nproc) uImage + if [[ "${{ matrix.targets.cpu }}" =~ ^(hs5x|hs6x) ]]; then - image_name="loader" - image_path=${{ github.workspace }}/arch/arc/boot/loader + cp ${{ github.workspace }}/arch/arc/boot/loader vmlinux-${{ matrix.targets.cpu }} else - image_name="vmlinux" - image_path="${{ github.workspace }}/vmlinux" + cp ${{ github.workspace }}/vmlinux vmlinux-${{ matrix.targets.cpu }} fi - make -j $(nproc) ${image_name} - cp $image_path vmlinux-${{ matrix.targets.cpu }} + cp ${{ github.workspace }}/arch/arc/boot/uImage uImage-${{ matrix.targets.cpu }} shell: bash - name: Upload ${{ matrix.targets.cpu }} vmlinux @@ -165,6 +165,13 @@ jobs: path: vmlinux-${{ matrix.targets.cpu }} retention-days: 5 + - name: Upload ${{ matrix.targets.cpu }} uImage + uses: actions/upload-artifact@v3 + with: + name: uImage-${{ matrix.targets.cpu }} + path: uImage-${{ matrix.targets.cpu }} + retention-days: 5 + test: needs: [build] runs-on: nsim