Robinson Wu <wurobin...@qq.com> [2020-04-07 16:36:52]: Hi,
> +&pinctrl { > + state_default: pinctrl0 { > + gpio { > + ralink,group = "gpio","p3led_an","p4led_an", > + "pwm0","pwm1","refclk","wdt","wled_an"; > + ralink,function = "gpio"; > + }; > + > + p0led { > + ralink,group = "p0led_an"; > + ralink,function = "p0led_an"; > + }; > + > + p1led { > + ralink,group = "p1led_an"; > + ralink,function = "p1led_an"; > + }; > + > + p2led { > + ralink,group = "p2led_an"; > + ralink,function = "p2led_an"; > + }; > + > + pwm_2_3 { > + ralink,group = "uart2"; > + ralink,function = "pwm"; > + }; > + }; > + > + uart2 { > + uart2 { > + ralink,group = "spis"; > + ralink,function = "pwm_uart2"; > + }; > + }; this block looks weird > +&spi0 { > + status = "okay"; > + > + pinctrl-names = "default"; > + pinctrl-0 = <&spi_pins>, <&spi_cs1_pins>; > + > + flash@0 { > + compatible = "jedec,spi-nor"; > + reg = <0>; > + spi-max-frequency = <40000000>; > + m25p,chunked-io = <32>; > + > + partitions { > + compatible = "fixed-partitions"; > + #address-cells = <1>; > + #size-cells = <1>; > + > + partition@0 { > + label = "u-boot"; > + reg = <0x0 0x30000>; > + read-only; > + }; > + > + partition@30000 { > + label = "u-boot-env"; > + reg = <0x30000 0x10000>; > + read-only; > + }; > + > + factory: partition@40000 { > + label = "factory"; > + reg = <0x40000 0x10000>; > + read-only; > + }; > + > + firmware: partition@50000 { > + compatible = "denx,uimage"; missing reg property > + label = "firmware"; > + }; > + }; > + }; > + > + spidev@1 { > + #address-cells = <1>; > + #size-cells = <1>; > + compatible = "linux,spidev"; > + reg = <1>; > + spi-max-frequency = <40000000>; > + }; Remove this, it's going to produce kernel warning. > --- a/target/linux/ramips/image/mt76x8.mk > +++ b/target/linux/ramips/image/mt76x8.mk > @@ -140,6 +140,36 @@ define Device/iptime_a604m > endef > TARGET_DEVICES += iptime_a604m > whitespace issue > +define Device/jotale_js76x8-16m > + MTK_SOC := mt7628an > + IMAGE_SIZE := 16064k > + DEVICE_VENDOR := Jotale > + DEVICE_MODEL := JS76x8 > + DEVICE_VARIANT := 16M > + DEVICE_PACKAGES := kmod-usb2 kmod-usb-ohci > +endef > +TARGET_DEVICES += jotale_js76x8-16m > + > +define Device/jotale_js76x8-32m > + MTK_SOC := mt7628an > + IMAGE_SIZE := 32448k > + DEVICE_VENDOR := Jotale > + DEVICE_MODEL := JS76x8 > + DEVICE_VARIANT := 32M > + DEVICE_PACKAGES := kmod-usb2 kmod-usb-ohci > +endef > +TARGET_DEVICES += jotale_js76x8-32m > + > +define Device/jotale_js76x8-8m > + MTK_SOC := mt7628an > + IMAGE_SIZE := 7872k > + DEVICE_VENDOR := Jotale > + DEVICE_MODEL := JS76x8 > + DEVICE_VARIANT := 8M > + DEVICE_PACKAGES := kmod-usb2 kmod-usb-ohci > +endef > +TARGET_DEVICES += jotale_js76x8-8m > + Be DRY, use some common Device and just change IMAGE_SIZE and DEVICE_VARIANT. > @@ -186,6 +189,9 @@ ramips_setup_macs() > mercury,mac1200r-v2) > wan_mac=$(macaddr_add "$(mtd_get_mac_binary factory_info 0xd)" > 1) > ;; > + jotale,js76x8-16m|\ > + jotale,js76x8-32m|\ > + jotale,js76x8-8m|\ Wrong alphabetic sorting here _______________________________________________ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel