1. 18 12月, 2022 22 次提交
    • H
      tools/sed: Fix handling of symlinks of 128 chars · c2000ebf
      Hauke Mehrtens 提交于
      If the absolute path a symlink is pointing to is 128 bytes long sed
      failed with an error message like this: "<path>/sedstbU8O: Not a directory"
      
      This fixes a problem building python seen in the build bot.
      
      This patch is on its way into upstream sed.
      Signed-off-by: NHauke Mehrtens <hauke@hauke-m.de>
      c2000ebf
    • O
      image-commands.mk: Be consistent in command invocation · 47df168d
      Olliver Schinagl 提交于
      Most/all other tools use the staging dir prefix, gzip should as well.
      Signed-off-by: NOlliver Schinagl <oliver@schinagl.nl>
      Acked-by: NChristian Marangi <ansuelsmth@gmail.com>
      47df168d
    • A
      ramips: add support for SNR-CPE-W4N-MT router · 3f201d1f
      Alexey Bartenev 提交于
      General specification:
      - SoC Type: MediaTek MT7620N (580MHz)
      - ROM: 8 MB SPI-NOR (W25Q64FV)
      - RAM: 64 MB DDR (M13S5121632A)
      - Switch: MediaTek MT7530
      - Ethernet: 5 ports - 5×100MbE (WAN, LAN1-4)
      - Wireless 2.4 GHz: b/g/n
      - Buttons: 1 button (RESET)
      - Bootloader: U-Boot 1.1.3, MediaTek U-Boot: 5.0.0.5
      - Power: 12 VDC, 1.0 A
      
      Flash by the native uploader in 2 stages:
      1. Use the native uploader to flash an initramfs image. Choose
       openwrt-ramips-mt7620-snr_cpe-w4n-mt-initramfs-kernel.bin file by
       "Administration/Management/Firmware update/Choose File" in vendor's
       web interface (ip: 192.168.1.10, login: Admin, password: Admin).
       Wait ~160 seconds.
      2. Flash a sysupgrade image via the initramfs image. Choose
       openwrt-ramips-mt7620-snr_cpe-w4n-mt-squashfs-sysupgrade.bin
       file by "System/Backup/Flash Firmware/Flash image..." in
       LuCI web interface (ip: 192.168.1.1, login: root, no password).
       Wait ~240 seconds.
      
      Flash by U-Boot TFTP method:
      1. Configure your PC with IP 192.168.1.131
      2. Set up TFTP server and put the
       openwrt-ramips-mt7620-snr_cpe-w4n-mt-squashfs-sysupgrade.bin
       image on your PC
      3. Connect serial port (57600 8N1) and turn on the router.
       Then interrupt "U-Boot Boot Menu" by hitting 2 key (select "2:
       Load system code then write to Flash via TFTP.").
      Press Y key when show "Warning!! Erase Linux in Flash then burn
       new one. Are you sure? (Y/N)"
      Input device IP (192.168.1.1) ==:192.168.1.1
      Input server IP (192.168.1.131) ==:192.168.1.131
      Input Linux Kernel filename () ==:
      openwrt-ramips-mt7620-snr_cpe-w4n-mt-squashfs-sysupgrade.bin
      3. Wait ~120 seconds to complete flashing
      Signed-off-by: NAlexey Bartenev <41exey@proton.me>
      3f201d1f
    • H
      gdb: Do not link against xxhash · a442974c
      Hauke Mehrtens 提交于
      libxxhash is now available in the OpenWrt package feed and gdb will link
      against it if gdb finds this library. Explicitly deactivate the usage
      of xxhash.
      
      This should fix the build of gdb in build bots.
      Signed-off-by: NHauke Mehrtens <hauke@hauke-m.de>
      a442974c
    • D
      ath79: add support for KuWFi C910 · d9566d05
      Davide Fioravanti 提交于
      KuWFi C910 is an 802.11n (300N) indoor router with LTE support.
      
      I can't find anywhere the OEM firmware. So if you want to restore the
      original firmware you must do a dump before the OpenWrt flash.
      
      According to the U-Boot, the board name is Iyunlink MINI_V2.
      
      Hardware
      --------
      SoC:   Qualcomm QCA9533 650/400/200/25/25 MHz (CPU/RAM/AHB/SPI/REF)
      RAM:   128 MB DDR2 16-bit CL3-4-4-10 (Nanya NT5TU64M16HG-AC)
      FLASH: 16 MB Winbond W25Q128
      ETH:
        - 2x 100M LAN (QCA9533 internal AR8229 switch, eth0)
        - 1x 100M WAN (QCA9533 internal PHY, eth1)
      WIFI:
        - 2.4GHz: 1x QCA9533 2T2R (b/g/n)
        - 2 external non detachable antennas (near the power barrel side)
      LTE:
        - Quectel EC200T-EU (or -CN or -AU depending on markets)
        - 2 external non detachable antennas (near the sim slot side)
      BTN:
        - 1x Reset button
      LEDS:
        - 5x White leds (Power, Wifi, Wan, Lan1, Lan2)
        - 1x RGB led (Internet)
      UART: 115200-8-N-1 (Starting from lan ports in order: GND, RX, TX, VCC)
      
      Everything works correctly.
      
      MAC Addresses
      -------------
      LAN XX:XX:XX:XX:XX:48 (art@0x1002)
      WAN XX:XX:XX:XX:XX:49 (art@0x1002 + 1)
      WIFI XX:XX:XX:XX:XX:48
      
      LABEL XX:XX:XX:XX:XX:48
      
      Installation
      ------------
      Turn the router on while pressing the reset button for 4 seconds.
      You can simply count the flashes of the first lan led. (See notes)
      If done correctly you should see the first lan led glowing slowly and
      you should be able to enter the U-Boot web interface.
      
      Click on the second tab ("固件") and select the -factory.bin firmware
      then click "Update firmware".
      
      A screen "Update in progress" should appear.
      
      After few minutes the flash should be completed.
      
      This procedure can be used also to recover the router in case of soft
      brick.
      
      Backup the original firmware
      ----------------------------
      The following steps are intended for a linux pc. However using the
      right software this guide should also work for Windows and MacOS.
      
      1) Install a tftp server on your pc. For example tftpd-hpa.
      
      2) Create two empty files in your tftp folder called:
      	kuwfi_c910_all_nor.bin
      	kuwfi_c910_firmware_only.bin
      
      3) Give global write permissions to these files:
      	chmod 666 kuwfi_c910_all_nor.bin
      	chmod 666 kuwfi_c910_firmware_only.bin
      
      4) Start a netcat session on your pc with this command:
      	nc -u -p 6666 192.168.1.1 6666
      
      5) Set the static address on your pc: 192.168.1.2. Connect the router
      	to your pc.
      
      6) Turn the router on while pressing the reset button for 8-9 seconds.
      	You can simply count the flashes of the first lan led. If you
      	press the reset button for too many seconds it will continue
      	the normal boot, so you have to restart the router. (See notes)
      
      7) If done correctly you should see the U-Boot network console and you
      	should see the following lines on the netcat session:
      Version and build date:
        U-Boot 1.1.4-55f1bca8-dirty, 2020-05-07
      
      Modification by:
        Piotr Dymacz <piotr@dymacz.pl>
        https://github.com/pepe2k/u-boot_mod
      
      u-boot>
      
      8) Start the transfer of the whole NOR:
      	tftpput 0x9f000000 0x1000000 kuwfi_c910_all_nor.bin
      
      9) The router should start the transfer and it should end with a
      	message like this (pay attention to the bytes transferred):
      TFTP transfer complete!
      
      Bytes transferred: 16777216 (0x1000000)
      
      10) Repeat the same transfer for the firmware:
      	tftpput 0x9f050000 0xfa0000 kuwfi_c910_firmware_only.bin
      
      11) The router should start the transfer and it should end with a
      	message like this (pay attention to the bytes transferred):
      TFTP transfer complete!
      
      Bytes transferred: 16384000 (0xfa0000)
      
      12) Now you have the backup for the whole nor and for the firmware
      	partition. If you want to restore the OEM firmware from OpenWrt
      	you have to flash the kuwfi_c910_firmware_only.bin from the
      	U-Boot web interface.
      
      	WARNING: Don't use the kuwfi_c910_all_nor.bin file. This file
      	is only useful if you manage to	hard brick the router or you
      	damage the art partition (ask on the forum)
      
      Notes
      -----
      This router (or at least my unit) has the pepe2k's U-Boot. It's a
      modded U-Boot version with a lot of cool features. You can read more
      here: https://github.com/pepe2k/u-boot_mod
      
      With this version of U-Boot, pushing the reset button while turning on
      the router starts different tools:
       - 3-5 seconds: U-Boot web interface that can be used to replace the
       	firmware, the art or the U-Boot itself
       - 5-7 seconds: U-Boot uart console
       - 7-10 seconds: U-Boot network console
       - 11+ seconds: Normal boot
      
      The LTE modem can be used in cdc_ether (ECM) or RNDIS mode.
      The default mode is ECM and in this commit only the ECM software is
      included. In order to set RNDIS mode you must use this AT command:
      	AT+QCFG="usbnet",3
      In order to use again the ECM mode you must use this AT command:
      	AT+QCFG="usbnet",1
      
      Look for "Quectel_EC200T_Linux_USB_Driver_User_Guide_V1.0.pdf" for
      other AT commands
      Signed-off-by: NDavide Fioravanti <pantanastyle@gmail.com>
      d9566d05
    • S
      ramips: improve support for SIM SIMAX1800T and Haier HAR-20S2U1 · 6361a952
      Shiji Yang 提交于
      1. Use ARTIFACTS to build factory image. This change allows users to
         generate initramfs factory image using OpenWrt ImageBuilder.
      
      2. Override the default bootargs property defined in "mt7621.dtsi".
         Although we use the "bootargs-override" property to set bootargs,
         the default "bootargs" property will still be written into the
         device tree, so it is better to override it.
      
      Tested on SIM SIMAX1800T
      Signed-off-by: NShiji Yang <yangshiji66@qq.com>
      6361a952
    • S
      ramips: improve support for H3C TX180x series devices · a7d8b54f
      Shiji Yang 提交于
      1. Explicitly declare gpio pin groups to ensure that gpio works properly.
      
      2. Override bootargs in device tree to avoid modifying u-boot envs during
         initial installation.
      
      Tested on H3C TX1801 Plus
      Signed-off-by: NShiji Yang <yangshiji66@qq.com>
      a7d8b54f
    • C
      sunxi: fix board_name for MarsBoard A10 · 53123b93
      Chukun Pan 提交于
      The compatible in the device tree is "haoyu,a10-marsboard",
      modify the board_name to keep it consistent.
      Signed-off-by: NChukun Pan <amadeus@jmu.edu.cn>
      53123b93
    • C
      sunxi: fix typo in device packages for MarsBoard A10 · 7bcf6b54
      Chukun Pan 提交于
      The kmod prefix for sound-soc-sunxi is missing, fix it.
      Also add kmod-sound-core as dependence.
      
      Fixes: 6a356598 ("sunxi: Added profile for HAOYU Electronics Marsboard A10")
      Signed-off-by: NChukun Pan <amadeus@jmu.edu.cn>
      7bcf6b54
    • N
      ath79: convert WiFis based on ar7241_ubnt_unifi.dtsi to nvmem-cells · af5306ba
      Nick Hainke 提交于
      Pull the calibration data from the nvmem subsystem. This allows us to
      move userspace caldata extraction into the device-tree definition.
      
      While working on it remove stale uboot partition label and merge art
      into partition node.
      Signed-off-by: NNick Hainke <vincent@systemli.org>
      af5306ba
    • N
      ath79: convert Buffalo WZR-HP-G302H A1A0 WiFis to nvmem-cells · b7ad3c5c
      Nick Hainke 提交于
      Pull the calibration data from the nvmem subsystem. This allows us to
      move userspace caldata extraction into the device-tree definition.
      
      Merge art into partition node.
      Signed-off-by: NNick Hainke <vincent@systemli.org>
      b7ad3c5c
    • N
      ath79: convert OpenMesh OM2P v1 WiFis to nvmem-cells · d4ec4f9d
      Nick Hainke 提交于
      Pull the calibration data from the nvmem subsystem. This allows us to
      move userspace caldata extraction into the device-tree definition.
      
      Merge art into partition node.
      Signed-off-by: NNick Hainke <vincent@systemli.org>
      d4ec4f9d
    • N
      ath79: convert OpenMesh OM5P-AN WiFis to nvmem-cells · f6ca84bf
      Nick Hainke 提交于
      Pull the calibration data from the nvmem subsystem. This allows us to
      move userspace caldata extraction into the device-tree definition.
      
      Merge art into partition node.
      Signed-off-by: NNick Hainke <vincent@systemli.org>
      f6ca84bf
    • N
      ath79: convert boards based on ar9344_openmesh_mr600.dtsi to nvmem-cells · 46077860
      Nick Hainke 提交于
      Pull the calibration data from the nvmem subsystem. This allows us to
      move userspace caldata extraction into the device-tree definition.
      
      Merge art into partition node.
      Signed-off-by: NNick Hainke <vincent@systemli.org>
      46077860
    • N
      strace: update to 6.1 · 74b7d696
      Nick Hainke 提交于
      Release Notes:
      https://github.com/strace/strace/releases/tag/v6.1Signed-off-by: NNick Hainke <vincent@systemli.org>
      74b7d696
    • L
      tools/bash: update to 5.2.15 · fc47874e
      Linhui Liu 提交于
      Update to the latest released version.
      Signed-off-by: NLinhui Liu <liulinhui36@gmail.com>
      fc47874e
    • N
      trace-cmd: update to v3.1.5 · 95ed519b
      Nick Hainke 提交于
      Update to latest release.
      Signed-off-by: NNick Hainke <vincent@systemli.org>
      95ed519b
    • N
      libtracefs: update to 1.6.3 · b5d317f4
      Nick Hainke 提交于
      Update to latest release.
      Signed-off-by: NNick Hainke <vincent@systemli.org>
      b5d317f4
    • N
      libtraceevent: update to 1.7.0 · b01f2d9f
      Nick Hainke 提交于
      Update to latest release.
      Signed-off-by: NNick Hainke <vincent@systemli.org>
      b01f2d9f
    • H
      kernel: Make use of KERNEL_MAKE · 243a7256
      Hauke Mehrtens 提交于
      Make use of KERNEL_MAKE in kernel packages were easily possible.
      This moves some more code to common places and reduces the number of
      lines.
      
      It is defined like this:
      KERNEL_MAKE = $(MAKE) $(KERNEL_MAKEOPTS)
      KERNEL_MAKEOPTS = -C $(LINUX_DIR) $(KERNEL_MAKE_FLAGS)
      Signed-off-by: NHauke Mehrtens <hauke@hauke-m.de>
      243a7256
    • H
      kernel: Make KERNEL_MAKEOPTS recursively expanded · 06ad3ade
      Hauke Mehrtens 提交于
      KERNEL_MAKEOPTS will get expanded when it is used and not when it is
      defined in the kernel.mk file now. This fixes problems finding dependent
      kernel modules when it is used by a kernel module package.
      
      Without this change the build of packages which depend on other out of
      tree modules failed when they used KERNEL_MAKE because some symbols could
      not be found. This happened because KERNEL_MAKE_FLAGS which contains a
      "if $(__package_mk)" was  evaluated where KERNEL_MAKEOPTS was defined
      and not when the KERNEL_MAKE was used. For packages which included
      kernel.mk before package.mk we saw this problem. One workaround
      was to use the correct include order and the other one was to not
      use KERNEL_MAKE_FLAGS, but copy its content.
      Signed-off-by: NHauke Mehrtens <hmehrtens@maxlinear.com>
      06ad3ade
    • L
      tools/mpc: update to 1.3.1 · 46092284
      Linhui Liu 提交于
      Version 1.3.1 new features:
      	Bug fix: It is again possible to include mpc.h without including stdio.h.
      Version 1.3.0 new features:
          New function: mpc_agm
          New rounding modes "away from zero", indicated by the letter "A" and corresponding to MPFR_RNDA on the designated real or imaginary part.
          New experimental ball arithmetic.
          New experimental function: mpc_eta_fund
          Bug fixes:
              mpc_asin for asin(z) with small |Re(z)| and tiny |Im(z)|
              mpc_pow_fr: sign of zero part of result when the base has up to sign the same real and imaginary part, and the exponent is an even positive integer
              mpc_fma: the returned int value was incorrect in some cases (indicating whether the rounded real/imaginary parts were smaller/equal/greater than the exact values), but the computed complex value was correct.
          Remove the unmaintained Makefile.vc; build files for Visual Studio are maintained independently by Brian Gladman.
      Signed-off-by: NLinhui Liu <liulinhui36@gmail.com>
      46092284
  2. 17 12月, 2022 6 次提交
    • L
    • C
      mediatek: redmi-ax6000: drop cs-gpios · 7fb32285
      Chuanhong Guo 提交于
      'cs-gpios = <0>, <0>' is a hack in ath79 to override the incorrectly
      specified maximum number of chipselects available in spi-ath79.c.
      It's not needed here and must have been copied here by mistake.
      Signed-off-by: NChuanhong Guo <gch981213@gmail.com>
      7fb32285
    • C
      mediatek: add alternative stock layout for Xiaomi Redmi Router AX6000 · 18bea173
      Chen Minqiang 提交于
      In this implementation, the flash partition layout is adjusted to avoid
      modifying the uboot environment of mtdparts. This ensures that the 30M
      ubi_kernel partition remains aligned with the stock ubi partition, and
      the kernel volume is placed in it. This allows the stock uboot to boot
      from it without changing the mtdparts, which is useful for reverting back
      to the stock firmware using Xiaomi Firmware Tools. In actual testing,
      modifying mtdparts has been found to break Xiaomi Firmware Tools.
      
      1. use ARTIFACTS to generate initramfs-factory.ubi for easy installation.
      2. The NAND flash layout is changed to allow for reverting back to the
         stock firmware.
      3. Before performing sysupgrade, do some cleanup in platform_pre_upgrade
         to ensure a clean installation of OpenWRT.
      4. Setup the uboot env to ensure that the system always boot, which can
         be helpful for users who may forget to do this before sysupgrade in
         the initramfs.
      
      New flash instructions:
      1. Gain ssh access. Please refer to:
         https://openwrt.org/toh/xiaomi/redmi_ax6000#installation)
      
      2. Check which system current u-boot is loading from:
         COMMAND: `cat /proc/cmdline`
         sample OUTPUT: `console=ttyS0,115200n1 loglevel=8 firmware=1 uart_en=1`
         if firmware=1, current system is ubi1
         if firmware=0, current system is ubi0
      
      3. Setup nvram and write the firmware:
         If the current system is ubi1, please set it up so that the next time
         it will boot from ubi, and write the firmware to ubi:
      ```
      nvram set boot_wait=on
      nvram set uart_en=1
      nvram set flag_boot_rootfs=0
      nvram set flag_last_success=0
      nvram set flag_boot_success=1
      nvram set flag_try_sys1_failed=0
      nvram set flag_try_sys2_failed=0
      nvram commit
      ubiformat /dev/mtd8 -y -f /tmp/initramfs-factory.ubi
      ```
         If the current system is ubi, please set it up so that the next time
         it will boot from ubi1, and write the firmware to ubi1:
      ```
      nvram set boot_wait=on
      nvram set uart_en=1
      nvram set flag_boot_rootfs=1
      nvram set flag_last_success=1
      nvram set flag_boot_success=1
      nvram set flag_try_sys1_failed=0
      nvram set flag_try_sys2_failed=0
      nvram commit
      ubiformat /dev/mtd9 -y -f /tmp/initramfs-factory.ubi
      ```
      
      4. After rebooting, the system should now boot into the openwrt initramfs.
         Flash the squashfs-sysupgrade.bin via using ssh or luci.
      ```
      sysupgrade -n /tmp/squashfs-sysupgrade.bin
      ```
      Done.
      
      For existing users of the Redmi AX6000 running OpenWrt, here are the steps to
      switch to this new layout:
      
      1. Flash initramfs-factory.ubi
      ```
      mtd -r -e ubi write /tmp/initramfs-factory.ubi ubi
      ```
      
      2. After rebooting, the system will boot into the new openwrt-initramfs.
      Log in and perform a sysupgrade to complete the process.
      ```
      sysupgrade -n /tmp/squashfs-sysupgrade.bin
      ```
      Signed-off-by: NChen Minqiang <ptpt52@gmail.com>
      Signed-off-by: NChuanhong Guo <gch981213@gmail.com>
      18bea173
    • C
      base-files: sysupgrade-tar: allow separated kernel/rootfs ubi · 189637c9
      Chuanhong Guo 提交于
      There are some devices putting kernel and rootfs on separated
      ubi volumes. To make OpenWrt compatible with their bootloader,
      we need to put kernel and rootfs into separated ubi volumes.
      Add support for CI_KERN_UBIPART and CI_ROOT_UBIPART for this
      situation.
      Signed-off-by: NChuanhong Guo <gch981213@gmail.com>
      189637c9
    • C
      base-files: split ubi attaching out of nand_upgrade_prepare_ubi · c48e511f
      Chuanhong Guo 提交于
      split ubi reformat/attach into nand_attach_ubi in preparation
      for reusing this code in other functions.
      Signed-off-by: NChuanhong Guo <gch981213@gmail.com>
      c48e511f
    • C
      generic: add support for EON EN25QX128A spi nor flash · d7876daf
      Christian Marangi 提交于
      Add support for EON EN25QX128A spi nor flash with no flags as it does
      support SFDP parsing.
      
      Fixes: #9442
      Signed-off-by: NChristian Marangi <ansuelsmth@gmail.com>
      Tested-by: Szabolcs Hubai <szab.hu@gmail.com> [ramips/mt7621: xiaomi_mi-router-4a-gigabit]
      d7876daf
  3. 16 12月, 2022 12 次提交