aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ramips
Commit message (Collapse)AuthorAgeFilesLines
* ramips: Add support for ZTE ZXECS EBG3130 aka BDCOM WAP2100-SKPetr Štetiar2018-11-266-1/+149
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On the bottom sticker it's branded as ZTE ZXECS EBG3130 device, but in factory OpenWrt image it's referenced as BDCOM WAP2100-SK device. Specifications: - SoC: MediaTek MT7620A - RAM: 128 MB - Flash: 16 MB - Ethernet: 5 FE ports - Wireless radio: 2T2R 2.4 GHz and 1T1R 5 GHz (MT7610EN, unsupported) - UART: 1 x UART on PCB marked as J2 (R=RX, T=TX, G=GND) with 115200 8N1 config - LEDs: Power, FE ports 1-5, WPS, USB, RF 2.4G, RF 5G - Other: USB port, SD card slot and 2x external antennas (non-detachable) Flashing instructions: A) The U-Boot has HTTP based firmware upgrade A1) Flashing notes We've identified so far two different batches of units, unfortunately each batch has different U-Boot bootloader flashed with different default environment variables, thus each batch has different IP address for accessing web based firmware updater. * First batch has web based bootloader IP address 1.1.1.1 * Second batch has web based bootloader IP address 192.168.1.250 In case you can't connect to either of those IPs, you can try to get the default IP address via two methods: A1.1) Serial console, then the IP address is visible during the boot ... HTTP server is starting at IP: 1.1.1.1 raspi_read: from:40004 len:6 HTTP server is ready! ... A1.2) Over telnet/SSH using this command: root@bdcom:/# grep ipaddr= /dev/mtd0 ipaddr=1.1.1.1 A2) Flashing with browser * Change IP address of PC to 1.1.1.2 with 255.255.255.0 netmask * Reboot the device and try to reach web based bootloader in the browser with the following URL http://1.1.1.1 * Quickly select the firmware sysupgrade file and click on the `Update firmware` button, this all has to be done within 10 seconds, bootloader doesn't wait any longer If done correctly, the web page should show UPDATE IN PROGRESS page with progress indicator. Once the flashing completes (it takes roughly around 1 minute), the device will reboot to the OpenWrt firmware A3) Flashing with curl sudo ip addr add 1.1.1.2/24 dev eth0 curl \ --verbose \ --retry 3 \ --retry-delay 1 \ --retry-max-time 30 \ --connect-timeout 30 \ --form "firmware=@openwrt-ramips-mt7620-BDCOM-WAP2100-SK-squashfs-sysupgrade.bin" \ http://1.1.1.1 Now power on the router. B) The U-boot is based on Ralink SDK so we can flash the firmware using UART. 1. Configure PC with a static IP address and setup an TFTP server. 2. Put the firmware into the tftp directory. 3. Connect the UART line as described on the PCB (G=GND, R=RX, T=TX) 4. Power up the device and press 2, follow the instruction to set device and tftp server IP address and input the firmware file name. U-boot will then load the firmware and write it into the flash. Signed-off-by: Petr Štetiar <ynezz@true.cz>
* ramips: fix ethernet for f5d8235-v2 boardRoman Yeryomin2018-11-263-2/+14
| | | | | | | | | Belkin F5D8235 v2 has two ethernet switches on board. One internal rt3052 and rtl8366rb on rgmii interface. Looks like internal switch settings were lost in translation to device tree infrastructure. Signed-off-by: Roman Yeryomin <roman@advem.lv>
* ramips: add support for Skylab SKW92A in EVBRussell Senior2018-11-266-0/+143
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Specifically, SKW92A_E16, described here: http://www.skylabmodule.com/wp-content/uploads/SkyLab_SKW92A_V1.04_datasheet.pdf Specification: - MediaTek MT7628N/N (580 Mhz) - 64 MB of RAM - 16 MB of FLASH - 2T2R 2.4 GHz - 5x 10/100 Mbps Ethernet - 2x u.FL - Power by micro-USB connector at USB1 on EVB - UART via micro-USB connector at USB3 on EVB (57600 8n1) - 5x Ethernet LEDs - 1x WLAN LEDs - 1x WPS LED connected by jumper wire from I2S_CK on J20 to WPS_LED pin hole next to daughter board on EVB - WPS/Reset button (S2 on EVB) - RESET button (S1 on EVB) is *not* connected to RST hole next to daughter board Flash instruction: >From Skylab firmware: 1. Associate with SKYLAP_AP 2. In a browser, load: http://10.10.10.254/ 3. Username/password: admin/admin 4. In web admin interface: Administration / Upload Firmware, browse to sysupgrade image, apply, flash will fail with a message: Not a valid firmware. *** Warning: "/var/tmpFW" has corrupted data! 5. Telnet to 10.10.10.254, drops you into a root shell with no credentials 6. # cd /var 7. # mtd_write -r write tmpFW mtd4 Unlocking mtd4 ... Writing from tmpFW to mtd4 ... [e] 8. When flash has completed, you will have booted into your firmware. >From U-boot via TFTP and initramfs: 1. Place openwrt-ramips-mt76x8-skw92a-initramfs-kernel.bin on a TFTP server 2. Connect to serial console at USB3 on EVB 3. Connect ethernet between port 1 (not WAN) and your TFTP server (e.g. 192.168.11.20) 4. Start terminal software (e.g. screen /dev/ttyUSB0 57600) on PC 5. Apply power to EVB 6. Interrupt u-boot with keypress of "1" 7. At u-boot prompts: Input device IP (10.10.10.123) ==:192.168.11.21 Input server IP (10.10.10.3) ==:192.168.11.20 Input Linux Kernel filename (root_uImage) ==:openwrt-ramips-mt76x8-skw92a-initramfs-kernel.bin 8. Move ethernet to port 0 (WAN) on EVB 9. At new OpenWrt console shell, fetch squashfs-sysupgrade image and flash with sysupgrade. >From U-boot via TFTP direct flash: 1. Place openwrt-ramips-mt76x8-skw92a-squashfs-sysupgrade.bin on a TFTP server 2. Connect to serial console at USB3 on EVB (57600 8N1) 3. Connect ethernet between port 1 (not WAN) an your TFTP server (e.g. 192.168.11.20) 4. Start terminal software (e.g. screen /dev/ttyUSB0 57600) on PC 5. Apply power to EVB 6. Interrupt u-boot with keypress of "2" 7. At u-boot prompts: Warning!! Erase Linux in Flash then burn new one. Are you sure?(Y/N) Y Input device IP (10.10.10.123) ==:192.168.11.21 Input server IP (10.10.10.3) ==:192.168.11.20 Input Linux Kernel filename (root_uImage) ==:openwrt-ramips-mt76x8-skw92a-squashfs-sysupgrade.bin 8. When transfer is complete or as OpenWrt begins booting, move ethernet to port 0 (WAN). Signed-off-by: Russell Senior <russell@personaltelco.net>
* ramips: select kmod-mt76x0e for TP-Link ArcherC20i and wr902ac-v3Daniel Golle2018-11-252-1/+2
| | | | | | | | | Both devices come with a MediaTek MT7610E 5GHz 802.11ac 1T1R radio which wasn't supported at the time the devices were added to OpenWrt. Now that we got it, include kmod-mt76x0e in images for those devices. Reported-by: Arian Sanusi <openwrt@semioptimal.net> Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* ramips: use separated mtd patch reverting write_page() removalRafał Miłecki2018-11-092-29/+68
| | | | | | | This helps understanding mtd changes needed to get downstream NAND driver working. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* ramips: fix netgear r6120 factory image generationKoen Vandeputte2018-11-081-2/+2
| | | | | | | | | | | | | | | | | | | | | | | as indicated in commit c5bf408ed6bd "(ramips: fix image generation for mt76x8") more rework was needed to fix the other issues. Building on another machine, but using the same arch, showed the application failing again for different reasons. Fix this by completely rewriting the application, fixing following found issues: - buffer overflows, resulting in stack corruption - flaws in memory requirement calculations (too small, too large) - memory leaks - missing bounds checking on string handling - non-reproducable images, by using unitilized memory in checksum calculation - missing error handling, resulting in succes on specific image errors - endianness errors when building on BE machines - various minor build warnings - documentation did not match the code actions (header item locations) - allowing input to be decimal, hex or octal now Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
* ramips: add missing DTS frequency limit for the 5 GHz radio on Archer C20iFelix Fietkau2018-11-061-0/+1
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>
* kernel: bump 4.14 to 4.14.79Koen Vandeputte2018-11-056-11/+11
| | | | | | | | | Refreshed all patches. Compile-tested on: ar71xx, cns3xxx, imx6, x86_64 Runtime-tested on: ar71xx, cns3xxx, imx6, x86_64 Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
* ramips: fix leds on GL.iNet GL-MT300N-V2Martin Weinelt2018-11-022-1/+2
| | | | | | | The WAN LED now shows the link state. It's color is green, not blue. Signed-off-by: Martin Weinelt <hexa@darmstadt.ccc.de>
* kernel: Add support for Winbond w25q128jv SPI NOR flashBaptiste Jonglez2018-10-202-7/+7
| | | | | | | | | | | | | | | | | Newer batches of several Mikrotik boards contain this yet-unsupported flash chip, for instance: - rb941-2nd (hAP lite) - rb952ui-5ac2nd (hAP ac lite) - RBM33G and probably other Mikrotik boards need this patch as well. The patch was submitted upstream by Robert Marko: https://patchwork.ozlabs.org/patch/934181/ Closes: FS#1715 Signed-off-by: Baptiste Jonglez <git@bitsofnetworks.org> Cc: Robert Marko <robimarko@gmail.com>
* treewide: use wpad-basic for not small flash targetsMathias Kresin2018-10-164-32/+32
| | | | | | | | | | | | Add out of the box support for 802.11r and 802.11w to all targets not suffering from small flash. Signed-off-by: Mathias Kresin <dev@kresin.me> Mathias did all the heavy lifting on this, but I'm the one who should get shouted at for committing. Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
* ramips: refresh mt7621 kernel configFelix Fietkau2018-10-151-5/+29
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>
* kernel: bump 4.14 to 4.14.75Koen Vandeputte2018-10-101-1/+1
| | | | | | | | | Refreshed all patches. Compile-tested on: ar71xx, cns3xxx, imx6 Runtime-tested on: ar71xx, cns3xxx, imx6 Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
* ramips: don't hijack the status ledMathias Kresin2018-10-071-14/+0
| | | | | | | | | | Don't hijack the status led to indicate the wireless state. If we don't have a dedicated wireless led, it's as simply as the wireless status can't be indicated. Such a led misuse should be set by the user and not shipped by default. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: move status led unset to devicetreeMathias Kresin2018-10-078-25/+0
| | | | | | | Release the led used for boot status indication via devicetree instead of setting a default off trigger in userspace. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: add support for indicating the boot state using multiple ledsMathias Kresin2018-10-07214-217/+877
| | | | | | | | | Use diag.sh version used for other targets supporting different leds for the different boot states. The existing led sequences should be the same as before. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: set F5D8235 v1 usb led trigger via devicetreeMathias Kresin2018-10-072-5/+26
| | | | | | | Assign the usbdev trigger via devicetree and drop the userspace handling of the usb leds. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: set rt2880 pci controller of_nodeMathias Kresin2018-10-071-0/+32
| | | | | | | Set the PCI controller of_node such that PCI devices can be instantiated via device tree. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: set usb led trigger via devicetreeMathias Kresin2018-10-0770-80/+235
| | | | | | | | | | Assign the usbdev trigger via devicetree for all subtargets and drop the userspace handling of the usb leds. With the change all usb ports are triggering the usb led instead of only usb 1.1 XOR usb 2.0 XOR usb 3.0 as it was before. Signed-off-by: Mathias Kresin <dev@kresin.me>
* kernel: bump 4.14 to 4.14.74Koen Vandeputte2018-10-041-2/+2
| | | | | | | | | | | | | Refreshed all patches. Fixes CVE: - CVE-2018-7755 Compile-tested on: cns3xxx, imx6 Runtime-tested on: cns3xxx, imx6 Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
* ramips: fix Archer C20 sysupgradeSteffen Förster2018-09-261-1/+0
| | | | | | | | | | The sysupgrade image failed the check due to the wrong string in the supported devices. This patch provides the correct name by dropping the SUPPORTED_DEVICES to use the default generated name. Signed-off-by: Steffen Förster <steffen@chemnitz.freifunk.net> [drop the SUPPORTED_DEVICES, the old name was never used in a release] Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: fix power LED DTB for wt3020Emil Muratov2018-09-261-1/+1
| | | | | | | Since c134210 power LED is no longer lights after boot-up. Reversing gpio polarity makes it work as it should be. Signed-off-by: Emil Muratov <gpm@hotplug.ru>
* ramips: ex2700: actually remove kmod-mt76*Joseph C. Lehner2018-09-261-1/+1
| | | | | | | | | | | | | | When building using the multiple devices option with per-device root filesystem, only the meta package mt76 is omitted but not the dependencies selected by the package. Explicitly exclude all 3 mt76 packages, plus the metapackage. Otherwise, these modules will be included in the build, wasting a few hundred kilobytes. Signed-off-by: Joseph C. Lehner <joseph.c.lehner@gmail.com> [mention the root cause of the issue in the commit message] Signed-off-by: Mathias Kresin <dev@kresin.me>
* kernel: bump 4.14 to 4.14.70Koen Vandeputte2018-09-172-3/+3
| | | | | | | | | | | | | | | Refreshed all patches. Added new patch: - 192-Revert-ubifs-xattr-Don-t-operate-on-deleted-inodes.patch This fixes a bug introduced in upstream 4.14.68 which caused targets using ubifs to produce file-system errors on boot, rendering them useless. Compile-tested on: cns3xxx, imx6, x86_64 Runtime-tested on: cns3xxx, imx6, x86_64 Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
* ramips: Fix early memory calculation for certain MIPS platformsTobias Wolf2018-09-101-0/+45
| | | | | | | | | Kernel upstream commit 67a3ba25aa95 ("MIPS: Fix incorrect mem=X@Y handling") introduced a new issue for rt288x where "PHYS_OFFSET" is 0x0 but the calculated "ramstart" is not. As the prerequisite of custom memory map has been removed, this results in the full memory range of 0x0 - 0x8000000 to be marked as reserved for this platform. This patch adds the originally intended prerequisite again. Signed-off-by: Tobias Wolf <dev-NTEO@vplace.de>
* ramips: add support for TP-Link TL-MR3020 v3Carlo Nel2018-09-065-0/+165
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | TP-Link TL-MR3020 v3 is a pocket-size router based on MediaTek MT7628N. This PR is based on the work of @meyergru[1], with his permission. Specification: - MediaTek MT7628N/N (575 Mhz) - 64 MB of RAM - 8 MB of FLASH - 2T2R 2.4 GHz - 1x 10/100 Mbps Ethernet Flash instruction: The only way to flash the image in TL-MR3020 v3 is to use tftp recovery mode in U-Boot: 1. Configure PC with static IP 192.168.0.225/24 and tftp server. 2. Rename "openwrt-ramips-mt76x8-tplink_tl-mr3020-v3-squashfs-tftp-recovery.bin" to "tp_recovery.bin" and place it in tftp server directory. 3. Connect PC with the LAN port, press the reset button, power up the router and keep button pressed for around 6-7 seconds, until device starts downloading the file. 4. Router will download file from server, write it to flash and reboot. [1] https://github.com/meyergru/lede-source/commits/TL-MR3020-V3 Signed-off-by: Carlo Nel <carlojnel@gmail.com>
* ramips: drop obsolete sd card driver codeMathias Kresin2018-09-062-20/+4
| | | | | | | | | | | | | | | | | The pinmux for all SoCs using this driver is now set via the pinmux. It makes this code obsolete. Some of the code targeting the mt76x8 SoCs is still required. The sd card pins share the pads with the EPHY. These pads need to be switched to digital mode if the pins are used for sd cards. The eMMC 8-bit mode has to be enabled via pinmux instead of a kernel option. The uart2 group need to be set to function "sdxc d5 d4", pwm1 to "sdxc d6" and pwm0 to "sdxc d7" to do so. It can't be done by as part of a default pinmux, as it would break the normal operation of uart2. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: add mt7620/1 sdhci pinmuxMathias Kresin2018-09-068-16/+13
| | | | | | | Set the pins to the required mode via the pinmux driver. It allows to get rid of the pinmux related code in the sd card driver. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: fix mt7620a ND/SD pins pinmuxesMathias Kresin2018-09-064-4/+4
| | | | | | | | | | Drop the nd_sd gpio pinmux in case sdcard is used. They're mutually exclusive and for most of the boards not even used as GPIOs. If the pins are in sdcard mode, the pins ND_WE_N and ND_CS_N are still GPIOs (#45 and #46). Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: reference node by labelMathias Kresin2018-09-061-4/+4
| | | | | | Reference the HC5661A sdhci node by label instead of by the full path. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: add rt3352 SPI_CS1 pinmuxMathias Kresin2018-09-061-0/+45
| | | | | | | | The rt3352 has a pin that can be used as second spi chip select, watchdog reset or GPIO. The pinmux setup was missing the definition of said pin but it is already used in the SoC dtsi. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: ethernet: unify tx descriptor buffer splittingFelix Fietkau2018-09-031-75/+83
| | | | | | | | A buffer is split into multiple descriptors if it exceeds 16 KB. Apply the same split for the skb head as well (to deal with corner cases on fraglist support) Signed-off-by: Felix Fietkau <nbd@nbd.name>
* Revert "ramips: mmc: Fix init for MT7628AN"Jo-Philipp Wich2018-08-302-16/+1
| | | | | | | | | | This reverts commit 3a8efaef00d6b7317c46fe6b7e923912d8bf3500. The change reportedly breaks UART2 on some boards. Furthermore it uses bitwise logic on an uninitialized variable and fails to explain what it is fixing exactly. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* ramips: only limit lzma dictionary size on mt7621Jo-Philipp Wich2018-08-302-1/+2
| | | | | | | | | | | | | The changed dictionary size leads to a different LZMA header which breaks sysupgrade image magic checkibng on at least some RT288x boards. Since the commit message only mentions testing on MT7621 and since the change appears to break at least one other ramips subtarget, do not take any chances and restrict the size limitation to only MT7621. Fixes FS#1797 Fixes 09b6755946 ("ramips: limit dictionary size for lzma compression") Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* ramips: fix rt3883 pinmux for second SPIMathias Kresin2018-08-291-2/+2
| | | | | | | The rt3883 doesn't have a pinmux group named spi_cs1. The cs1 is part of the pci group. The function pci-func enables the second chip select. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: fix rt3883 pci pinmuxMathias Kresin2018-08-291-1/+1
| | | | | | | | | | The PCI pins need to be set to "PCI Host support one device" to allow the use of one PCI device and flash memory. The pci-fnc function is intended to be used if no PCI is used but flash, nand or the codec functionality is. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: drop pointless default led definitionsMathias Kresin2018-08-291-17/+0
| | | | | | | | | | | | | | | | The LEDs should be triggered/lit by any kind of state change instead of turned on/off unconditional. If LEDs really need to be turned off by default, it should be done via the default-state devicetree led property. The handling of the wndr3700v5 and wt3020 power led is at least strange. Something is for sure wrong with them. Either the leds are misnamed, the default off trigger is a typo or the polarity of the gpios is wrong. Drop the power led from userspace and wait for someone with access to the hardware to fix it properly. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: add missing zbt-cpe102 diag ledMathias Kresin2018-08-291-1/+6
| | | | | | | Based on the userspace led configuration it's quite obvious that the 4g-0 led should be used for boot status indication. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: express diag led handling via devicetreeMathias Kresin2018-08-296-9/+12
| | | | | | | Use the default-state property to express the desired led handling in the devicetree source file instead of the userspace. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: remove default on userspace trigger for diag ledsMathias Kresin2018-08-291-34/+0
| | | | | | | All the LEDs are turned on by diag.sh at the end of the boot process. No need to do the same via userspace configuration again. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: fix multi colour led handlingMathias Kresin2018-08-295-13/+14
| | | | | | | | All boards either have a multi colour led or a single lightpipe. It makes it impossible to handle the LEDs individual. Change the LED config for these boards to take it into account. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: rt-n12p: use the boardname helper variableMathias Kresin2018-08-291-4/+4
| | | | | | | Use the helper variable for the Asus RT-N12P as it is done by all boards. Signed-off-by: Mathias Kresin <dev@kresin.me>
* kernel: bump 4.14 to 4.14.67Koen Vandeputte2018-08-281-1/+1
| | | | | | | | | | | | Refreshed all patches. Removed upstreamed patches: - 037-v4.18-0008-ARM-dts-BCM5301x-Fix-i2c-controller-interrupt-type.patch Compile-tested on: cns3xxx, imx6 Runtime-tested on: cns3xxx, imx6 Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
* treewide: fix some cosmetic glitches in dts filesPaul Wassi2018-08-2714-20/+4
| | | | | | | | | | | - fix single spaces hidden by a tab - replace indentation with spaces by tabs - make empty lines empty - drop trailing whitespace - drop unnecessary blank lines Signed-off-by: Mathias Kresin <dev@kresin.me> Signed-off-by: Paul Wassi <p.wassi@gmx.at>
* ramips: fix mt7620 pinmux for second SPIMathias Kresin2018-08-272-4/+4
| | | | | | | | | | | The mt7620 doesn't have a pinmux group named spi_cs1. The cs1 is part of the "spi refclk" group. The function "spi refclk" enables the second chip select. On reset, the pins of the "spi refclk" group are used as reference clock and GPIO. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ramips: fix RBM11G partitioningThibaut VARÈNE2018-08-241-9/+36
| | | | | | | | | | | | | | | | | | | | | | | | | This patch improves faf64056ddd46992a75b1e277d94541c7251035c by correcting the partition scheme for the "RouterBoot" section of the flash. The partition scheme initially submitted is incorrect and does not reflect the actual flash structure. The "RouterBoot" section (name matching OEM) is subdivided in several static segments, as they are on ar71xx RB devices albeit with different offsets and sizes. The naming convention from ar71xx has been preserved, except for the bootloaders which are named "bootloader1" and "bootloader2" to avoid confusion with the master "RouterBoot" partition. The preferred 'fixed-partitions' DTS node syntax is used, with nesting support as introduced in 2a598bbaa3. "partition" is used for node names, with associated "label" to match policy set by 6dd94c2781. Leave a note in DTS to explain how the original author selected the SPI speed. Tested-by: Tobias Schramm <tobleminer@gmail.com> Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org> Reviewed-by: Rafał Miłecki <rafal@milecki.pl>
* ramips: fix RBM33G partitioningThibaut VARÈNE2018-08-241-9/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch improves 5684d087418d176cfdef4e045e1950ca7ba3b09f by correcting the partition scheme for the "RouterBoot" section of the flash. The partition scheme initially submitted is incorrect and does not reflect the actual flash structure. The "RouterBoot" section (name matching OEM) is subdivided in several static segments, as they are on ar71xx RB devices albeit with different offsets and sizes. The naming convention from ar71xx has been preserved, except for the bootloaders which are named "bootloader1" and "bootloader2" to avoid confusion with the master "RouterBoot" partition. The preferred 'fixed-partitions' DTS node syntax is used, with nesting support as introduced in 2a598bbaa3. "partition" is used for node names, with associated "label" to match policy set by 6dd94c2781. The OEM source code also define a "RouterBootFake" partition at the beginning of the secondary flash chip: to avoid trouble if OEM ever makes use of that space, it is also defined here. The resulting partition scheme looks like this: [ 10.114241] m25p80 spi0.0: w25x40 (512 Kbytes) [ 10.118708] 1 fixed-partitions partitions found on MTD device spi0.0 [ 10.125049] Creating 1 MTD partitions on "spi0.0": [ 10.129824] 0x000000000000-0x000000040000 : "RouterBoot" [ 10.136215] 5 fixed-partitions partitions found on MTD device RouterBoot [ 10.142894] Creating 5 MTD partitions on "RouterBoot": [ 10.148032] 0x000000000000-0x00000000f000 : "bootloader1" [ 10.154336] 0x00000000f000-0x000000010000 : "hard_config" [ 10.160665] 0x000000010000-0x00000001f000 : "bootloader2" [ 10.167046] 0x000000020000-0x000000021000 : "soft_config" [ 10.173461] 0x000000030000-0x000000031000 : "bios" [ 10.190191] m25p80 spi0.1: w25q128 (16384 Kbytes) [ 10.194950] 2 fixed-partitions partitions found on MTD device spi0.1 [ 10.201271] Creating 2 MTD partitions on "spi0.1": [ 10.206071] 0x000000000000-0x000000040000 : "RouterBootFake" [ 10.212746] 0x000000040000-0x000001000000 : "firmware" [ 10.307216] 2 minor-fw partitions found on MTD device firmware [ 10.313044] 0x000000040000-0x000000220000 : "kernel" [ 10.319002] 0x000000220000-0x000001000000 : "rootfs" [ 10.324906] mtd: device 9 (rootfs) set to be root filesystem [ 10.330678] 1 squashfs-split partitions found on MTD device rootfs [ 10.336886] 0x000000b40000-0x000001000000 : "rootfs_data" Leave a note in DTS to explain how the original author selected the SPI speed. Tested-by: Tobias Schramm <tobleminer@gmail.com> Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org> Reviewed-by: Rafał Miłecki <rafal@milecki.pl> [rmilecki: dropped "RouterBootFake" partition] Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* ramips: mt7620: add dir-810l network configRoger Pueyo Centelles2018-08-231-0/+1
| | | | | | | The device was not included in the /etc/board.d/02_network file, so the network wouldn't be properly set up on boot. Signed-off-by: Roger Pueyo Centelles <roger.pueyo@guifi.net>
* ramips: add support for ELECOM WRC-1900GSTNOGUCHI Hiroshi2018-08-236-172/+200
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ELECOM WRC-1900GST is a wireless router, based on Mediatek MT7621A. This is almost same as WRC-2533GST except wireless specs. Specifications: - SoC : MT7621A (four logical CPU cores) - RAM : 128MiB - ROM : 16MiB of SPI NOR-FLASH - wireless : 5GHz : 3T3R up to 1300Mbps/11ac with MT7615 2.4GHz : 3T3R up to 600Mbps/11n with MT7615 - Ethernet : 5 ports, all ports is capable of 1000base-T - Ether switch : MT7530 (MT7621A built-in) - LEDs : 4 LEDs - buttons : 2 buttons and 1 slide-switch - UART : header is on PCB, 57600bps Flash instruction using factory image: 1. Connect the computer to the LAN port of WRC-1900GST 2. Connect power cable to WRC-1900GST and turn on it 3. Access to "https://192.168.2.1/" and open firmware update page ("ファームウェア更新") 4. Select the OpenWrt factory image and click apply ("適用") button 5. Wait ~150 seconds to complete flashing Signed-off-by: NOGUCHI Hiroshi <drvlabo@gmail.com>
* ramips: fix compatibles in SoC dtsiMathias Kresin2018-08-233-3/+3
| | | | | | | The former used compatibles aren't defined anywhere and aren't used by the devicetree source files including them. Signed-off-by: Mathias Kresin <dev@kresin.me>