Skip to content

Commit

Permalink
Merge branch 'openwrt:main' into BPI-R4-NIC-BE14-danpawlik
Browse files Browse the repository at this point in the history
  • Loading branch information
nextgen-networks authored Sep 28, 2024
2 parents 543fb96 + 45bd222 commit eb1a4e1
Show file tree
Hide file tree
Showing 8 changed files with 1,514 additions and 868 deletions.
26 changes: 20 additions & 6 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,22 +39,18 @@
- any-glob-to-any-file:
- "target/linux/bcm4908/**"
- "package/boot/uboot-bcm4908/**"
- "package/boot/arm-trusted-firmware-bcm63xx/**"
"target/bcm53xx":
- changed-files:
- any-glob-to-any-file:
- "target/linux/bcm53xx/**"
- "package/boot/uboot-bcm53xx/**"
"target/bcm63xx":
- changed-files:
- any-glob-to-any-file:
- "target/linux/bcm63xx/**"
- "package/kernel/bcm63xx-cfe/**"
- "package/boot/arm-trusted-firmware-bcm63xx/**"
"target/bmips":
- changed-files:
- any-glob-to-any-file:
- "target/linux/bmips/**"
- "package/boot/uboot-bmips/**"
- "package/kernel/bcm63xx-cfe/**"
"target/d1":
- changed-files:
- any-glob-to-any-file:
Expand Down Expand Up @@ -83,6 +79,12 @@
- changed-files:
- any-glob-to-any-file:
- "target/linux/qualcommax/**"
"target/ixp4xx":
- changed-files:
- any-glob-to-any-file:
- "target/linux/ixp4xx/**"
- "package/boot/apex/Makefile/**"
- "package/firmware/ixp4xx-microcode/**"
"target/kirkwood":
- changed-files:
- any-glob-to-any-file:
Expand All @@ -103,6 +105,10 @@
- "package/boot/tfa-layerscape/**"
- "package/boot/uboot-layerscape/**"
- "package/network/utils/layerscape/**"
"target/loongarch64":
- changed-files:
- any-glob-to-any-file:
- "target/linux/loongarch64/**"
"target/malta":
- changed-files:
- any-glob-to-any-file:
Expand Down Expand Up @@ -165,6 +171,14 @@
- "target/linux/sifiveu/**"
- "package/boot/uboot-sifiveu/**"
- "package/boot/opensbi/**"
"target/siflower":
- changed-files:
- any-glob-to-any-file:
- "target/linux/siflower/**"
"target/starfive":
- changed-files:
- any-glob-to-any-file:
- "target/linux/starfive/**"
"target/sunxi":
- changed-files:
- any-glob-to-any-file:
Expand Down
13 changes: 10 additions & 3 deletions package/base-files/files/lib/upgrade/emmc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,22 @@ emmc_upgrade_tar() {
tar tf "$tar_file" ${board_dir}/kernel 1>/dev/null 2>/dev/null && has_kernel=1
tar tf "$tar_file" ${board_dir}/root 1>/dev/null 2>/dev/null && has_rootfs=1

[ "$has_kernel" = 1 -a "$EMMC_KERN_DEV" ] &&
export EMMC_KERNEL_BLOCKS=$(($(tar xf "$tar_file" ${board_dir}/kernel -O | dd of="$EMMC_KERN_DEV" bs=512 2>&1 | grep "records out" | cut -d' ' -f1)))

[ "$has_rootfs" = 1 -a "$EMMC_ROOT_DEV" ] && {
# Invalidate kernel image while rootfs is being written
[ "$has_kernel" = 1 -a "$EMMC_KERN_DEV" ] && {
dd if=/dev/zero of="$EMMC_KERN_DEV" bs=512 count=8
sync
}

export EMMC_ROOTFS_BLOCKS=$(($(tar xf "$tar_file" ${board_dir}/root -O | dd of="$EMMC_ROOT_DEV" bs=512 2>&1 | grep "records out" | cut -d' ' -f1)))
# Account for 64KiB ROOTDEV_OVERLAY_ALIGN in libfstools
EMMC_ROOTFS_BLOCKS=$(((EMMC_ROOTFS_BLOCKS + 127) & ~127))
sync
}

[ "$has_kernel" = 1 -a "$EMMC_KERN_DEV" ] &&
export EMMC_KERNEL_BLOCKS=$(($(tar xf "$tar_file" ${board_dir}/kernel -O | dd of="$EMMC_KERN_DEV" bs=512 2>&1 | grep "records out" | cut -d' ' -f1)))

if [ -z "$UPGRADE_BACKUP" ]; then
if [ "$EMMC_DATA_DEV" ]; then
dd if=/dev/zero of="$EMMC_DATA_DEV" bs=512 count=8
Expand Down
Loading

0 comments on commit eb1a4e1

Please sign in to comment.