P2812HNUF3

Ivar Orskaug ivarorskaug at gmail.com
Sun Dec 12 04:32:34 PST 2021


Thanks for all the good feedback.
As pointed out, it's not possible to migrate from version 19 to 21
after applying this patch.
A backup/restore of config is required.
Some additional info for upgrading is also in the commit message
(updating uboot parameters).
The same information should be updated in the wiki page for the device also.

Ivar
diff --git a/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_zyxel_p-2812hnu-f3.dts
b/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_zyxel_p-2812hnu-f3.dts
index 376cdaeb61..a24dfcd5f9 100644
--- a/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_zyxel_p-2812hnu-f3.dts
+++ b/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_zyxel_p-2812hnu-f3.dts
@@ -55,11 +55,11 @@

                partition at 0 {
                        label = "kernel";
-                       reg = <0x0 0x200000>;
+                       reg = <0x0 0x500000>;
                };
-               partition at 200000 {
+               partition at 500000 {
                        label = "ubi";
-                       reg = <0x200000 0x7e00000>;
+                       reg = <0x500000 0x7b00000>;
                };
        };
 };
diff --git a/target/linux/lantiq/image/vr9.mk b/target/linux/lantiq/image/vr9.mk
index 909479587c..1686141438 100644
--- a/target/linux/lantiq/image/vr9.mk
+++ b/target/linux/lantiq/image/vr9.mk
@@ -282,8 +282,9 @@ define Device/zyxel_p-2812hnu-f3
   DEVICE_VARIANT := F3
   BOARD_NAME := P2812HNUF3
   DEVICE_PACKAGES := kmod-rt2800-pci wpad-basic-wolfssl kmod-usb-dwc2
-  KERNEL_SIZE := 2048k
+  KERNEL_SIZE := 5120k
   SUPPORTED_DEVICES += P2812HNUF3
-  DEFAULT := n
+  DEVICE_COMPAT_VERSION := 1.1
+  DEVICE_COMPAT_MESSAGE := Flash layout changed
 endef
 TARGET_DEVICES += zyxel_p-2812hnu-f3
Repartition flash to accommodate for a bigger kernel image.
The new kernel image (.bin) must be booted from tftp before running sysupgrade.
Running configuration must be backed up and restored.
After upgrading, update uboot parameters to load the entire kernel partition:

setenv nboot ' nand read 0x80800000 0x0 0x500000; bootm 0x80800000'
setenv bootcmd 'run nboot'
saveenv


tor. 9. des. 2021 kl. 22:14 skrev Ivar Orskaug <ivarorskaug at gmail.com>:
>
> Hi,
> P2812HNUF3 is currently broken in main because of the kernel 5.10
> increase in size. This patch increases the kernel flash partition to
> 3072k, aligning with P2812HNUF1. Would it be possible to apply it to
> main?
> Regards Ivar
>
> diff --git a/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_zyxel_p-2812hnu-f3.dts
> b/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_zyxel_p-2812hnu-f3.dts
> index 376cdaeb61..86520247d0 100644
> --- a/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_zyxel_p-2812hnu-f3.dts
> +++ b/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_zyxel_p-2812hnu-f3.dts
> @@ -55,11 +55,11 @@
>
>                 partition at 0 {
>                         label = "kernel";
> -                       reg = <0x0 0x200000>;
> +                       reg = <0x0 0x300000>;
>                 };
> -               partition at 200000 {
> +               partition at 300000 {
>                         label = "ubi";
> -                       reg = <0x200000 0x7e00000>;
> +                       reg = <0x300000 0x7d00000>;
>                 };
>         };
>  };
> diff --git a/target/linux/lantiq/image/vr9.mk b/target/linux/lantiq/image/vr9.mk
> index 909479587c..9e9818bdbf 100644
> --- a/target/linux/lantiq/image/vr9.mk
> +++ b/target/linux/lantiq/image/vr9.mk
> @@ -282,7 +282,7 @@ define Device/zyxel_p-2812hnu-f3
>    DEVICE_VARIANT := F3
>    BOARD_NAME := P2812HNUF3
>    DEVICE_PACKAGES := kmod-rt2800-pci wpad-basic-wolfssl kmod-usb-dwc2
> -  KERNEL_SIZE := 2048k
> +  KERNEL_SIZE := 3072k
>    SUPPORTED_DEVICES += P2812HNUF3
>    DEFAULT := n
>  endef



More information about the openwrt-devel mailing list