Buttons of AVM FritzBox 4020 are incorrectly flagged as active high.
This was an oversight as RFKill button was working as expected even
with incorrectly flagged GPIO.
Signed-off-by: David Bauer <mail@david-bauer.net>
Buttons of AVM FritzBox 4020 are incorrectly flagged as active high.
This was an oversight as RFKill button was working as expected even
with incorrectly flagged GPIO.
Signed-off-by: David Bauer <mail@david-bauer.net>
kernel upstream commit 9efcaa7c4afba5628f2650a76f69c798f47eeb18 to 4.14
itself a backport of 0f02cfbc3d9e413d450d8d0fd660077c23f67eff has
resolved the cache line issues that led to us disabling VDSO by default
on MIPS.
Remove our force disable patch:
pending-4.14/206-mips-disable-vdso.patch
Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
Acked-by: Hauke Mehrtens <hauke@hauke-m.de>
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>
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>
In order to make RSSI indicator on the device work out of box,
include "rssileds" package in per-device rootfs image by default
for Ubiquiti XM family.
Signed-off-by: Lech Perczak <lech.perczak@gmail.com>
When mapping for RSSI LEDs was defined for interface wlan0 on
Ubiquiti XM family, the mapping for rssileds monitor was omitted
by mistake. Therefore create the mapping, so RSSI LEDs work without
additional configuration, after starting rssileds service.
Signed-off-by: Lech Perczak <lech.perczak@gmail.com>
Buffalo WZR-HP-AG300H is a dual band router based on
Qualcom Atheros AR7161 rev 2
Specification:
- 680 MHz CPU (Qualcomm Atheros AR7161)
- 128 MiB RAM (2x Samsung K4H511638G-LCCC)
- 32 MiB Flash (2x Winbond 25Q128BVFG)
- WiFi 5 GHz a/n (Atheros AR9220)
- WiFi 2.4 GHz b/g/n (Atheros AR9223)
- 1000Base-T WAN (Atheros AR7161)
- 4x 1000Base-T Switch (Atheros AR8316)
- 1x USB 2.0
- 3 Buttons (AOSS/WPS, Reset, USB Eject)
- 2 Slide switches (Router (on/off/auto), Movie Engine (on/off))
- 9 LEDs (Power green, WLAN 2GHz green, WLAN 2GHz amber,
WLAN 5GHz green, WLAN 5GHz LED amber, Router green,
Diag red, Movie Engine blue, USB green)
It is already supported by the ar71xx target.
For more information on the device visit the wiki:
<https://openwrt.org/toh/buffalo/wzr-hp-ag300h>
Serial console:
- The UART Header is next to Movie Engine Switch.
- Pinout is RX - TX - GND - 3.3V (Square Pad is 3.3V)
- The Serial setting is 115200-8-N-1.
Installation of OpenWRT from vendor firmware:
- Connect to the Web-interface at http://192.168.11.1
- Go to “Administration” → “Firmware Upgrade”
- Upload the OpenWrt factory image
Tested:
- Ethernet (LAN, WAN)
- WiFi
- Installation
- via TFTP rescue
- via factory image
- on firmware v1.77 (28-05-2012)
- on pro firmware v24SP2 r30356 (26-03-2018)
- via sysupgrade from ar71xx
(wlan devices don't work because of new names)
- via sysupgrade from itself
- Buttons
- LEDS
- USB (Power control and device recognition)
Signed-off-by: Bernhard Frauendienst <openwrt@nospam.obeliks.de>
Some systems require multiple flash chips to be concatenated and read as
a single mtd device. The ar71xx target provides custom code to create
such mtdconcat devices. When porting devices to ath79, however, there is
no way to create such devices from within the device tree.
This commit adds a driver for creating virtual mtd-concat devices to the
ath79 target. Nodes must have a compatible = "virtual,mtd-concat" line,
and define a list of devices to concat in the 'devices' property,
for example:
flash {
compatible = "virtual,mtd-concat";
devices = <&flash0 &flash1>;
};
The driver is added to the very end of the mtd Makefile to increase the
likelyhood of all child devices already being loaded at the time of
probing, preventing unnecessary deferred probes which might in turn
cause other problems (like failure to load MAC addresses from art because
the partitions are not loaded yet).
Signed-off-by: Bernhard Frauendienst <openwrt@nospam.obeliks.de>
ELECOM WRC-300GHBK2-I is a 2.4 GHz wireless router, based on Qualcomm
Atheros QCA9563.
Specification:
- Qualcomm Atheros QCA9563
- 64 MB of RAM (DDR2)
- 8 MB of Flash (SPI-NOR)
- 2T2R 2.4 GHz wifi
- SoC internal
- 5x 10/100/1000 Mbps Ethernet
- 3x LEDs, 4x keys(connected to GPIO: 3x)
- UART header on PCB
- TX, GND, RX, Vcc from ethernet port side
- 115200n8
Flash instruction using factory image:
1. Boot the WRC-300GHBK2-I normaly and connect the computer to its
LAN port
2. Access to "http://192.168.2.1/" and open firmware update page
("ファームウェア更新 手動更新(アップデート)")
3. Select the OpenWrt factory image and click apply ("適用") button
to perform firmware update
4. On the (initramfs) factory image, execute "mtd erase firmware" to
erase stock firmware and execute sysupgrade with squashfs-sysupgrade
image for WRC-300GHBK2-I
5. Wait ~150 seconds to complete flashing
Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
This patch ports over support for the device from ar71xx.
SOC: AR7370 (Wasp - AR9344 rev2 0001974c)
RAM: Winbond W9725G6KB-25 32MiB
FLASH: Winbond 25Q64FVSIG 8MiB
WLAN: AR9380 Dual-Band 802.11abgn 3x3:3
INPUT: WPS, RESET button (hardware on/off toggle button)
LED: Power, LAN, WiFi, 3 RSSI-Leds (low, medium, high)
Serial: Header Next to the winbond flash chip (labeld JP1)
Pinout is GND - NC - RX - TX - 3V3 (JP1)
The Serial setting is 115200-8-N-1.
- Installation via uboot's upgrade command
0. attach serial cable
1. interrupt uboot and enter "upgrade code.bin" into
the u-boot prompt
ar7240> upgrade code.bin
2. rename openwrt...sysupgrade.bin to code.bin on PC
3. run a tftp-client on the PC
(shell)$ tftp 192.168.1.230
binary
put code.bin
4. wait for the device to finish
[...]
Copy buff to Flash from 0x9f040000 length 0x79f000
Copy to Flash... write addr: 9f040000
done
5. enter "go" in the u-boot prompt
ar7240> go
- TFTP ramdisk image boot from the uboot prompt
(tftp server defaults to serverip 192.168.1.254)
=> tftpboot 81000000 initramfs.bin
=> bootm
Tested and working:
- LEDs
- Buttons
- Ethernet
- Wi-Fi
- OpenWRT sysupgrade
For flashing and debricking information see:
<https://openwrt.org/toh/wd/rext>
Users coming from ar71xx can use sysupgrade too. But I highly
advise to no save the old configuration and start from a clean
state.
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
This patch ports the cybertan_part code from ar71xx and converts the
driver to a DT-supported mtd parser. As a result, it will no longer
add the u-boot, nvram and art partitions, which were never part of
the special Cybertan header.
Instead these partitions have to be specified in the DT, which has the
upside of making it possible to add properties (i.e.: read-only), labels
and references to these important partitions.
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
The board is made by Avnet, so rename it accordingly as
upstream has done it
Also move the device to maintain alphabetic order
Signed-off-by: Luis Araneda <luaraneda@gmail.com>
Implement the generation of sdcard images with ext4 or
squashfs + f2fs overlay, but only enable the latter
automatically
Additionally, add mkf2fs and e2fsprogs to default packages
to manipulate ext4 and f2fs filesystems
Finally, disable the automatic generation of initramfs
and rootfs.tar.gz images, as they are no longer required
(they can still be selected in menuconfig)
Signed-off-by: Luis Araneda <luaraneda@gmail.com>
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>