Skip to content

Commit

Permalink
fix: repair pine64 support
Browse files Browse the repository at this point in the history
Apparently, I submitted non working board support earlier. This commit
fixes that and also adds the boards to both `sbcs` target and drone CI.

Signed-off-by: Jorik Jonker <jorik@kippendief.biz>
  • Loading branch information
jonkerj authored and talos-bot committed May 5, 2021
1 parent 3823909 commit 5de8dbc
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
1 change: 1 addition & 0 deletions .drone.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -538,6 +538,7 @@ local release = {
'_out/metal-rpi_4-arm64.img.xz',
'_out/metal-rockpi_4-arm64.img.xz',
'_out/metal-rock64-arm64.img.xz',
'_out/metal-pine64-arm64.img.xz',
'_out/metal-bananapi_m64-arm64.img.xz',
'_out/metal-libretech_all_h3_cc_h5-arm64.img.xz',
'_out/openstack-amd64.tar.gz',
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ sbc-%: ## Builds the specified SBC image. Valid options are rpi_4, rock64, banan
@docker pull $(REGISTRY_AND_USERNAME)/installer:$(TAG)
@docker run --rm -v /dev:/dev --privileged $(REGISTRY_AND_USERNAME)/installer:$(TAG) image --platform metal --arch arm64 --board $* --tar-to-stdout | tar xz -C $(ARTIFACTS)

sbcs: sbc-rpi_4 sbc-rock64 sbc-bananapi_m64 sbc-libretech_all_h3_cc_h5 sbc-rockpi_4 ## Builds all known SBC images (Raspberry Pi 4 Model B, Rock64, Banana Pi M64, Radxa ROCK Pi 4, and Libre Computer Board ALL-H3-CC).
sbcs: sbc-rpi_4 sbc-rock64 sbc-bananapi_m64 sbc-libretech_all_h3_cc_h5 sbc-rockpi_4 sbc-pine64 ## Builds all known SBC images (Raspberry Pi 4 Model B, Rock64, Banana Pi M64, Radxa ROCK Pi 4, pine64, and Libre Computer Board ALL-H3-CC).

.PHONY: iso
iso: ## Builds the ISO and outputs it to the artifact directory.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
)

var (
bin = fmt.Sprintf("/usr/install/u-boot/%s/u-boot-sunxi-with-spl.bin", constants.BoardPine64)
bin = fmt.Sprintf("usr/install/arm64/u-boot/%s/u-boot-sunxi-with-spl.bin", constants.BoardPine64)
off int64 = 1024 * 8
dtb = "/dtb/allwinner/sun50i-a64-pine64-plus.dtb"
)
Expand All @@ -33,7 +33,7 @@ type Pine64 struct{}

// Name implements the runtime.Board.
func (b *Pine64) Name() string {
return constants.BoardBananaPiM64
return constants.BoardPine64
}

// Install implements the runtime.Board.
Expand Down Expand Up @@ -72,7 +72,7 @@ func (b Pine64) Install(disk string) (err error) {
return err
}

src := "/usr/install" + dtb
src := "/usr/install/arm64" + dtb
dst := "/boot/EFI" + dtb

err = os.MkdirAll(filepath.Dir(dst), 0o600)
Expand Down
4 changes: 2 additions & 2 deletions pkg/machinery/constants/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,10 @@ const (
// BoardBananaPiM64 is the name of the Banana Pi M64.
BoardBananaPiM64 = "bananapi_m64"

// BoardPine64 is the name of the Pine64 Rock64.
// BoardPine64 is the name of the Pine64.
BoardPine64 = "pine64"

// BoardRock64 is the name of the Pine64 Rock64.
// BoardRock64 is the name of the Rock64.
BoardRock64 = "rock64"

// BoardRockpi4 is the name of the Radxa Rock pi 4.
Expand Down

0 comments on commit 5de8dbc

Please sign in to comment.