This patch provides full GPIO support for WNR612v2 (LEDs and buttons).
It exposes all LEDs to operating system, including Ethernet ones.
Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
SVN-Revision: 48924
This patch add speed_mask parameter to Ethernet port LED initialization
during system startup. LEDs are configured to show amber light for 10 Mbps
link and green for 100 Mbps as described on device label.
Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
SVN-Revision: 48923
This patch provides full GPIO support for WNR2000v3 (LEDs and buttons).
It exposes all LEDs to operating system, including Ethernet ones.
Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
SVN-Revision: 48922
Combine all bus operations for one MMD access in one function.
Protecting all these bus operations with one lock also helps
to avoid potential issues due to bus operations intercepting
the register and data write.
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
SVN-Revision: 48914
The default TTL for address resolution table entries is 5 minutes
for all members of the AR8216 family. This can cause issues if
e.g. Wifi clients roam to another AP and their MAC appears on
another switch port suddenly. Then the client may not be reachable
until the old ARL entry expires.
I would have expected the switch to invalidate old entries if it
detects the same MAC on another port. But that's not the case.
Therefore make the TTL for ARL entries configurable.
The effective TTL will always be a multiple of 7 seconds.
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
SVN-Revision: 48913
The line before includes the port number anyway so there's no need
to duplicate the port number in the MIB info header.
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
SVN-Revision: 48912
The decimal values especially for TxByte and RxGoodByte are hard to read
once bigger amounts of data have been transferred.
Therefore complement the decimal values with info in GiB / MiB / KiB.
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
SVN-Revision: 48911
For unused switch ports all MIB values are zero. Displaying ~40 empty
MIB counters is just confusing and makes it hard to read the output of
swconfig dev <dev> show.
Therefore, if all MIB counters for a port are zero, just display
an info that the MIB counters are empty.
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
SVN-Revision: 48910
This patch adds profiles and support for building factory and
sysupgrade images for JHR-N805R, JHR-N825R and JHR-N926R.
Signed-off-by: Reinhard Max <reinhard@m4x.de>
Reviewed-by: Torsten Duwe <duwe@lst.de>
SVN-Revision: 48906
This patch adds support for JHR-N805R, JHR-N825R and JHR-N926R to
various scripts in the base-files directory.
Signed-off-by: Reinhard Max <reinhard@m4x.de>
Reviewed-by: Torsten Duwe <duwe@lst.de>
SVN-Revision: 48905
Add a device tree for JCG JHR-N825R
This router is based on a RT3052 and has 4MB of CFI flash and 32MB of
SDRAM. As a special feature, it comes with a two digit seven segment
display that is connected to a pair of daisy-chained 74164 shift
registers that can be controlled via GPIOs.
For details, see https://wikidevi.com/wiki/JCG_JHR-N825R .
Signed-off-by: Reinhard Max <reinhard@m4x.de>
Reviewed-by: Torsten Duwe <duwe@lst.de>
SVN-Revision: 48904
Add a device tree for JCG JHR-N825R
This router is based on a RT3052 and has 4MB of CFI flash and 32MB of
SDRAM. For details, see https://wikidevi.com/wiki/JCG_JHR-N825R .
Signed-off-by: Reinhard Max <reinhard@m4x.de>
Reviewed-by: Torsten Duwe <duwe@lst.de>
SVN-Revision: 48903
Add a device tree for JCG JHR-N805R
This router is based on a RT3050 and has 4MB of SPI flash and 16MB of
SDRAM. For details, see https://wikidevi.com/wiki/JCG_JHR-N805R .
Signed-off-by: Reinhard Max <reinhard@m4x.de>
Reviewed-by: Torsten Duwe <duwe@lst.de>
SVN-Revision: 48902
Commit d0f5ab6d95a1 ("ramips: Added support for ZBT-826 / ZBT-1026")
incorrectly changed the mode of the ramips shell scripts from 755 to 644.
I.e., they are not excutable any more and for example devices will be left
with broken configs.
Signed-off-by: Kristian Evensen <kristian.evensen@gmail.com>
SVN-Revision: 48893
Enable platform-supplied WLAN LED name for ath9k device.
Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
Acked-by: Hartmut Knaack <knaack.h@gmx.de>
SVN-Revision: 48879
This patch moves the OOLITE profile code into the overarching Gainstrong
profile and deletes the old single profile file.
Signed-off by: Stijn Segers <francesco.borromini@inventati.org>
SVN-Revision: 48866
The ubdev01 profile defines its own MTDPARTS with smaller firmware
partition, so give it its own UBNT_BOARD in mkfwimage.
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
SVN-Revision: 48828
This is the first patch of a series of three to tidy up the profiles for
Gainstrong devices. Right now there are two Gainstrong profiles, each
for a single device built by this manufacturer. This patch renames the
MiniBox profile to Gainstrong and updates the copyright notice.
The series applies cleanly to current trunk. Resent with the architecture in
the subject, forgot that the first time.
Signed-off by: Stijn Segers <francesco.borromini@inventati.org>
SVN-Revision: 48797
Hi,
the board in subject (RT5350F-OLinuXino-EVB) still ships from vendor
with a RC3 image built upon a .dts file which declares GPIO12 and GPIO14
as relay2 and relay1 respectively, as you can see from their rt5350f
branch on GitHub.
For some reason in the official stable build both the GPIOs are swapped
and the wrong names are declared in the gpio-export directive.
I'm submitting this patch which should roll back the wrong changes, so
that we get backward compatibility with any script developed on RC3
which controls the relays.
After patching correct operation is restored:
root@OpenWrt:/# cat /sys/kernel/debug/gpio
GPIOs 0-21, platform/10000600.gpio, 10000600.gpio:
gpio-0 (button ) in hi
gpio-12 (relay2 ) out lo
gpio-14 (relay1 ) out lo
Thank you,
Signed-off-by: Lorenzo Cafaro <lorenzo@ibisco.net>
SVN-Revision: 48796
The vdso version of this function has some problems with the cache.
Very often it works on dated data which causes problem. We are
currently working on fixing this in upstream Linux kernel.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
SVN-Revision: 48787
Fix for invalid/random WLAN MAC address in WNR612v2. Permanent platform
MAC is calculated and assigned during system startup. WLAN MAC follows
wired Ethernet interface addresses. This is the same fix as for WNR2000v3.
Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
SVN-Revision: 48779
Netgear WNR612v2 has no USB port yet default system image
includes USB kernel modules. This patch fixes that.
Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
SVN-Revision: 48778
Fix for invalid/random WLAN MAC address in WNR2000v3. Permanent platform
MAC is calculated and assigned during system startup. WLAN MAC follows
wired Ethernet interface addresses.
Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
SVN-Revision: 48777
This patch adds speed_mask special file to LEDs connected to switch ports
via 'switch' trigger. It allows to choose which speeds to signal when link
is up. If router has more than one LED per port, they may light up
differently depending on how fast connection is. Default setting is 'all
speeds' so backward compatibility with system scripts (for example uci) is
maintained.
Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
SVN-Revision: 48775
This patch changes swconfig_trig_port_mask_store() handler to utilize
kstrtoul() function instead of call to obsolete simple_strtoul(). Thanks
to this change, new handler takes less memory and makes port_mask special
file accept not only hexadecimal, but also decimal and octal numbers.
Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
SVN-Revision: 48774
As indicated in the bug tracker[1], failsafe mode is broken on at least some
devices using the mt7620 switch (and possibly mt7621). The thread explicitly
mentions the Xiaomi MiWifi, and the Nexx WT3020, and an unspecified device
using the mt7621 switch; the issue also applies to the Netgear EX2700.
The problem is that failsafe mode uses eth0, but enable_vlan is always set to 1
by the switch driver. Connecting to and/or pinging the device fails. This patch
fixes the failsafe preinit config, by making sure that vlan support is disabled.
It currently only fixes the switch config on mt7620, but might apply to the
mt7621 as well, so the patch has been designed with this in mind.
A similar (line wrapped) patch was submitted in December by Simon Peter, but never
accepted and/or discussed.
This patch applies to both Chaos Calmer and trunk.
[1] https://dev.openwrt.org/ticket/18768
Signed-off-by: Joseph C. Lehner <joseph.c.lehner@gmail.com>
SVN-Revision: 48772
This patch adds support for building factory and sysupgrade images
for the Netgear EX2700 that don't require modification of u-boot
environment variables.
The bootloader on this device expects the kernel partition to end
on a 64k block boundary. The last 64 byte of the kernel partition
must contain a valid uImage header - in the stock firmware, this is
the uImage header of the root filesystem. For this patch, we're using
the uImage header of a 0 byte partition (ex2700-fakeroot.uImage).
Signed-off-by: Joseph C. Lehner <joseph.c.lehner@gmail.com>
SVN-Revision: 48771
- remove the suffix (N, ND) to indicate that the image is for all
WR841-models
- some of these models have a "N"-suffix, others have (ND)-suffix,
but the boards are the same - only difference is the detachable
antenna on "D"-models
- discussed this idea to remove the suffix in IRC with jow and Borromini
Signed-off-by: Sven Roederer <devel-sven@geroedel.de>
SVN-Revision: 48767
Seama format has 2 similar headers: container (seal) header and entity
header. The first one has size always set to 0 and doesn't contain MD5
digest.
When dealing with Seama on a flash we deal directly with an entity. You
can see mtdsplit_parse_seama reads from offset 0 and expects entity to
be there. Seama container is used by bootloader / interface only which
extract entity out of it and flash it.
That said we should fix our header struct. This is important as we
calculate possible rootfs offset assuming it may be placed right after
Seama entity. So far calculate offset was always 16B too low.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
SVN-Revision: 48754
- Fix typo in board_data partition start address
- Increase board_data partition size in order to exploit all flash size
Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi83@gmail.com>
SVN-Revision: 48751
This patch introduces support of new boards with ARC HS38 cores.
ARC HS38 is a new generation of ARC cores which utilize ARCv2 ISA.
As with ARC770 we're addind support for 2 boards for now:
[1] Synopsys SDP board (AXS103)
This is the same base-board as in AXS101 but with
FPGA-based CPU-tile where ARCHs38 core is implemented.
[2] nSIM
Again this is the same simulation engine but configured for
new instruction set and features of new CPU.
Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Felix Fietkau <nbd@openwrt.org>
Cc: Jo-Philipp Wich <jow@openwrt.org>
Cc: Jonas Gorski <jogo@openwrt.org>
SVN-Revision: 48740
This patch adds support for Phicomm PSG1208.This is a router with MT7620A SoC with 8M flash and 64M ram.
The WPS led is uesd as status_led because the power light can't be controlled with GPIO.
It seems that the 5g wifi led is connected to MT7612E and it can't be controlled with GPIO too.
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
SVN-Revision: 48721
Netgear WNR2000v3 has no USB port yet default system image
includes USB kernel modules. This patch fixes that.
Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
SVN-Revision: 48701
Avoids inadvertent file creation when executing
`/etc/init.d/dsl_control status`.
Signed-off-by: Jonathan A. Kollasch <jakllsch@kollasch.net>
SVN-Revision: 48700
This patch adds support for the Netgear EX2700 and builds an approriate
sysupgrade image.
What's missing is the option to build a factory image flashable via the
router's stock web interface, but this approach is hindered by the fact
that u-boot operforms an additional integrity check, which expects a
uImage header in the last 64 bytes of the "kernel" partition, which
the bootloader expects to be 960k, a size exceeded by the standard
OpenWrt kernel.
Signed-off-by: Joseph C. Lehner <joseph.c.lehner@gmail.com>
SVN-Revision: 48698
Add support for Xilinx ZC702 Dev board
Zynq target is using 4.4 kernel and mainline 2016.1 u-boot.
Patch is tested with Xilinx ZC702 Dev board with SD boot mode.
known issues:
- no QSPI driver in 4.4 kernel: no QSPI flash support
- USB is not working in 4.4 kernel
Signed-off-by: Jason Wu <jason.wu.misc@gmail.com>
create mode 100644 package/boot/uboot-zynq/Makefile
create mode 100644 target/linux/zynq/Makefile
create mode 100644 target/linux/zynq/base-files.mk
create mode 100755 target/linux/zynq/base-files/etc/board.d/02_network
create mode 100644 target/linux/zynq/base-files/etc/config/network
create mode 100644 target/linux/zynq/base-files/etc/inittab
create mode 100644 target/linux/zynq/config-4.4
create mode 100644 target/linux/zynq/image/Makefile
create mode 100755 target/linux/zynq/image/mkits.sh
create mode 100644 target/linux/zynq/patches-4.4/0001-arm-dts-zynq-zc702.dts-Set-default-rdinit-to-sbin-in.patch
create mode 100644 target/linux/zynq/profiles/zc702.mk
SVN-Revision: 48697
Update OpenWRT build tree to reflect changes in TLC-591xx LED family driver.
In kernels < 4.0 the driver was present in form of a patch for the TLC-59116 chip,
and was upstreamed later in kernels > 4.0 to support the entire chip family.
Signed-off-by: Sebastian Careba <nitroshift@yahoo.com>
[jow: fix Kconfig symbol name]
Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>
SVN-Revision: 48684
With this patch sysupgrade will write directly to the partitions
instead of to the main disk. The UUID is copied from the image
to the MBR as well. This prevents the mbr from being completely
overwritten and losing the partition table. The -p option has
been added to maintain the original behavior and overwite the
entire disk with the new image. Tests have been added to ensure
that the image partitions match up with the active partitions.
Signed-off-by: Rob Mosher <nyt-openwrt@countercultured.net>
SVN-Revision: 48682
The top half of UARTF on the HLK-RM04 is used for GPIO.
mode 1 mode 2
RIN GPIO14
DSR_N GPIO13
DCD_N GPIO12
DTR_N GPIO11
RXD GPIO10
CTS_N GPIO09
TXD GPIO08
RTS_N GPIO07
This patch applies 3'b101 mode to UARTF:
GPIO14
GPIO13
GPIO12
GPIO11
RXD
CTS_N
TXD
RTS_N
Because the base rt5350.dtsi file forces 3'b000 mode, remove the pin setting from this file and apply it directly to the files that inherit from it (WIZFI630A.dts and WT1520.dtsi). This change makes the rt5350.dtsi file consistent with the mt7620a.dtsi file.
Signed-off-by: John Clark <inindev@gmail.com>
SVN-Revision: 48665
The I2C function of the RT5350 SoC on the HLK-RM04 is used for GPIO1 and GPIO2.
Take note that the I2C_SD pin is GPIO1 on the RT5350 and is exposed on the HLK-RM04 as GPIO0
Likewise the I2C_SCLK pin is GPIO2 on the RT5350 and is exposed on the HLK-RM04 as GPIO1
group mode 1 mode 2 hlk-rm04 pin & export
i2c i2c_sd gpio1 (pin 8, hlk-rm04:gpio0)
i2c i2c_sclk gpio2 (pin 9, hlk-rm04:gpio1)
reference:
http://www.hlktech.net/product_detail.php?ProId=39http://cdn.sparkfun.com/datasheets/Wireless/WiFi/RT5350.pdf
Signed-off-by: John Clark <inindev@gmail.com>
SVN-Revision: 48664
The RESET button of the HLK-RM04 is connected to GPIO0, linux function 0x198
The WPS button of the HLK-RM04 is connected to GPIO14, linux function 0x211
Signed-off-by: John Clark <inindev@gmail.com>
SVN-Revision: 48663
The power LED on the HLK-RM04 is hard wired to the power bus and is not under GPIO control, remove the bogus config for it.
(Note that GPIO0 is actually connected to the RESET button.)
Signed-off-by: John Clark <inindev@gmail.com>
SVN-Revision: 48662
With the backport of the kernel 4.5 pinctrl-xway patches (3551609d &
826bca29) the pinmux group "spi" was splitted into "spi_di", "spi_do" &
"spi_clk". But the no longer existing group "spi" is still used by some
device tree source files.
This fixes the detection of the wireless chipset of the VGV7510KW22.
Signed-off-by: Mathias Kresin <openwrt@kresin.me>
SVN-Revision: 48658
The stock u-boot doesn't disable unused flash banks. Therefore, the nand
driver tries to initialize a not connected NOR flash and the device
hangs on boot.
Workaround the issue by selecting the second flash bank (NAND).
Signed-off-by: Mathias Kresin <openwrt@kresin.me>
Acked-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
SVN-Revision: 48657
When dealing with Broadcom hardware we can simply use swconfig's generic
helper, we just need to do some validation of requested state.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
SVN-Revision: 48623
Thanks to this change swconfig can access port PHYs e.g. when setting
port link state with a generic helper.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
SVN-Revision: 48622
It's quite common for switches to have PHY per port so adding a generic
helper setting link state will help many drivers. It just needs an API
to access PHYs which this patch also adds.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
SVN-Revision: 48621
Some D-Link routers (e.g. DIR-885L) have NAND and use Seama format. It
means OpenWrt will want to have UBI in Sseama entity and should be able
to detect it.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
SVN-Revision: 48600
Our mtdsplit parsers may want to create partition with name choice based
on partition file system (e.g. SquashFS vs. JFFS2). This patch allows
passing extra argument pointing to variable that will be set properly.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
SVN-Revision: 48598
All other SoC types are using "lantiq,sram" and "simple-bus" to ensure
that all child nodes are set up correctly during linux kernel
initialization (plat_of_setup(void) in arch/mips/lantiq/prom.c). Without
this some of sram child nodes might not be parsed.
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
SVN-Revision: 48548
This removes a lot of duplicate register and interrupt definitions by
moving the xrx200-net definition to vr9.dtsi and making all devices re-
use it.
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
SVN-Revision: 48547
Linux now has device tree support for malta. The patch for correcting
/proc/iomem content is not needed now. Previously it was
root@(none):/# cat /proc/iomem
00000000-00000fff : reserved
00001000-000effff : System RAM
000f0000-000fffff : reserved
00100000-0fffefff : System RAM
00100000-003f2b6b : Kernel code
003f2b6c-00485937 : Kernel data
...
Now it's
root@OpenWrt:/# cat /proc/iomem
00000000-0fffefff : System RAM
00100000-004a3297 : Kernel code
004a3298-0057cfff : Kernel data
...
The kernel config was prepared as follows
1. cp target/linux/malta/config-{3.18,4.4}
2. make kernel_menuconfig CONFIG_TARGET=subtarget_platform
Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
SVN-Revision: 48543
Initially 4.4 didn't work on bcm53xx because network was breaking few
seconds after setting interfaces. It's fixed since r48059 (switching
from 4.4-rc5 to 4.4-rc7).
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
SVN-Revision: 48510
Rename kernel_size variable as it includes whole entity size, not just a
kernel size. Also update comments to match it and describe better what
are we checking/looking for.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
SVN-Revision: 48480
The new .abiflags section was kept, pushing the appended arguments to
the wrong offset and causing it to read the section instead, making
it fail on boot.
Fix this by dropping this section as well as the other sections.
Closes#21679.
Signed-off-by: Jonas Gorski <jogo@openwrt.org>
SVN-Revision: 48474
Directly return the return value of genl_register_family_with_ops()
instead of storing it in a temporary variable, then returning it.
Signed-off-by: Jonas Gorski <jogo@openwrt.org>
SVN-Revision: 48472
This reverts commit r48335
The workaround is incomplete and cannot cover all possible cases. The
only real solution to this problem is to disable this feature on
ARM11MPcore entirely.
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 48460
This reverts commit r48276.
This can overwrite the caldata_backup partition, so the layout needs to
be changed in a different way.
Thanks to Arjen de Korte for spotting the issue.
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 48456
r48337 unfortunately incorrectly changed the boardname of the stg212
into stg-212 which is not the name of the image of DTS file or
boardname using sysupgrade, which is 'stg212' and imho should stay
that way.
The changes r48337 made for pogoplug-pro and pogoplug-v3 were correct,
thus this commit only partially reverts r48337.
Also properly set default for USB LED while already at it.
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
SVN-Revision: 48398
r48381 added CONFIG_MTD_SPLIT_UIMAGE_FW=Y to the lantiq kernel
configuration. That unfortunately contains a typo since the "y" has to
be lower-case. This leads to the kernel asking whether the config
symbol should be enabled and thus breaking the build.
FIXES: r48381/feab990887b4: lantiq: Enable the uImage mtd splitter
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
SVN-Revision: 48389
Until linux 4.1 the lantiq target used CONFIG_MTD_UIMAGE_SPLIT=y. That
option however is only available until linux 4.3 - thus it was not added
to lantiq's 4.4 kernel config (in r48307). This results in broken images
for devices which are using uImages. This fixes#21652
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
SVN-Revision: 48381
The bootloader was updated and now uses 115200 instead of 57600 baud
for the serial console. Change this also in OpenWrt's DTS, so the rate
is consistent for bootloader and linux kernel output.
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
SVN-Revision: 48359
The image name for the HiLink HLK-RM04 module has a typo and should read "RM04" rather than "RM02"
Signed-off-by: John Clark <inindev@gmail.com>
SVN-Revision: 48355