Use options from generic instead of target-specific,
as the bootargs are now passed by the bootloader
and can be device-specific
Signed-off-by: Luis Araneda <luaraneda@gmail.com>
The bump to 4.14 changed the way mdio probes behind switches.
While the board_info is added to the list, the code that actually inserted
the list info into the phydev structure was missing.
This resulted in non-working ethernet ports.
Re-add it to fix switch probing.
This mimics the exact behaviour as it was in kernel 4.9.
Before:
[ 1.066007] switch0: Atheros AR8327 rev. 4 switch registered on ag71xx-mdio.0
[ 1.073409] Atheros AR8216/AR8236/AR8316: probe of ag71xx-mdio.0:00 failed with error -22
[ 1.102455] libphy: ag71xx_mdio: probed
[ 1.737938] ag71xx ag71xx.0: connected to PHY at ag71xx-mdio.0:00 [uid=004dd034, driver=Generic PHY]
[ 1.747994] eth0: Atheros AG71xx at 0xb9000000, irq 4, mode:RGMII
[ 2.377642] ag71xx-mdio.1: Found an AR934X built-in switch
[ 2.429938] eth1: Atheros AG71xx at 0xba000000, irq 5, mode:GMII
After:
[ 11.163357] libphy: Fixed MDIO Bus: probed
[ 11.319898] libphy: ag71xx_mdio: probed
[ 11.360844] switch0: Atheros AR8327 rev. 4 switch registered on ag71xx-mdio.0
[ 12.447398] libphy: ag71xx_mdio: probed
[ 13.077402] ag71xx ag71xx.0: connected to PHY at ag71xx-mdio.0:00 [uid=004dd034, driver=Atheros AR8216/AR8236/AR8316]
[ 13.088989] eth0: Atheros AG71xx at 0xb9000000, irq 4, mode:RGMII
[ 13.717716] ag71xx-mdio.1: Found an AR934X built-in switch
[ 13.769990] eth1: Atheros AG71xx at 0xba000000, irq 5, mode:GMII
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
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>
Without "syscon" being present in an ag71xx ethernet DT node's
compatible property, a panic occurs at boot during probe citing
"Unhandled kernel unaligned access".
With this modification, the panic no longer occurs and instead the probe
simply fails, allowing the boot process to continue.
Signed-off-by: Matt Merhar <mattmerhar@protonmail.com>
This adds "syscon" to the compatible properties for the eth0/eth1 nodes
in ar7100.dtsi.
Without this, a kernel panic is encountered on boot with some ar7100
boards. This for some reason wasn't an issue for the WNDR3800, which
uses a Realtek switch chipset, but the panic was encountered on the
RouterStation Pro (using an AR8216 switch) and some other boards that
haven't yet been merged.
The panic message mentions an unaligned access and happens in
ag71xx_mdio_probe in drivers/net/ethernet/atheros/ag71xx/ag71xx_mdio.c.
Even if the unaligned access is fixed, the ag71xx_mdio probe still fails
without the "syscon" property.
This was already being worked around in
ar7161_ubnt_routerstation-pro.dts by overriding the compatible property,
so this commit removes that as well.
All of the other ath79 .dtsi already have this property, so no changes
are needed elsewhere.
Signed-off-by: Matt Merhar <mattmerhar@protonmail.com>
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>
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>
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>
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>
u-boot.mk checks for the Default profile to build images for all targets.
This brings the target default profile in sync with other targets
Signed-off-by: Felix Fietkau <nbd@nbd.name>
PCI paths of the WLAN devices have changed between kernel 4.4 and 4.9;
migrate config so existing wifi-iface definitions don't break.
This is implemented as a hotplug handler rather than a uci-defaults script
as the migration script must run before the 10-wifi-detect hotplug handler.
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
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>
This reverts commit 3a8efaef00.
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>
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>
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>
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>
This remedies an issue with the MBL Duo if both disks are inserted
and contain OpenWrt. kernel and dtb would be loaded from SATA 1:1
while rootfs (/dev/sda2) would be mounted on SATA 0:1.
Such a mix&match would obviously only work if both OpenWrt versions/
builds are identical, and especially fail after sysupgrade upgraded
the system disk on SATA 0:1.
The fallback to SATA 1:1 needs to be kept for MBL Single (only has
SATA 1:1) and MBL Duo with one disk inserted on SATA 1:1. To speed
up booting in those cases, the unneccesarily doubled "sata init"
will only be called once. (In theory it could be omitted completely
since the on-flash boot script already initializes SATA to load the
on-disk boot script.)
Tested on MBL Duo (all possible combination of disks) and MBL Single
Acked-by: Christian Lamparter <chunkeey@gmail.com>
Signed-off-by: Freddy Leitner <hello@square.wf>
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>
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>
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>
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>
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>
Commit 7af1fb9faa ("kernel: add a RPS balancer") introduces a RPS balancer
for all targets.
In the past however, this patch was already introduced for target "mediatek"
in commit 7762c07c88 ("mediatek: bump to v4.14")
Remove the separate copy of the patch within the mediatek target,
which otherwise is applied twice and results in a build error.
Fixes: 7af1fb9faa ("kernel: add a RPS balancer")
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
By default the RPS delegation will happen by masking the last few bits of
skb->hash. This patch adds an inermediate hash bucket that maps the masked
hash to a RPS core. This makes RPS results much more deterministic on SMP
systems.
Signed-off-by: John Crispin <john@phrozen.org>
The current make-ras.sh image generation script for the ZyXEL NBG6617
has portability issues with bash. Because of this, factory images are
currently not built correctly by the OpenWRT buildbots.
This commit replaces the make-ras.sh by C-written mkrasimage.
The new mkrasimage is also compatible with other ZyXEL devices using
the ras image-format.
This is not tested with the NBG6616 but it correctly builds the
header for ZyXEL factory image.
Signed-off-by: David Bauer <mail@david-bauer.net>
Currently all PCI devices get the same IRQ that affects performance badly.
This commit adresses this problem and cleans the code.
ar7100 has a special PCI interrupt controller@18060018 that works exactly
the same way as misc interrupt controller.
This patch does the following:
1. Defines pci-intc interrupt controller@18060018 in dtsi.
2. Removes interrupt-controller property from PCI node.
3. Sets a correct interrupt mask for PCI devices.
4. Removes all IRQ handling code from the PCI driver.
"qca,ar7100-misc-intc" should be used as the compatible property, becuase on ar7100
the controlled status register is read-only and the ack method used in
"qca,ar7240-misc-intc" won't work properly.
There are two very minor downsides of this patch that don't affect perormance:
1. We allocate an IRQ domain of 32 IRQ, whan we need only 5. But ar7100 aren't tiny un terms of RAM
and that is not very important and can be tuned if we implement "nr-interrupts" property".
2. It reuses the same irg chip name "MISC" for both controllers.
Run tested on DIR-825 B1.
Signed-off-by: Dmitry Tunin <hanipouspilot@gmail.com>
We currently don't have any code configuring interface mode in ath79,
meaning that we relies on bootloader to set the correct interface mode.
This patch added code to set interface correctly so that everything works
even if bootloader configures it wrong.(e.g. on WNDR3800 u-boot set
the second GMAC mode to RMII but it should be RGMII.)
Introduced "qca,mac-idx" for the difference in MII_CTRL register value.
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
Netgear WNR612v2 flashed with recent OpenWrt builds suffers from kernel
panic at boot during wireless chip initialization, making device
unusable:
ath: phy0: Ignoring endianness difference in EEPROM magic bytes.
ath: phy0: Enable LNA combining
CPU 0 Unable to handle kernel paging request at virtual address 1000fee1, epc == 801d08f0, ra == 801d0d90
Oops[#1]:
CPU: 0 PID: 469 Comm: kmodloader Not tainted 4.9.120 #0
[ ... register dump etc ... ]
Kernel panic - not syncing: Fatal exception
Rebooting in 1 seconds..
This simple patch fixes above error. It keeps LED table in memory after
kernel init phase for ath9k driver to operate correctly (__initdata
removed).
Also, another bug is fixed - correct array size is provided to function
that adds platform LEDs (this device has only 1 connected to Wifi chip)
preventing code from going outside array bounds.
Fixes: 1f5ea4eae4 ("ar71xx: add correct named default wireless led by using platform leds")
Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
[trimmed commit message]
Signed-off-by: Mathias Kresin <dev@kresin.me>
The NBG6616 shares a config symbol with the NBG6716. It was accidentally
removed from the config when the ar71xx-tiny target was split off.
Fixes: 0cd5e85e7a ("ar71xx: create new ar71xx/tiny subtarget for 4MB flash devices")
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
This adds a shared ar7161_ubnt_routerstation.dtsi as well as two other
.dts files that utilize it, ar7161_ubnt_routerstation.dts and
ar7161_ubnt_routerstation-pro.dts.
The modifications to generic-ubnt.mk, config-default, and base-files
necessary for image generation, parsing RedBoot FIS partitions, network
configuration, and sysupgrade are also included.
This reintroduces vital bits from platform_do_upgrade_combined() and its
supporting functions to /lib/upgrade/platform.sh, which were previously
removed from ath79 in 3e9d9f6225 "ath79:
sysupgrade: drop unused platform checks". The new function is called
"routerstation_do_upgrade" and will *only* work for the RouterStation
series of boards. It does however retain the ability to downgrade (e.g.
from master -> 17.01.x using sysupgrade -F).
All hardware is functional including the AR8216 switch (for the Pro),
wireless via ath5k/ath9k using the miniPCI slots, flash, USB, button,
and LED.
Switch and LAN/WAN configuration is the same as it is with the
equivalent ar71xx targets. MAC addresses are assigned based upon the
content stored in the RedBoot config partition.
Flashing via both sysupgrade and TFTP has been confirmed to work. Also,
the initramfs images are now raw .bin files instead of being wrapped in
a uImage (as they currently are in ar71xx), which makes them bootable
with RedBoot.
One notable difference to ar71xx is the inclusion of the RedBoot
"fconfig" utility (analogous to U-Boot’s fw_printenv/fw_setenv) in
DEVICE_PACKAGES. The FIS partitions are probed using the RedBoot MTD
parser’s DT binding, whose proper usage is mutually exclusive to
defining a separate fixed-partitions node for "RedBoot config". This
config partition contains the board's base MAC address. The lack of a
hard-coded flash location means that the mtd-mac-address property cannot
be used in the .dts, so instead fconfig is used to read the MAC
addresses from flash in userspace during first boot.
Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
Signed-off-by: Matt Merhar <mattmerhar@protonmail.com>
- 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>
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>
This adds a configuration options which is needed now.
Without this patch the geode build will fail.
Fixes: 4eda2fddf2 ("x86/geode: enable X86_INTEL_LPSS to select PINCTRL")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
WNDR3400v3 needs GPIO 21 pulled high to enable power to USB ports. Add a
kernel patch to do that.
Signed-off-by: Tuomas Tynkkynen <tuomas.tynkkynen@iki.fi>
- Specifications -
CuBox i1:
- SoC: i.MX6 Solo
- Cores: 1
- Memory Size: 512MB
- GPU: GC880
- Wifi/Bluetooth: Optional
- USB 2.0 ports: 2
- Ethernet: 10/100/1000 Mbps
CuBox i2 | i2eX:
- SoC: i.MX6 Dual Lite
- Cores: 2
- Memory Size: 1GB
- GPU: GC2000
- Wifi/Bluetooth: Optional
- USB 2.0 ports: 2
- Ethernet: 10/100/1000 Mbps
CuBox i4Pro | i4x4:
- SoC: i.MX6 Quad
- Cores: 4
- Memory Size: 2/4 GB
- GPU: GC2000
- Wifi/Bluetooth: Build In
- USB 2.0 ports: 2
- Ethernet: 10/100/1000 Mbps
Built-in u-boot requires SPL (secondary program loader) to be present on the SD-card regardless of the image type which will be loaded.
SPL is generated by the u-boot-mx6cuboxi package which is preselected by the target device and can be found in bin/u-boot-mx6cuboxi directory.
Flashing the SPL:
dd if=/dev/zero of=/dev/mmcblk0 bs=1M count=4
dd if=bin/targets/imx6/generic/u-boot-mx6cuboxi/SPL of=/dev/mmcblk0 bs=1K seek=1
Preparing the firmware on the SD-card:
(echo o; echo n; echo p; echo 1; echo ''; echo ''; echo w) | fdisk /dev/mmcblk0
mkfs.ext4 /dev/mmcblk0p1
mount /dev/mmcblk0p1 /mnt
tar -xzf bin/targets/imx6/generic/openwrt-imx6-device-cubox-i-rootfs.tar.gz -C /mnt/
mkdir -p /mnt/boot
cp bin/targets/imx6/generic/{*-uImage,*.dtb,*.scr} /mnt/boot/
Generated u-boot.img needs to be placed on the first partition:
cp bin/targets/imx6/generic/u-boot-mx6cuboxi/u-boot.img /mnt/
To boot from the SD card:
Boot script which sets mmc/dtb parameters and boots the board is automatically sourced.
If this does not work for any reason:
mmc dev 0; load mmc 0:1 $scriptaddr boot/boot.scr; source $scriptaddr
Currently imx6dl-cubox-i.dtb (Dual Lite) and imx6q-cubox-i.dtb (Quad) device trees are available.
Tested on i4Pro, MMC, USB (+ HiD), HDMI and ethernet ports are working.
Wireless and bluetooth are broken ATM. According to SolidRun forums, BCM4329/BCM4330 firmware is used which works fine on older kernels.
Signed-off-by: Vladimir Vid <vladimir.vid@sartura.hr>
Without UHCI a non-trivial number of machines will have no keyboard
without BIOS assistance.
Add XHCI as well in case there are chipsets which don't support legacy
interfaces, and support PCI OHCI controllers also.
Signed-off-by: Alex Maclean <monkeh@monkeh.net>
This patch improves faf64056dd 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>
This patch improves 5684d08741 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>
Ubiquiti XM series boards contain a set of RSSI LEDs. Create an UCI
mapping for them, so visual feedback on RSSI is available, when using
userspace RSSI monitor daemon.
Runtime tested using rssileds.
Signed-off-by: Lech Perczak <lech.perczak@gmail.com>
Create aliases for led-booting and led-failsafe pointing at
ubnt:green:link4 LED, forUbiquiti XM series, so visual feedback
on device status becomes available, in order to enter failsafe mode
via button. led-running and led-upgrade aliases are omitted to avoid
conflicting with RSSI LEDs when in normal operation.
Signed-off-by: Lech Perczak <lech.perczak@gmail.com>
ubnt,bullet-m and ubnt,rocket-m targets support only single Ethernet
port, therefore disable creation of WAN zone and interfaces for them,
as their intended purpose is a wireless bridge. This aligns the
configuration with one found in ar71xx target.
ubnt,nano-m target is kept as is, being a two-port device.
Signed-off-by: Lech Perczak <lech.perczak@gmail.com>
Enable ath9k EEPROM extraction on boot for Ubiquiti XM-series boards.
This is required for wireless interface to function.
Runtime tested on Nanobridge M5.
Signed-off-by: Lech Perczak <lech.perczak@gmail.com>
I-O DATA ETG3-R is a wired router, based on Atheros AR9342.
Specification:
- Atheros AR9342
- 64 MB of RAM
- 8 MB of Flash
- 5x 10/100/1000 Ethernet
- AR8327N
- 2x LEDs, 1x key
- UART header on PCB
- Vcc, GND, TX, RX from ethernet port side
- 115200n8
Flash instruction using initramfs image:
1. Connect serial cable to UART header on ETG3-R
2. Rename OpenWrt initramfs image to "1500A8C0.img" and place it in
the TFTP directory
3. Set IP address of the computer to 192.168.0.10, connect to the
LAN port of ETG3-R, and start the TFTP server on the computer
4. Connect power cable to ETG3-R and turn on the router
5. Press "Enter" key when the "Hit any key to stop autoboot:" message
is displayed on the console and enter the u-boot cli
6. execute following commands to change kernel address for u-boot
setenv bootsf 1
setenv mtd_kernel1 "bootm 0x9f050000"
saveenv
7. execute "tftpboot; bootm" command to download the initramfs image from
TFTP server and boot with it
8. On the initramfs image, execute "mtd erase firmware" to erase stock
firmware and execute sysupgrade with sysupgrade image for ETG3-R
9. Wait ~150 seconds to complete flashing
Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
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>
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>
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>
According to abbfcc8525 ("ramips: add support for GL-inet
GL-MT300N-V2") the board has a MediaTek MT7628AN. Change the SoC
compatible to match the used hardware.
Signed-off-by: Mathias Kresin <dev@kresin.me>
RT5350 neither have rgmii nor a mdio pinmux group. MT7628an doesn't
have a jtag group. Having these groups defined might cause a boot
panic.
The pin controller fails to initialise for kernels > 4.9 if invalid
groups are used. If a subsystem references a pin controller
configuration node, it can not find this node and errors out. In worst
case it's the SPI driver which errors out and we have no root
filesystem to mount.
Signed-off-by: Mathias Kresin <dev@kresin.me>
The intention of 967b6be118 ("ar8327: Add workarounds for AR8337
switch") was to remove the register fixups for AR8337. But instead they
were removed for AR8327.
The RGMII RX delay is forced even if the port is used as phy instead of
mac, which results in no package flow at least for one board.
Fixes: FS#1664
Signed-off-by: Mathias Kresin <dev@kresin.me>
While "rawnand.h" is available in kernel 4.14,
the default for this target is kernel 4.9 in which "nand.h" should be used.
Add an extra check to include the correct file depending on kernel version
Fixes these build errors:
drivers/mtd/nand/ar934x_nfc.c:16:10: fatal error: linux/mtd/rawnand.h: No such file or directory
#include <linux/mtd/rawnand.h>
^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Fixes: 318e19ba67 ("ar71xx: add v4.14 support")
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
Sysupgrading to ath79 from ar71xx currently fails because of mismatching
supported_devices. ar71xx is expecting "tl-mr3020" which is missing in
the ath79 image. Upgrading from ath79 is unaffected, as the image
contains the old string for ar71xx and the new one coming from the
device-tree.
Signed-off-by: David Bauer <mail@david-bauer.net>
PISEN WMM003N is never supported by ar71xx, this commit also removed
SUPPORTED_DEVICES for it because it's completely useless.
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
This commit adds support for the AVM Fritz!Box 4020 WiFi-router.
SoC: Qualcomm Atheros QCA9561 (Dragonfly) 750MHz
RAM: Winbond W971GG6KB-25
FLASH: Macronix MX25L12835F
WiFi: QCA9561 b/g/n 3x3 450Mbit/s
USB: 1x USB 2.0
IN: WPS button, WiFi button
OUT: Power LED green, Internet LED green, WLAN LED green,
LAN LED green, INFO LED green, INFO LED red
UART: Header Next to Black metal shield
Pinout is 3.3V - RX - TX - GND (Square Pad is 3.3V)
The Serial setting is 115200-8-N-1.
Tested and working:
- Ethernet (LAN + WAN)
- WiFi (correct MAC)
- Installation via EVA bootloader
- OpenWRT sysupgrade
- Buttons
- LEDs
The USB port doesn't work. Both Root Hubs are detected as having 0 Ports:
[ 3.670807] kmodloader: loading kernel modules from /etc/modules-boot.d/*
[ 3.723267] usbcore: registered new interface driver usbfs
[ 3.729058] usbcore: registered new interface driver hub
[ 3.734616] usbcore: registered new device driver usb
[ 3.744181] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[ 3.758357] SCSI subsystem initialized
[ 3.766026] ehci-platform: EHCI generic platform driver
[ 3.771548] ehci-platform ehci-platform.0: EHCI Host Controller
[ 3.777708] ehci-platform ehci-platform.0: new USB bus registered, assigned bus number 1
[ 3.788169] ehci-platform ehci-platform.0: irq 48, io mem 0x1b000000
[ 3.816647] ehci-platform ehci-platform.0: USB 2.0 started, EHCI 0.00
[ 3.824001] hub 1-0:1.0: USB hub found
[ 3.828219] hub 1-0:1.0: config failed, hub doesn't have any ports! (err -19)
[ 3.835825] ehci-platform ehci-platform.1: EHCI Host Controller
[ 3.842009] ehci-platform ehci-platform.1: new USB bus registered, assigned bus number 2
[ 3.852481] ehci-platform ehci-platform.1: irq 49, io mem 0x1b400000
[ 3.886631] ehci-platform ehci-platform.1: USB 2.0 started, EHCI 0.00
[ 3.894011] hub 2-0:1.0: USB hub found
[ 3.898190] hub 2-0:1.0: config failed, hub doesn't have any ports! (err -19)
[ 3.908928] usbcore: registered new interface driver usb-storage
[ 3.915634] kmodloader: done loading kernel modules from /etc/modules-boot.d/*
A few words about the shift-register:
AVM used a trick to control the shift-register for the LEDs with only 2
pins, SERCLK and MOSI. Q7S, normally used for daisy-chaining multiple
shift-registers, pulls the latch, moving the shift register-state to
the storage register. It also pulls down MR (normally pulled up) to
clear the storage register, so the latch gets released and will not be
pulled by the remaining bits in the shift-register. Shift register is
all-zero after this.
For that we need to make sure output 7 is set to high on driver probe.
We accomplish this by using gpio-hogging.
Installation via EVA:
In the first seconds after Power is connected, the bootloader will
listen for FTP connections on 169.254.157.1 (Might also be 192.168.178.1).
Firmware can be uploaded like following:
ftp> quote USER adam2
ftp> quote PASS adam2
ftp> binary
ftp> debug
ftp> passive
ftp> quote MEDIA FLSH
ftp> put openwrt-sysupgrade.bin mtd1
Note that this procedure might take up to two minutes. After transfer is
complete you need to powercycle the device to boot OpenWRT.
Signed-off-by: David Bauer <mail@david-bauer.net>
TP-Link Archer C7 v1 is a dual band router
based on Qualcomm/Atheros QCA9558 + QCA9880.
Specification:
- 720 MHz CPU
- 128 MB of RAM (Various chips)
- 8 MB of FLASH (Various chips)
- SoC QCA9558 integrated 3T3R 2.4 GHz Wi-Fi
- minipcie slot with 3T3R 5 GHz QCA9880-AR1A (unsupported by ath10k!)
- 5x 10/100/1000 Mbps Ethernet (AR8327N Switch)
- 10x LEDs, 2x software buttons
For further informwation on the device, visit the wiki:
<https://openwrt.org/toh/tp-link/archer-c7-1750>
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
I-O DATA WN-AC1167DGR is a 2.4/5 GHz band 11ac router, based on
Qualcomm Atheros QCA9557.
Specification:
- Qualcomm Atheros QCA9557
- 128 MB of RAM (DDR2)
- 16 MB of Flash (SPI)
- 2T2R 2.4/5 GHz wifi
- 2.4 GHz: SoC internal
- 5 GHz: QCA988x
- 5x 10/100/1000 Mbps Ethernet
- 6x LEDs, 6x keys (4x buttons, 1x slide switch)
- UART header on PCB
- Vcc, GND, TX, RX from ethernet port side
- 115200n8
Flash instruction using factory image:
1. Connect the computer to the LAN port of WN-AC1167DGR
2. Connect power cable to WN-AC1167DGR and turn on it
3. Access to "http://192.168.0.1/" and open firmware update page
("ファームウェア")
4. Select the OpenWrt factory image and click update ("更新") button
5. Wait ~150 seconds to complete flashing
Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
Adding tl-wr841-v11 and the rename of tl-wr841n-v9 to tl-wr841-v9 in 01_leds
and 02_network script files are missing in commits cc35c91 and 8db6522.
Signed-off-by: Johann Neuhauser <johann@it-neuhauser.de>
[merged with identical case in 02_network]
Signed-off-by: Mathias Kresin <dev@kresin.me>
If it isn't a usb led, it shouldn't be used as one by default. It is up
to the user to add such a (mis)configuration for the board.
Signed-off-by: Mathias Kresin <dev@kresin.me>
Buffalo WHR-G301N is a 2.4 GHz 11n router, based on Atheros AR7240.
Ported from ar71xx target.
Specification:
- Atheros AR7240
- 32 MB of RAM
- 4 MB of Flash
- 2.4 GHz 2T2R wifi
- 5x 10/100 Mbps Ethernet
- 9x LEDs, 4x keys
- LED: 8x gpio-leds, 1x ath9k-leds
- key: 2x buttons, 1x slide switch
- UART header on PCB
- Vcc, GND, TX, RX from LEDs side
- 115200n8
Flash instruction using factory image:
1. Connect the computer to the LAN port of WHR-G301N
2. Connect power cable to WHR-G301N and turn on it
3. Access to "http://192.168.11.1/" and open firmware update page
("ファーム更新")
4. Select the OpenWrt factory image and click execute ("実行") button
5. Wait ~150 seconds to complete flashing
Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
[fix the SUPPORTED_DEVICES to be compatible with the ar71xx image]
Signed-off-by: Mathias Kresin <dev@kresin.me>
Indicate a (sys)upgrade via leds as well. It brings the lantiq diag.sh
script en par with the other implementations using devicetree aliases
to define multiple leds for boot status indication.
By default, use the boot finished led to indicate an upgrade for now.
Signed-off-by: Mathias Kresin <dev@kresin.me>
The upgrade led is only used if a running led is defined. If no running
led is defined, the upgrade led is ignored and upgrade isn't indicated
at all.
Instead, turn off the running led prior to turning the upgrade led on.
In most cases there isn't any visual change, but it allows to use an
independent led for upgrade indication.
Signed-off-by: Mathias Kresin <dev@kresin.me>
Set the (sys)upgrade state when sourcing the stage2 script instead of
setting the state for each target individual.
This change fixes the, due to a missing state set, not working upgrade
led on ath79 and apm821xx.
Signed-off-by: Mathias Kresin <dev@kresin.me>
Since kernel 4.10 commit 61e84623ace3 ("net: centralize net_device
min/max MTU checking"), the range of mtu is [min_mtu, max_mtu], which
is [68, 1500] by default.
It's necessary to set a max_mtu if a mtu > 1500 is supported.
Tested-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
Signed-off-by: Mathias Kresin <dev@kresin.me>
The following patch was integrated upstream:
* target/linux/generic/backport-4.9/500-ext4-fix-check-to-prevent-initializing-reserved-inod.patch
This fixes tries to work around the following security problems:
* CVE-2018-3620 L1 Terminal Fault OS, SMM related aspects
* CVE-2018-3646 L1 Terminal Fault Virtualization related aspects
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
The following patches were integrated upstream:
* target/linux/ipq40xx/patches-4.14/050-0006-mtd-nand-qcom-Add-a-NULL-check-for-devm_kasprintf.patch
* target/linux/mediatek/patches-4.14/0177-phy-phy-mtk-tphy-use-auto-instead-of-force-to-bypass.patch
This fixes tries to work around the following security problems:
* CVE-2018-3620 L1 Terminal Fault OS, SMM related aspects
* CVE-2018-3646 L1 Terminal Fault Virtualization related aspects
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Use the orange led by default to match the bootloader/stock firmware
behaviour. Turn on the green power led after boot to indicate a
finished boot and the orange one off.
Signed-off-by: Dmitry Tunin <hanipouspilot@gmail.com>
[reword commit message, keep orange power led enabled during early
kernel boot]
Signed-off-by: Mathias Kresin <dev@kresin.me>
Use the orange led by default to match the bootloader/stock firmware
behaviour. Turn on the blue power led after boot to indicate a finished
boot and the orange one off.
Signed-off-by: Dmitry Tunin <hanipouspilot@gmail.com>
[reword commit message, keep orange power led enabled during early
kernel boot]
Signed-off-by: Mathias Kresin <dev@kresin.me>
Use diag.sh version used for apm821xx, ipq40xx and ipq806x, which
supports different leds for the different boot states.
The existing led sequences should be the same as before.
Signed-off-by: Dmitry Tunin <hanipouspilot@gmail.com>
[reword commit message]
Signed-off-by: Mathias Kresin <dev@kresin.me>
The DWR-118-A2 Wireless Router is based on the MT7620A SoC.
Specification:
- MediaTek MT7620A (580 Mhz)
- 128 MB of RAM
- 16 MB of FLASH
- 1x 802.11bgn radio
- 1x 802.11ac radio (MT7612EN)
- 4x 10/100 Mbps Ethernet (1 WAN and 3 LAN)
- 1x 10/100/1000 Mbps Marvell Ethernet PHY (1 LAN)
- 2x external, non-detachable antennas
- 1x USB 2.0
- UART (J1) header on PCB (57600 8n1)
- 7x LED (5x GPIO-controlled), 2x button
- JBOOT bootloader
Known issues:
- GELAN not working
- flash is very slow
The status led has been assigned to the dwr-118-a2:green:internet led.
At the end of the boot it is switched off and is available for other
operation. Work correctly also during sysupgrade operation.
Installation:
Apply factory image via http web-gui or JBOOT recovery page
How to revert to OEM firmware:
- push the reset button and turn on the power. Wait until LED start
blinking (~10sec.)
- upload original factory image via JBOOT http (IP: 192.168.123.254)
Signed-off-by: Cezary Jackiewicz <cezary@eko.one.pl>
Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
HiWiFi "Gee Enjoy1200" HC5861B is a dual-band router based on MediaTek MT7628AN
https://www.hiwifi.com/enjoy-view
Specifications:
- MediaTek MT7628AN 580MHz
- 128 MB DDR2 RAM
- 16 MB SPI Flash
- 2.4G MT7628AN 802.11bgn 2T2R 300Mbps
- 5G MT7612EN 802.11ac 2T2R 867Mbps
- 5x 10/100 Mbps Ethernet
Flash instruction:
1. Get SSH access to the router
2. SSH to router with `ssh -p 1022 root@192.168.199.1`, The SSH password is the same as the webconfig one
3. Upload OpenWrt sysupgrade firmware into the router's `/tmp` folder with SCP
4. Run `mtd write /tmp/<filename> firmware`
5. reboot
Everything is working
Signed-off-by: Deng Qingfang <dengqf6@mail2.sysu.edu.cn>
Move the alias node of the TP-Link WR841v9 and rename the phandle of
the qss led to qss_led in preparation for adding the very similar
TP-Link WR841v11.
Signed-off-by: Johann Neuhauser <johann@it-neuhauser.de>
Remove SUPPORTED_DEVICES from wr841-v9 because it´s not needed and
for consistency rename everything to tl-wr841-v9.
Signed-off-by: Johann Neuhauser <johann@it-neuhauser.de>
Add ath9k wifi capabilities to WNDR3700 family.
* use kmod-owl-loader to load firmware from "art"
* add wifi to DTS
* add wifi LEDs
Avoid using the same MAC for eth0 LAN and wlan0 by
toggling the eth0 MAC into a locally administered MAC.
That is currently done by in user-space by adding a
uci config item into /etc/config/network
(More elegant solution might be setting it already in
preinit phase.)
Known issues:
* wifi firmware file may not get created on the first boot
after flashing on time to bring wifi normally up. Likely
the overlay jffs2 is not yet ready for creating the
firmware file. "wifi up" may still bring wifi up.
Wifi will work normally at subsequent boots.
* phy0 and phy1 may get assigned mixed, so that phy0 may
be the 5GHz radio instead of the normal 2.4GHz, and vice
versa for phy1. Does not happen always, but may happen.
Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
[fix the wifi unit address in the dts]
Signed-off-by: Mathias Kresin <dev@kresin.me>
Pisen WMM003N (sold under the name of Cloud Easy Power) is an
AR9331-based router and power bank combo device. The device uses a
stock firmware modified from OpenWRT for TP-Link TL-WR703N; however
some GPIO definition is different on this device with TL-WR703N. An
AXP202 PMIC (connected to a 5000mAh battery) and a SD slot are also
added, and the stock Flash/RAM configuration is 8MiB/64MiB.
The stock firmware is an old and heavily modified OpenWRT-based
firmware, which has telnetd defaultly open, and the root password is
"ifconfig" (quotation marks not included). The factory image format is
not known yet, however the stock firmware ships the OpenWRT's sysupgrade
command, and it can be used to install a newer firmware.
Due to the lack of the access to the STM8 embedded controller, the SD
slot is currently not usable (because it's muxed with the on-board USB
port) and the AXP PMIC cannot be monitored.
Signed-off-by: Icenowy Zheng <icenowy@aosc.io>
This target is on 4.9 currently.
It seems the support for this old kernel never got dropped.
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
This router is called RE450 and the tl prefix was used to identify it
as a TP-Link device. Drop the tl prefix since we now have tplink in
dts and device name.
Signed-off-by: Peter Lundkvist <peter.lundkvist@gmail.com>
In "brcm47xx: rework model detection" the file 01_detect was moved
to 01_network, therefore also update the warning message in case
everything fails.
Signed-off-by: Paul Wassi <p.wassi@gmx.at>
PLL for eth0 internal clock on ar913x is at 0x18050014
and AR913X_ETH0_PLL_SHIFT is 20 instead of 17
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
Add support for WNDR3700 and WNDR3700v2.
They share most things with WNDR3800.
Only device IDs and partition structure needs to be set.
Note: WNDR3700 (v1) has no NETGEAR_HW_ID, but has
also the NA version of the factory image.
Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
Prepare for addition of WNDR3700 and WNDR3700v2 by
separating the common parts into wndr3700.dtsi and
leaving just the device-specific things into wndr3800.dts
The three routers are identical except
* device IDs
* WNDR3700 (v1) has only 8 MB flash, while others have 16 MB.
Partition structure needs to be defined for each device.
* (WNDR3800 has 128 MB RAM, but RAM size is not in DTS)
Also separate the common parts of the image recipe.
(Drop also the initramfs recipe.)
Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
The wholesale changes introduced in commit f9b8328 missed this DTS file
because it hadn't been merged yet. This patch brings it in line to match
the other mt7620a devices' DTS files.
Additionally, the Internet LED is now labeled correctly and set to unused
by default, since the WAN interface is not known in every configuration.
Using sysupgrade between images before and after this commit will require
the -F flag.
Tested-by: Rohan Murch <rohan.murch@gmail.com>
Signed-off-by: Daniel Gimpelevich <daniel@gimpelevich.san-francisco.ca.us>
[drop internet led default setting]
Signed-off-by: Mathias Kresin <dev@kresin.me>
This patch adds support for the Netgear R6120, aka Netgear AC1200.
Specification:
- SoC: MediaTek MT7628 (580 MHz)
- Flash: 16 MiB
- RAM: 64 MiB
- Wireless: 2.4Ghz(builtin) and 5Ghz (MT7612E)
- LAN speed: 10/100
- LAN ports: 4
- WAN speed: 10/100
- WAN ports: 1
- Serial baud rate of Bootloader and factory firmware: 57600
To flash use nmrpflash with the provided factory.img.
Flashing via webinterface will not work, for now.
Signed-off-by: Ludwig Thomeczek <ledesrc@wxorx.net>
The kernel image of the at91-q5xr5 is getting too bing now and this is
breaking the build. Remove the image for the at91-q5xr5 from the build
to at least build images for the other devices.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
I-O DATA WN-AC1600DGR2 is a 2.4/5 GHz band 11ac router, based on
Qualcomm Atheros QCA9557.
Specification:
- Qualcomm Atheros QCA9557
- 128 MB of RAM
- 16 MB of Flash
- 2.4/5 GHz wifi
- 2.4 GHz: 2T2R (SoC internal)
- 5 GHz: 3T3R (QCA9880)
- 5x 10/100/1000 Mbps Ethernet
- 6x LEDs, 6x keys (4x buttons, 1x slide switch)
- UART header on PCB
- Vcc, GND, TX, RX from ethernet port side
- 115200n8
Flash instruction using factory image:
1. Connect the computer to the LAN port of WN-AC1600DGR2
2. Connect power cable to WN-AC1600DGR2 and turn on it
3. Access to "http://192.168.0.1/" and open firmware update page
("ファームウェア")
4. Select the OpenWrt factory image and click update ("更新") button
5. Wait ~150 seconds to complete flashing
Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
This patch copies over the MAC patching helper functions from lantiq's
target/linux/lantiq/base-files/etc/hotplug.d/firmware/12-ath9k-eeprom
file.
Not all vendors bothered to write the correct MAC addresses for the
ath9k wifi into the calibration data. And while ath9k does have some
special dt-properties to extract the addresses from a fixed position,
there are still devices that require userspace to edit or modify
the caldata.
In my case, the MAC address for the Wi-Fi device is stored in an
unsorted key-value based "nvram" database and there's an existing
userspace tool to extract the data.
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
This commit adds support for the OCEDO Koala
SOC: Qualcomm QCA9558 (Scorpion)
RAM: 128MB
FLASH: 16MiB
WLAN1: QCA9558 2.4 GHz 802.11bgn 3x3
WLAN2: QCA9880 5 GHz 802.11nac 3x3
INPUT: RESET button
LED: Power, LAN, WiFi 2.4, WiFi 5, SYS
Serial: Header Next to Black metal shield
Pinout is 3.3V - GND - TX - RX (Arrow Pad is 3.3V)
The Serial setting is 115200-8-N-1.
Tested and working:
- Ethernet
- 2.4 GHz WiFi
- 5 GHz WiFi
- TFTP boot from ramdisk image
- Installation via ramdisk image
- OpenWRT sysupgrade
- Buttons
- LEDs
Installation seems to be possible only through booting an OpenWRT
ramdisk image.
Hold down the reset button while powering on the device. It will load a
ramdisk image named 'koala-uImage-initramfs-lzma.bin' from 192.168.100.8.
Note: depending on the present software, the device might also try to
pull a file called 'koala-uimage-factory'. Only the name differs, it
is still used as a ramdisk image.
Wait for the ramdisk image to boot. OpenWRT can be written to the flash
via sysupgrade or mtd.
Due to the flip-flop bootloader which we not (yet) support, you need to
set the partition the bootloader is selecting. It is possible from the
initramfs image with
> fw_setenv bootcmd run bootcmd_1
Afterwards you can reboot the device.
Signed-off-by: David Bauer <mail@david-bauer.net>
Bit 8/12 of reset controller which is marked as PHY_RESET/SWITCH_RESET
in datasheets will trigger either a reset for builtin switch or assert
an external ETH0_RESET_L/ETH1_RESET_L pin, which are usually connected
to external PHY/switch. None of them should be triggered every time an
interface is brought up in ethernet driver.
Remove PHY reset support from ag71xx and definition for them in dtsi.
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
Buffalo BHR-4GRV2 is a wired router, based on Qualcomm Atheros
QCA9558.
Ported from ar71xx target.
Specification:
- Qualcomm Atheros QCA9558
- 64 MB of RAM
- 16 MB of Flash
- 5x 10/100/1000 Ethernet
- QCA8337N
- 4x LEDs, 2x keys
- UART header on PCB
- Vcc, TX, RX, GND from LED side
- 115200n8
Flash instruction using factory image:
1. Connect the computer to the LAN port of BHR-4GRV2
2. Connect power cable to BHR-4GRV2 and turn on it
3. Access to "http://192.168.12.1/" and open firmware update
page ("ファームウェア更新")
4. Select the OpenWrt factory image and click update ("更新実行")
button
5. Wait ~120 seconds to complete flashing
Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
This adds PLL settings for the ethernet ports of the TP-Link TL-WR1043
v2/v3 and the Openmesh OM5P-AC-v2.
We also change the PLL-settings in the qca9557.dtsi to match the ones
used as default on the ar71xx target.
As of 4b9680f138 those devices have broken ethernet ports as the default
PLL settings defined in the QCA9557.dtsi are applied which are off for
those devices.
Signed-off-by: David Bauer <mail@david-bauer.net>
commit 4b9680f fixed pll settings and the correct pll set
by bootloader is overrided by value in qca9557.dtsi which
is incorrect for Archer C7 and breaks ethernet. Add pll
values for archer c7 to fix ethernet connection.
This individual pll tweak has been cherry picked from github pr 1260
which changes a couple of things in a single commit and should be
ideally split. This commit get archer v7 back and working.
Tested: archer c7 v2
Original combined commit authored by:
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
c7 fix only split out by:
Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
Changed default role of Orange Pi PC2 MSUB port to host (in dts)
Changed default function of Orange Pi PC2 power button to PWR_BTN
Signed-off-by: Antonio Silverio <menion@gmail.com>
CPU: H5 High Performance Quad-core 64-bit Cortex-A53
GPU: Mali450 OpenGL ES 2.0/1.1/1.0, OpenVG 1.1, EGL
Memory: 1GB DDR3 (shared with GPU)
Onboard Storage: TF card (Max. 32GB) / NOR flash(2MB)
Onboard Network: 1000M/100M Ethernet RJ45
USB 2.0 Ports: Three USB 2.0 HOST, one USB 2.0 OTG, HOST mode
role by default in DTS
Buttons: Power Button(SW4) Debug TTL
UART: ..DC-IN..
>[GND][RX][TX] ..HDMI..
Signed-off-by: Antonio Silverio <menion@gmail.com>
When checking the outcome of the PHY autonegotiation status, at803x
currently returns false in case the SGMII side is not established.
Due to a hardware-bug, ag71xx needs to fixup the SoCs SGMII side, which
it can't as it is not aware of the link-establishment.
This commit allows to ignore the SGMII side autonegotiation status to
allow ag71xx to do the fixup work.
Signed-off-by: David Bauer <mail@david-bauer.net>
The QCA955X is affected by a hardware bug which causes link-loss of the
SGMII link between SoC and PHY. This happens on change of link-state or
speed.
It is not really known what causes this bug. It definitely occurs when
using a AR8033 Gigabit Ethernet PHY.
Qualcomm solves this Bug in a similar fashion. We need to apply the fix
on a per-device base via platform-data as performing the fixup work will
break connectivity in case the SGMII interface is connected to a Switch.
This bug was first proposed to be fixed by Sven Eckelmann in 2016.
https://patchwork.ozlabs.org/patch/604782/
Based-on-patch-by: Sven Eckelmann <sven.eckelmann@open-mesh.com>
Signed-off-by: David Bauer <mail@david-bauer.net>
This commit adds the ability to configure specific functions of the
at803x series ethernet-PHYs, which were previously configured
exclusively with the help of platform-data, via device-tree.
This is needed to fully support existing boards of the ar71xx platform.
Signed-off-by: David Bauer <mail@david-bauer.net>
Backport an upstream fix for a remotely exploitable TCP denial of service
flaw in Linux 4.9+.
The fixes are included in Linux 4.14.59 and later but did not yet end up in
version 4.9.118.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
The QCA9557 dtsi is currently missing pll-handle and pll-regs for both
eth0 and eth1, therefore PLL settings won't be applied. This commit
fixes this behavior.
Signed-off-by: David Bauer <mail@david-bauer.net>
While finalizing support for the U7623 with 512MB, I made an embarresing
error and configured 1GB RAM for the board. I also forgot to move memory
from the dtsi and to the dts. This commit takes care of my mistakes.
While I am confessing my mistakes, I also note that I made a mistake in
the commit message of the initial U7623 commit. It is the .bin-file, and
not the .gz file that shall be sent to the device via tftp.
v1->v2:
* Remove redundant memory node (thanks Jonas Gorski)
Signed-off-by: Kristian Evensen <kristian.evensen@gmail.com>
Including the tl-wdr3600 image build code just to overwrite most of it
doesn't make much sense and only makes it hard to read.
Furthermore, the tl-wdr4300 image will be marked as compatible with the
tl-wdr3600 this way.
Signed-off-by: Mathias Kresin <dev@kresin.me>
The variables are used in image build recipes and need to be marked as
per devices vars to be stored individual per image define. Otherwise
the last defined variable will be used for all boards.
Signed-off-by: Mathias Kresin <dev@kresin.me>
This patch did the following things:
1. Separate ath9k-leds out of gpio leds so that all other leds will work
before ath9k loded (e.g. during preinit/init stage).
2. Rename wps led to qss since that's how TP-Link mark it.
3. Rename LED prefix to tp-link because that dts is shared by many devices.
4. Rename to wr740n-v1 because v1 is the first and v2 just use the fw of v1.
(This will require a forced sysupgrade if you comes from
the previous wr740n v2 image.)
5. Remove SUPPORTED_DEVICES.
(tl-wr740n-v2 doesn't exist anywhere so it's useless.)
6. Add all WR741ND v1 clones found in ar71xx.
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
Fix all issues found by the devicetree compiler like wrong address/size
cells as well as wrong/missing/superfluous unit addresses.
Signed-off-by: Mathias Kresin <dev@kresin.me>
Use only the jedec,spi-nor compatible string. Everything else either
never worked or is only support to keep compatibility.
Signed-off-by: Mathias Kresin <dev@kresin.me>
Use the same method for setting queue index pointers consistenly
throughout the source file.
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
This router is called Archer C7 and the tl was used to identify
TP-LINK. Since we have added tplink in dts/board name, the tl
prefix is useless now.
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
Change lan and it's LED to eth0
It's broken since c7c807cb8c
where I changed the dts but forgot to change default configurations.
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
1. Swap eth0/eth1
Both devices are using AR9331, the builtin switch on AR9331 is
connected to gmac1 and gmac1 is named as eth1 in ath79.
PS: gmac1 is eth0 and gmac0 is eth1 in ar71xx because of the
reversed initialization order.
2. Fix the incorrect compatible string in dts
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
phy-handle is used to poll link status. They are useless when
we need fixed-link on these interfaces.
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
Jonas Gorski commented on the previous patch:
|This is actually the wrong fix and papers over an issue in one of our
|local patches.
|
|We intentionally allow regmap to be built as a module, see
|
|/target/linux/generic/hack-4.14/259-regmap_dynamic.patch
|[...]
|[The regulator code] optionally supports regmap thanks to the stubs
|provided if regmap is disabled - which breaks if you compile regmap
|as a module.
In order to mitigate this issue, this patch reverts the previous patch
and replaces the existing IS_ENABLED(CONFIG_REGMAP) with
IS_REACHABLE(CONFIG_REGMAP). This solves this particular issue as the
regulator code will now automatically fallback to the regmap stubs in
case the kmod-regmap module is enabled, but nothing else sets
CONFIG_REGMAP=y.
Note: There's still a potential issue that this patch doesn't solve:
If someone ever wants to make a OpenWrt kernel package for a
regulator module that requires the REGMAP feature for a target that
doesn't set CONFIG_REGMAP=y but has CONFIG_REGULATOR=y, the resulting
kmod-regulator-xyz package will not work on the target.
Luckily, there aren't any in-tree OpenWrt kernel module packages for
regulators at the moment. On the bright side: regmap is a critical
part nowadays and all new and upcoming architectures require it by
default. This will likely only ever be a problem for legacy targets
and devices that cannot afford to enable REGMAP.
Cc: Jonas Gorski <jonas.gorski@gmail.com>
Cc: John Crispin <john@phrozen.org>
Fixes: d00913d121 ("kernel: modules: fix kmod-regmap")
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
To share mdio addr for IntPHY and ExtPHY,
as described in the documentation (MT7620_ProgrammingGuide.pdf).
(refer: http://download.villagetelco.org/hardware/MT7620/MT7620_ProgrammingGuide.pdf)
when port4 setup to work as gmac mode, dts like:
&gsw {
mediatek,port4 = "gmac";
};
we should set SYSCFG1.GE2_MODE==0x0 (RGMII).
but SYSCFG1.GE2_MODE may have been set to 3(RJ-45) by uboot/default
so we need to re-set it to 0x0
before this changes:
gsw: 4FE + 2GE may not work correctly and MDIO addr 4 cannot be used by ExtPHY
after this changes:
gsw: 4FE + 2GE works and MDIO addr 4 can be used by ExtPHY
Signed-off-by: Chen Minqiang <ptpt52@gmail.com>
When PHY's are defined on the MDIO bus in the DTS, gigabit support was
being masked out for no apparent reason, pegging all such ports to 10/100.
If gigabit support must be disabled for some reason, there should be a
"max-speed" property in the DTS.
Reported-by: James McKenzie <openwrt@madingley.org>
Signed-off-by: Daniel Gimpelevich <daniel@gimpelevich.san-francisco.ca.us>
Mediatek has a reference platform that pairs an MT7620A with an MT7530W,
where the latter responds on MDIO address 0x1f while both chips respond on
0x0 to 0x4. The driver special-cases this arrangement to make sure it's
talking to the right chip, but two different ways in two different places.
This patch consolidates the detection without the current requirement of
both tests to be separately satisfied in the DTS.
Signed-off-by: Daniel Gimpelevich <daniel@gimpelevich.san-francisco.ca.us>
This really simplifies debugging, if a package is not found or a feed is
not reachable, a proper stderr is printed. Currently it would only say
`_call_manifest` failed.
Signed-off-by: Paul Spooren <mail@aparcar.org>
Starting with kernel 4.4, the use of partitions as direct subnodes of the
mtd device is discouraged and only supported for backward compatiblity
reasons.
Signed-off-by: Alex Maclean <monkeh@monkeh.net>
Fix space vs. tabs issue and trainling whitespaces. Use C style
comments or drop the comments if they explain what is already to see in
the devicetree parameters.
Signed-off-by: Mathias Kresin <dev@kresin.me>
The hardware NAT node has the same reg/unit as the ethernet node. One
of them need to be a child of the other.
Make the hardware NAT node a child of the ethernet node since the it
"reference" the netdev in its properties.
Signed-off-by: Mathias Kresin <dev@kresin.me>
Add the ranges property to the PCI bridges where missing. Add the unit
address to PCI bridge where missing.
Rework the complete rt3883 pci node. Drop the PCI unit nodes from the
dtsi. They are not used by any dts file and should be rather in the dts
than in the SoC dtsi. Express the PCI-PCI bridge in a clean devicetree
syntax. The ralink,pci-slot isn't used by any driver, drop it. Move the
pci interrupt controller out of the pci node. It doesn't share the same
reg and therefore should be an independent/SoC child node.
Move the pci related rt3883 pinctrl setting to the dtsi instead of
defining the very same for each rt3883 board.
If the device_type property is used for PCI units, the unit is treated
as pci bridge which it isn't. Drop it for PCI units.
Reference pci-bridges or the pci node defined in the dtsi instead of
recreating the whole node hierarchy. It allows to change the referenced
node in the dtsi without the need to touch all dts.
Fix the PCI(e) wireless unit addresses. All our PCI(e) wireless chips
are the first device on the bus. The unit address has to be the bus
address instead of the PCI vendor/device id.
Signed-off-by: Mathias Kresin <dev@kresin.me>
Since commit c1e7738988f5 ("checks: add gpio binding properties check")
dtc treats any *-gpios and *-gpio property as phandle at least during
checks. The only whitelisted property is nr-gpio.
Use ralink,nr-gpio in favour of ralink,num-gpios to get rid of false
positive warnings.
Signed-off-by: Mathias Kresin <dev@kresin.me>
The cpu interrupt controller doesn't have a reg property, hence we
can't use a unit address in the node name.
Signed-off-by: Mathias Kresin <dev@kresin.me>
Without this patch you will get an error "gpio-export probe deferral
not supported" when you try to export i2c expander gpio pins.
gpio-export is probed long before i2c-bus and i2c expander are created
and it doesn't retry it so none pins are exported.
Signed-off-by: René van Dorst <opensource@vdorst.com>
apply the change to all instances of the gpio exports patch
Signed-off-by: Mathias Kresin <dev@kresin.me>
Revert 290c54473e ("ath79: fix TP-Link Archer C7 v2 wlan1 MAC address")
which obviously aims to have a distinct MAC address per interface.
Unfortunally it doesn't match what is used by the stock firmware and we
shouldn'z use MAC Adresses not reserverd for/assigned to a particular
board.
The correct MAC adress increments for this board are:
wlan0 (5GHz) : -1
wlan1 (2.4GHz) : 0
eth1 (LAN) : 0
eth0 (WAN) : 1
Fixes: FS#408
Signed-off-by: Mathias Kresin <dev@kresin.me>
The Linux headers on arm64 architectures contain references to common
arch/arm/ headers which were not bundled by the SDK so far.
Check if we're packing the SDK for an arm64 target and if we do, also
include arch/arm headers as well.
Fixes FS#1725.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
It seems to have been missed when the patch was accepted.
Fixes: d591260407 ("brcm63xx: initial support for Sky SR102 router")
Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
The integrated SoC wifi will likely never be supported, and if,
it will go through DT with the sprom contents there.
Fixes: d591260407 ("brcm63xx: initial support for Sky SR102 router")
Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
Adds Support for the TP-LINK CPE510 V2.0 by TP-Link.
The hardware is almost the same as the CPE510 V1.0
Follow the same processes as for the CPE510 V1.0
Signed-off-by: Andrew Cameron <apcameron@softhome.net>
1) Add comments so it's clear why we did things; this may prevent
someone (e.g. me) from sinking time into fixing things that
aren't broken and/or were done for reason.
2) Drop mdio 0 probe/register; we don't use ag1xx mdio bus 0.
3) Cosmetic reording of some code (tested) that makes the defintion
more clear.
Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
The CR3000 stock firmware is now irrelevant as it required a now defunct
cloud service. Therefore only build images that use the entire flash
(overwriting stock firwmare-specific partitions that no longer matter),
previously called 'nocloud' images.
Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
The PowerCloud Systems CR3000 was a cloud-managed CPE for a now defunct
NaaS offering. It was previously supported under the ar71xx branch and
this forward ports that support with some notable differences:
1) Since reverting to stock firmware is now irrelevant there is is only
a single openwrt image generated which uses the entire flash rather than
preserving PowerCloud-specific partitions that are unneeded to openwrt--
those partitions will be erased and used by the openwrt image.
2) Rather than use a non-standard probe order for the ethernet devices,
this image uses a set of 'ip link set ethX name ethY' commands very early
in preinit (before the network is used at all), in order to have the the
switch and Wan use the same ethernet names as in previous images.
3) /etc/config/wireless will need to be regenerated as the path to the
wireless device has changed due to differences in ath79 DT for ar93x
compared to ar71xx images.
4) eth0 is wan and eth1 is lan (switch)
Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
Refreshed all patches
Remove upstreamed patches.
- 103-MIPS-ath79-fix-register-address-in-ath79_ddr_wb_flus.patch
- 403-mtd_fix_cfi_cmdset_0002_status_check.patch
- 001-4.11-01-mtd-m25p80-consider-max-message-size-in-m25p80_read.patch
- 001-4.15-08-bcm63xx_enet-correct-clock-usage.patch
- 001-4.15-09-bcm63xx_enet-do-not-write-to-random-DMA-channel-on-B.patch
- 900-gen_stats-fix-netlink-stats-padding.patch
Introduce a new backported patch to address ext4 breakage, introduced in 4.9.112
- backport-4.9/500-ext4-fix-check-to-prevent-initializing-reserved-inod.patch
This patch has been slightly altered to compensate for a new helper function
introduced in later kernels.
Also add ARM64_SSBD symbol to ARM64 targets still running kernel 4.9
Compile-tested on: ar71xx, bcm2710
Runtime-tested on: ar71xx
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
Bundle the usbip utility sources shipped with the Linux kernel tree in
order to allow the usbip packages from the package feed to build within
the OpenWrt SDK.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
In 4.14.57, a new symbol for Spectre v4 mitigation was introduced for
ARM64. Add this symbol to all ARM64 targets using kernel 4.14.
This mitigates CVE-2018-3639 on ARM64.
Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
AT803X_REG_CHIP_CONFIG and AT803X_BT_BX_REG_SEL have been defined
upstream by commit f62265b53ef3 ("at803x: double check SGMII side autoneg")
An existing local patch then added those exact same defines again which
isn't necessary, so remove them.
Fixes: f791fb4af4 ("kernel: add linux 4.9 support")
Fixes: b3f95490b9 ("kernel: generic: Add kernel 4.14 support")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
The patch was wrongly removed by a kernel version bump to 4.9.105 in
the believe that it was merged upstream thow it wasn't. This lead to
unrecoverable link losses on devices which use those PHYs such as
many ubnt single-port CPEs.
Fixes: 7dca1bae82 (kernel: bump to 4.9.105)
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
The previous round of fixes for the 82574 chip cause an issue with
emulated e1000e devices in VMware ESXi 6.5. It also contains changes
that are not strictly necessary. These patches fix the issues introduced
in the previous series, revert the unnecessary changes to avoid
unforeseen fallout, and avoid a case where interrupts can be missed.
The final two patches of this series are already in the kernel, so no
need to include them here.
Patchwork: https://patchwork.ozlabs.org/cover/881776/
Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
This changes the DT binding's compatible property to
"ecoscentric,redboot-fis-partitions", removing the existing reference to
Red Hat.
Per the documentation hosted at eCosCentric's website, eCosCentric is
RedBoot's sole commercial maintainer since 2002, and the project has
been under the stewardship of the Free Software Foundation since 2008.
This also updates the property in the Inventel Livebox 1 .dts, the
binding's only current user.
Signed-off-by: Matt Merhar <mattmerhar@protonmail.com>
The OpenMesh A62 is a tri-band device (1x 2.4GHz, 2x 5GHz) with special
filters in front of the RX+TX paths to the 5GHz PHYs. These filtered
channel can in theory still be used by the hardware but the signal strength
is reduced so much that it makes no sense.
Signed-off-by: Sven Eckelmann <sven.eckelmann@openmesh.com>
In the new DT-based pci-ar71xx driver, ar71xx_pci_irq_init() was being
called before populating the PCI controller's device_node struct member.
This led to no IRQ being assigned to connected PCI devices (e.g. ath9k
cards) and caused them to be non-functional aside from simply being
detected.
The previous errors encountered in dmesg were: "irq: no irq domain found
for /ahb/apb/pcie-controller@180c0000 !". /proc/interrupts listed an IRQ
of 0 for the cards.
While this has been only been tested on a yet-to-be-merged RouterStation
Pro target, it should also fix the broken wifi people have reported for
the ath79 WNDR3800 target.
Signed-off-by: Matt Merhar <mattmerhar@protonmail.com>
Add missing definitions for the orange WAN LED on the
TL-WR1043N(D) v4 and v5.
Change the name of a MAC address offset constant to
make it consistent with the format of the
existing constants.
Signed-off-by: Tim Thorpe <tim@tfthorpe.net>
ELECOM WRC-2533GST is a 2.4/5 GHz band 11ac rotuer, based on
MediaTek MT7621A.
Specification:
- MT7621A (2-Core, 4-Threads)
- 128 MB of RAM (DDR3)
- 16 MB of Flash (SPI)
- 4T4R 2.4/5 GHz wifi
- MediaTek MT7615
- 5x 10/100/1000 Mbps Ethernet
- 4x LEDs, 6 keys (2x buttons, 1x slide switch)
- UART header on PCB
- Vcc, GND, TX, RX from ethernet port side
- baudrate: 57600 bps
Flash instruction using factory image:
1. Connect the computer to the LAN port of WRC-2533GST
2. Connect power cable to WRC-2533GST 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: INAGAKI Hiroshi <musashino.open@gmail.com>
Tested with 18.06.0-rc2/ar71xx/generic/tl-wdr4300-v1, image & list
This PR is based on the work of @fewckert[1] with slight improvements.
Add function `manifest` to show the manifest of the produced image,
before actually building it. The manifest contains an orderd list of
package name and version.
This is usefull to check package dependencies but also determine a
unique and reproducible image name before building the package. The
sysupgrade server[2] builds images on request with individual package
selection. To distignish between created images which contain differnt
packages, the EXTRA_IMAGE_NAME is set to a shortend hash of the
manifest's content. So far the image was renamed afterwards as the
manifests content was unknown, however this corrupts the signed
sha256sums. This patch allows a clean solution as to dtermine the
manifest in advance and set the EXTRA_IMAGE_NAME accordingly.
[1]: https://github.com/lede-project/source/pull/1591
[2]: https://github.com/aparcar/attendedsysupgrade-server
Signed-off-by: Paul Spooren <mail@aparcar.org>
TP-Link Archer C59v2 is a dual-band AC1350 router based on
Qualcomm/Atheros QCA9561+QCA9886 chips.
Specification:
- 775/650/258 MHz (CPU/DDR/AHB)
- 128 MB of RAM (DDR2)
- 16 MB of FLASH (SPI NOR)
- 3T3R 2.4 GHz
- 2T2R 5 GHz
- 5x 10/100 Mbps Ethernet
- USB 2.0 port
- UART header on PCB
Flash instruction:
- via web UI:
1. Download openwrt-ar71xx-generic-archer-c59-v2-squashfs-factory.bin
2. Login to router and open the Advanced tab
3. Navigate to System Tools -> Firmware Upgrade
4. Upload firmware using the Manual Upgrade form
- via TFTP:
1. Set PC to fixed ip address 192.168.0.66
2. Download openwrt-ar71xx-generic-archer-c59-v2-squashfs-factory.bin
and rename it to tp_recovery.bin
3. Start a tftp server with the file tp_recovery.bin in its root directory
4. Turn off the router
5. Press and hold Reset button
6. Turn on router with the reset button pressed and wait ~15 seconds
7. Release the reset button and after a short time
the firmware should be transferred from the tftp server
8. Wait ~30 second to complete recovery.
Signed-off-by: Keith Maika <keithm@aoeex.com>
This fixes:
drivers/mtd/redboot.c:299:34: error: array type has incomplete element type 'struct of_device_id'
Fixes: 5e8b4be531 ("kernel: add DT binding support to the mtd redboot parser")
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
linux,part-probe should be avoided as its only supported with OpenWrt
downstream patch that is going to be dropped eventually.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
On brcm47xx boards, the model ID is the combination of the "boardtype" nvram
variable and an optional supplemental "boardnum" variable while the human
readable model name is usually exposed in the "machine" field of the
/proc/cpuinfo file.
Move the extraction of the board nvram variables and model name string into
the 01_sysinfo file and rework the 01_detect board configuration script to
solely use the prepared sysinfo values without performing own detection
logic.
As a consequence, we can drop the ucidef_set_board_id() and
ucidef_set_model_name() invocations in favor to the generic behaviour
which copies the /tmp/sysinfo/{board_name,model} values into the board.json
"id" and "name" fields respectively.
Since "01_detect" only contains network configuration logic after this
change, move it to "01_network" and rename the contained "detect_by_xxx"
functions to "configure_by_xxx" instead, to avoid potential confusion.
Fixes FS#1576
Acked-by: Rafał Miłecki <rafal@milecki.pl>
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
fixes FS#1034, squash fs images fails to boot because of missing ARM BCJ filter decoder
also activate squashf image creation
Signed-off-by: Lucian Cristian <lucian.cristian@gmail.com>
The Traverse LS1043-S board is a router board based on
NXP/Freescale's LS1043 SoC, with 4x1GBase-T, 1 SFP and 1 SFP+,
as well as miniPCIe and M.2 LTE.
Unlike the Layerscape reference boards, the LS1043-S board has
NAND flash and uses the mainline U-Boot.
This patch implements support for the LS1043-S board, as well as
the earlier LS1043-V board. It is our intention that all boards
in this family (LS1043-S and later, Five64) will boot the same binary.
Not included in this patchset are the hwmon drivers not in the kernel
(emc1704,pac1934) or the bootloader.
Signed-off-by: Mathew McBride <matt@traverse.com.au>
This is required for the Traverse LS1043 family, we generate a FIT image
that works on all boards across the family. This is done by creating
multiple configurations that select the right DTB for the board.
The bootloader on these boards is configured to boot like this:
bootm $kernel_load#ls1043s
bootm $kernel_load#ls1043v
This is based on earlier work by Jason Wu for Zynq:
https://lists.openwrt.org/pipermail/openwrt-devel/2016-March/040460.html
Modified to add FDT load addresses and multiple configurations with DTB.
Signed-off-by: Mathew McBride <matt@traverse.com.au>
This is required on the Traverse LS1043 boards to support SFP
and xDSL plug-ins.
This will not be needed on kernel 4.14.
Signed-off-by: Mathew McBride <matt@traverse.com.au>
In boards with fdt is impossible to use kmod-w1-gpio-custom.
w1-gpio-custom create platform structure for w1-gpio module,
but if board use fdt, data is ignored in w1-gpio probe.
This workaround fix the problem.
Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
The device name is corrected to match the hardware-stored (in hard config
flash space) device name.
Tested-by: Tobias Schramm <tobleminer@gmail.com>
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
The device name is corrected to match the hardware-stored (in hard config
flash space) device name.
Tested-by: Tobias Schramm <tobleminer@gmail.com>
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
Tested on HC5661A and it now fixes the issue that when enabling sd card
in HC5661A, the wan and 3 lan ports will down.
Known issue:
- When enabling SD card support, the led light of system will down and the rest 2 lights keep working.
Signed-off-by: LoveSy <shana@zju.edu.cn>
There is another thing about crc to do when initialize SD card on
MT7628.
This commit is to fix this init issue.
Signed-off-by: LoveSy <shana@zju.edu.cn>
Qxwlan E750G v8 is based on Qualcomm QCA9344.
Specification:
- 560/450/225 MHz (CPU/DDR/AHB)
- 128 MB of RAM (DDR2)
- 8/16 MB of FLASH (SPI NOR)
- 2T2R 2.4G GHz (AR9344)
- 2x 10/100 Mbps Ethernet (PoE support)
- 2x 10/100/1000 Mbps Ethernet
- 7x LED (6 driven by GPIO)
- 1x button (reset)
- 1x DC jack for main power input (9-48 V)
- UART (J23) and LEDs (J2) headers on PCB
Flash instruction (using U-Boot CLI and tftp server):
- Configure PC with static IP 192.168.1.10 and tftp server.
- Rename "sysupgrade" filename to "firmware.bin" and place it in tftp
server directory.
- Connect PC with one of RJ45 ports, power up the board and press
"enter" key to access U-Boot CLI.
- Use the following command to update the device to OpenWrt: "run lfw".
Flash instruction (using U-Boot web-based recovery):
- Configure PC with static IP 192.168.1.xxx(2-254)/24.
- Connect PC with one of RJ45 ports, press the reset button, power up
the board and keep button pressed for around 6-7 seconds, until LEDs
start flashing.
- Open your browser and enter 192.168.1.1, select "sysupgrade" image
and click the upgrade button.
Signed-off-by: 张鹏 <sd20@qxwlan.com>
Qxwlan E750A v4 is based on Qualcomm QCA9344.
Specification:
- 560/450/225 MHz (CPU/DDR/AHB)
- 128 MB of RAM (DDR2)
- 8/16 MB of FLASH (SPI NOR)
- 2T2R 5G GHz (AR9344)
- 2x 10/100 Mbps Ethernet (one port with PoE support)
- 1x miniPCIe slot (USB 2.0 bus only)
- 7x LED (6 driven by GPIO)
- 1x button (reset)
- 1x DC jack for main power input (9-48 V)
- UART (J23) and LEDs (J2) headers on PCB
Flash instruction (using U-Boot CLI and tftp server):
- Configure PC with static IP 192.168.1.10 and tftp server.
- Rename "sysupgrade" filename to "firmware.bin" and place it in tftp
server directory.
- Connect PC with one of RJ45 ports, power up the board and press
"enter" key to access U-Boot CLI.
- Use the following command to update the device to OpenWrt: "run lfw".
Flash instruction (using U-Boot web-based recovery):
- Configure PC with static IP 192.168.1.xxx(2-254)/24.
- Connect PC with one of RJ45 ports, press the reset button, power up
the board and keep button pressed for around 6-7 seconds, until LEDs
start flashing.
- Open your browser and enter 192.168.1.1, select "sysupgrade" image
and click the upgrade button.
Signed-off-by: 张鹏 <sd20@qxwlan.com>
Qxwlan E558 v2 is based on Qualcomm QCA9558 + AR8327.
Specification:
- 720/600/200 MHz (CPU/DDR/AHB)
- 128 MB of RAM (DDR2)
- 8/16 MB of FLASH (SPI NOR)
- 2T2R 2.4 GHz (QCA9558)
- 3x 10/100/1000 Mbps Ethernet (one port with PoE support)
- 4x miniPCIe slot (USB 2.0 bus only)
- 1x microSIM slot
- 5x LED (4 driven by GPIO)
- 1x button (reset)
- 1x 3-pos switch
- 1x DC jack for main power input (9-48 V)
- UART (JP5) and LEDs (J8) headers on PCB
Flash instruction (using U-Boot CLI and tftp server):
- Configure PC with static IP 192.168.1.10 and tftp server.
- Rename "sysupgrade" filename to "firmware.bin" and place it in tftp
server directory.
- Connect PC with one of RJ45 ports, power up the board and press
"enter" key to access U-Boot CLI.
- Use the following command to update the device to OpenWrt: "run lfw".
Flash instruction (using U-Boot web-based recovery):
- Configure PC with static IP 192.168.1.xxx(2-254)/24.
- Connect PC with one of RJ45 ports, press the reset button, power up
the board and keep button pressed for around 6-7 seconds, until LEDs
start flashing.
- Open your browser and enter 192.168.1.1, select "sysupgrade" image
and click the upgrade button.
Signed-off-by: 张鹏 <sd20@qxwlan.com>
The driver is written in such a way that with a board defintion that
connects a fixed phy, mdio, and switch in a certain way, a kernel oops could
result because of lack of previously probed mdio bus.
This commit allows for easier debugging in this case by casting the
correct blame with serial console messages.
Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
It's a little noisier but makes it obvious when the ar7240 switch was
connected to the MDIO bus, and to which phy device (or the failure
to do so).
Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
NB: Error only appears with ag71xx debug messages and dynamic printk
enabled. This is probably why no one has caught it before.
Previously phy probe debug messages used old (now wrong) functions
to get the phy name for printing. There was also the chance of
a NULL pointer in the event no phy_device was found.
Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
mdio bus isn't a standalone device on ar7240. (and maybe older SoCs?)
Use simple-mfd for ar7241 and later SoCs to get mdio1 ready before gmac0
For ar7240 and older chips, manually create platform device after
ag71xx_hw_init() in ag71xx_probe()to get mdio0 ready between
ag71xx_hw_init() and ag71xx_phy_connect().
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
Allow specifying desired mdio clock frequency in dts.
Use default frequency around 5MHz for builtin switch and 2MHz for other mdio bus.
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>