hi people, i'm moving my first step on the source code side, im' not a coder, then sorry if i make some big mistake !!

i have a router MqMaker WITI board , this router is supported in the tree but only in the 256mb ram flavour , but my version is the 512 mb flavour

following this guide i change the code

https://openwrt.org/docs/guide-developer/adding_new_device

basing my work on this source

 https://git.openwrt.org/openwrt/openwrt.git

but without success ,when i boot via tftp i  obtain a kernal panic ...


here the file fist , that i've changed

 grep -lri witi ./
./linux/ramips/base-files/etc/board.d/02_network
./linux/ramips/base-files/etc/diag.sh
./linux/ramips/base-files/lib/ramips.sh
./linux/ramips/base-files/lib/upgrade/platform.sh
./linux/ramips/base-files/sbin/fixup-mac-address
./linux/ramips/dts/WITI.dts
./linux/ramips/dts/WITI512.dts
./linux/ramips/image/mt7621.mk


and here the diff


+++ ./witi/target/linux/ramips/base-files/etc/diag.sh   2018-04-24 08:33:36.448378665 +0000 --- ./openwrt/target/linux/ramips/base-files/etc/diag.sh 2018-04-26 08:07:28.992222123 +0000
@@ -280,7 +280,6 @@
                ;;
        w306r-v20|\
        witi|\
+       witi512|\
        zbt-wr8305rt)
                status_led="$boardname:green:sys"
                ;;


+++ ./witi/target/linux/ramips/base-files/etc/diag.sh   2018-04-24 08:33:36.448378665 +0000 --- ./openwrt/target/linux/ramips/base-files/etc/diag.sh 2018-04-26 08:07:28.992222123 +0000
@@ -280,7 +280,6 @@
                ;;
        w306r-v20|\
        witi|\
+       witi512|\
        zbt-wr8305rt)
                status_led="$boardname:green:sys"
                ;;

+++ ./witi/target/linux/ramips/base-files/lib/ramips.sh 2018-04-24 08:34:29.507527711 +0000 --- ./openwrt/target/linux/ramips/base-files/lib/ramips.sh 2018-04-26 08:07:28.996222067 +0000
@@ -580,9 +580,6 @@
        *"WiTi")
                 name="witi"
                ;;
+       *"WiTi-512")
+                name="witi-512"
+               ;;
        *"WIZARD 8800")
                name="wizard8800"
                ;;



--- ./openwrt/target/linux/ramips/base-files/lib/upgrade/platform.sh 2018-04-26 08:07:28.996222067 +0000 +++ ./witi/target/linux/ramips/base-files/lib/upgrade/platform.sh 2018-04-24 08:34:54.147140864 +0000
@@ -173,6 +173,7 @@
        widora,neo-16m|\
        widora,neo-32m|\
        witi|\
+       witi512|\
        wizfi630a|\
        wl-330n|\
        wl-330n3g|\

--- ./openwrt/target/linux/ramips/base-files/sbin/fixup-mac-address 2018-04-26 08:07:28.996222067 +0000 +++ ./witi/target/linux/ramips/base-files/sbin/fixup-mac-address 2018-04-24 08:36:16.185887196 +0000
@@ -17,6 +17,15 @@
                echo "Unsupported board"
                exit 1
        ;;
+
+       witi512)
+               partname=factory
+               offset=$((0xe000))
+       ;;
+       *)
+               echo "Unsupported board"
+               exit 1
+       ;;
 esac

 while [ -n "$1" ]; do


--- ./openwrt/target/linux/ramips/dts/WITI.dts  2018-04-26 08:07:29.004221953 +0000 +++ ./witi/target/linux/ramips/dts/WITI512.dts  2018-04-24 08:21:24.814159470 +0000
@@ -7,11 +7,11 @@

 / {
        compatible = "mqmaker,witi", "mediatek,mt7621-soc";
-       model = "MQmaker WiTi";
+       model = "MQmaker WiTi (512)";

        memory@0 {
                device_type = "memory";
-               reg = <0x0 0x10000000>;
+               reg = <0x0 0x20000000>;
        };

        chosen {



--- ./openwrt/target/linux/ramips/image/mt7621.mk       2018-04-26 08:07:29.012221838 +0000 +++ ./witi/target/linux/ramips/image/mt7621.mk  2018-04-24 08:40:45.574063959 +0000
@@ -320,6 +320,16 @@
 endef
 TARGET_DEVICES += witi

+define Device/witi512
+  DTS := WITI512
+  IMAGE_SIZE := $(ralink_default_fw_size_16M)
+  DEVICE_TITLE := MQmaker WiTi 512
+  DEVICE_PACKAGES := \
+       kmod-ata-core kmod-ata-ahci kmod-mt76x2 kmod-sdhci-mt7620 kmod-usb3 \
+       kmod-usb-ledtrig-usbport wpad-mini
+endef
+TARGET_DEVICES += witi512
+
 define Device/wndr3700v5
   DTS := WNDR3700V5
   IMAGE_SIZE := $(ralink_default_fw_size_16M)




and here the boot log


https://pastebin.com/n78TAhmr

how i can fix it ? where i must put my eyes on ?


_______________________________________________
Lede-dev mailing list
Lede-dev@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/lede-dev

Reply via email to