Skip to content

Commit

Permalink
v9.7
Browse files Browse the repository at this point in the history
- DietPi-Patches | WIP: Migration for legacy R5S/R5C/6 series
  • Loading branch information
MichaIng committed Aug 15, 2024
1 parent 0690eaf commit c63d5cf
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .update/patches
Original file line number Diff line number Diff line change
Expand Up @@ -1778,6 +1778,44 @@ Patch_9_7()
*) :;;
esac
fi

# NanoPi R5S/R6S migration from legacy image with 8 partitions to Armbian-based kernel and bootloader
elif [[ $G_HW_MODEL == 76 && $(dpkg-query -s 'firmware-nanopi5' &> /dev/null) ]]
then
case $(</proc/device-tree/model) in
*R5S*) HW_VARIANT=1 /boot/dietpi/func/dietpi-set_software apt-mirror dietpi; local model='nanopi-r5s';;
*R5C*) HW_VARIANT=1 /boot/dietpi/func/dietpi-set_software apt-mirror dietpi; local model='nanopi-r5c';;
*) G_DIETPI-NOTIFY 1 'No known SBC model detected'; exit 1;;
esac
G_AGUP
if G_WHIP_DEFAULT_ITEM='yes' G_WHIP_YESNO '[ INFO ] Major kernel and bootloader upgrade available
\nFor the NanoPi R5S/R5C, we offer a major kernel upgrade to Linux 6.1, based on a new Rockchip kernel source which should provide not only new kernel features, but higher quality as well, compared to the old Rockchip Linux 5.10 legacy kernel.
\nAdditionally, compared to the previously hidden kernel image and boot config on the first 7 partitions, the new image and configs will stored and available within the /boot partition, so that kernel command-line parameters can be adjusted. Also kernel headers are available to compile new kernel modules.
\nThis implies flashing a new bootloader image, which reads boot scripts from the root partition.
\nHowever, while we are not aware of any left issues, it is still good to have a backup in place, and we do not enforce the upgrade. You can do it any time later.
\nDo you want to migrate to the new Linux 6.1 kernel now?'
then
:
fi

elif [[ $G_HW_MODEL == 79 && $(dpkg-query -s 'firmware-nanopi6' &> /dev/null) ]]
then
case $(</proc/device-tree/model) in
*R6S*) HW_VARIANT=1 /boot/dietpi/func/dietpi-set_software apt-mirror dietpi; local model='nanopi-r6s';;
*R6C*) HW_VARIANT=1 /boot/dietpi/func/dietpi-set_software apt-mirror dietpi; local model='nanopi-r6c';;
*T6*) HW_VARIANT=1 /boot/dietpi/func/dietpi-set_software apt-mirror dietpi; local model='nanopct6';;
*) G_DIETPI-NOTIFY 1 'No known SBC model detected'; exit 1;;
esac
G_AGUP
if G_WHIP_DEFAULT_ITEM='yes' G_WHIP_YESNO '[ INFO ] Major kernel and bootloader upgrade available
\nFor the NanoPi 6 series, we offer a major kernel upgrade to Linux 6.6, based on mainline kernel sources which should provide not only new kernel features, but higher quality as well, compared to the old Rockchip Linux 5.10 legacy kernel.
\nAdditionally, compared to the previously hidden kernel image and boot config on the first 7 partitions, the new image and configs will stored and available within the /boot partition, so that kernel command-line parameters can be adjusted. Also kernel headers are available to compile new kernel modules.
\nThis implies flashing a new bootloader image, which reads boot scripts from the root partition.
\nHowever, while we are not aware of any left issues, it is still good to have a backup in place, and we do not enforce the upgrade. You can do it any time later.
\nDo you want to migrate to the new Linux 6.6 kernel now?'
then
:
fi
fi

# Software updates, migrations and patches
Expand Down

0 comments on commit c63d5cf

Please sign in to comment.