openwrt/staging/lynxis.git
6 years agoar71xx: fix bad "proto" references in default network configuration
Jo-Philipp Wich [Fri, 25 May 2018 07:44:28 +0000 (09:44 +0200)]
ar71xx: fix bad "proto" references in default network configuration

This change was originally meant to go along with the ucidef_set_interface()
fixup.

Fixes: 7e664b7c2d ("base-files: fix ucidef_set_interface() protocol selection")
Fixes: 85048a9c1f ("base-files: rework _ucidef_set_interface to be more generic")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
6 years agobase-files: fix ucidef_set_interface() protocol selection
Jo-Philipp Wich [Fri, 25 May 2018 05:28:28 +0000 (07:28 +0200)]
base-files: fix ucidef_set_interface() protocol selection

The previous refactoring of ucidef_set_interface() removed the protocol
selection heuristic which breaks the networking defaults for the majority
of boards.

Re-add the protocol selection and rename two bad "proto" references to
the expected "protocol" value.

Fixes: 85048a9c1f ("base-files: rework _ucidef_set_interface to be more generic")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
6 years agohostapd: update to git HEAD of 2018-05-21, allow build against wolfssl
Daniel Golle [Sat, 28 Apr 2018 19:12:19 +0000 (21:12 +0200)]
hostapd: update to git HEAD of 2018-05-21, allow build against wolfssl

Support for building wpa_supplicant/hostapd against wolfssl has been
added upstream recently, add build option to allow users using it.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
6 years agomediatek: add mt7622 subtarget
John Crispin [Thu, 24 May 2018 20:10:49 +0000 (22:10 +0200)]
mediatek: add mt7622 subtarget

Signed-off-by: John Crispin <john@phrozen.org>
6 years agomediatek: backport upstream mediatek patches
John Crispin [Mon, 7 May 2018 10:07:32 +0000 (12:07 +0200)]
mediatek: backport upstream mediatek patches

Signed-off-by: John Crispin <john@phrozen.org>
6 years agowolfssl: update to version 3.14.4
Daniel Golle [Wed, 23 May 2018 21:26:41 +0000 (23:26 +0200)]
wolfssl: update to version 3.14.4

Use download from github archive corresponding to v3.14.4 tag because
the project's website apparently only offers 3.14.0-stable release
downloads.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
6 years agoustream-ssl: fix build against wolfSSL
Daniel Golle [Thu, 24 May 2018 16:51:44 +0000 (18:51 +0200)]
ustream-ssl: fix build against wolfSSL

commit 39a6ce205d (ustream-ssl: Enable ECDHE with OpenSSL.) broke
build against wolfSSL because wolfSSL doesn't (yet) support
SSL_CTX_set_ecdh_auto() of the OpenSSL API.

Fix this in ustream-ssl:

 189cd38b41 don't use SSL_CTX_set_ecdh_auto with wolfSSL

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
6 years agotools: zlib: do not hardcode the install prefix in zlib.pc
Jo-Philipp Wich [Thu, 24 May 2018 15:01:54 +0000 (17:01 +0200)]
tools: zlib: do not hardcode the install prefix in zlib.pc

Our pkg-config wrapper relies on the ability to redefine the $prefix and
$exec_prefix variables in order to construct proper search paths relative
to the build environment.

Patch the .pc file template to construct libdir, sharedlibdir and includedir
relative to the ${prefix} variable so that it can be overridden as needed.

This also fixes the libxml2/host build issue raised at
https://github.com/openwrt/packages/issues/6073 - it was caused by libxml2's
configure picking up a wrong host search path through zlib.pc, letting it
include the wrong endian.h, causing spurious member redeclaration errors in
system headers.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
6 years agofstools: Add the new options available in the menuconfig
Pierre Lebleu [Thu, 24 May 2018 12:20:33 +0000 (14:20 +0200)]
fstools: Add the new options available in the menuconfig

Mounting using the zlib compression and mounting with
full access accounting are now available in the
menuconfig.

Signed-off-by: Pierre Lebleu <pme.lebleu@gmail.com>
6 years agoath79: initial tl-wr1043nd v1 support
Lucian Cristian [Sat, 19 May 2018 17:12:58 +0000 (20:12 +0300)]
ath79: initial tl-wr1043nd v1 support

Signed-off-by: Lucian Cristian <lucian.cristian@gmail.com>
Signed-off-by: John Crispin <john@phrozen.org>
6 years agokernel: add reset control support to rtl8366 driver
John Crispin [Wed, 23 May 2018 22:23:16 +0000 (00:23 +0200)]
kernel: add reset control support to rtl8366 driver

Signed-off-by: John Crispin <john@phrozen.org>
6 years agoath79: fix adjust_link callback for ar9130
John Crispin [Wed, 23 May 2018 21:46:33 +0000 (23:46 +0200)]
ath79: fix adjust_link callback for ar9130

Signed-off-by: John Crispin <john@phrozen.org>
6 years agoath79: make ahb wifi work
John Crispin [Mon, 14 May 2018 05:11:56 +0000 (07:11 +0200)]
ath79: make ahb wifi work

Signed-off-by: John Crispin <john@phrozen.org>
6 years agoRevert "dnsmasq: use "hostsdir" instead of "addn-hosts""
Hans Dedecker [Thu, 24 May 2018 08:11:20 +0000 (10:11 +0200)]
Revert "dnsmasq: use "hostsdir" instead of "addn-hosts""

This reverts commit a03035dad198cd4b51645ceb43c1170f9cf95f16
as it has several issues:
-Host file is located in a directory which is not unique per dnsmasq instance
-odhcpd writes host info into the same directory but still sends a SIGHUP to dnsmasq

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
6 years agobase-files: rework _ucidef_set_interface to be more generic
Roman Yeryomin [Fri, 4 May 2018 15:42:36 +0000 (18:42 +0300)]
base-files: rework _ucidef_set_interface to be more generic

This is a rework of previously submitted patch reworking
ucidef_set_interface_raw [1]. Here, keep the idea but instead
make _ucidef_set_interface more generic and use it instead of
ucidef_set_interface_raw.
Also change the users like ucidef_set_interface_lan and others.

[1] https://patchwork.ozlabs.org/patch/844961/

Signed-off-by: Roman Yeryomin <roman@advem.lv>
6 years agokernel: bump 4.14 to 4.14.43
Koen Vandeputte [Wed, 23 May 2018 14:44:09 +0000 (16:44 +0200)]
kernel: bump 4.14 to 4.14.43

Refreshed all patches

Compile-tested on: cns3xxx, imx6, x86_64
Runtime-tested on: cns3xxx, imx6, x86_64

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
Tested-by: Michael Yartys <michael.yartys@protonmail.com>
6 years agokernel: bump 4.9 to 4.9.102
Koen Vandeputte [Wed, 23 May 2018 14:44:08 +0000 (16:44 +0200)]
kernel: bump 4.9 to 4.9.102

Refreshed all patches

Compile-tested on: ar71xx
Runtime-tested on: ar71xx

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
6 years agoramips: Fix up GnuBee PC1 DTS file a little
Rosen Penev [Thu, 24 May 2018 02:24:43 +0000 (19:24 -0700)]
ramips: Fix up GnuBee PC1 DTS file a little

There's nothing connected to i2c on this board, so remove it.

Also edited the gpio group to match the PC2 as they're the same.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
6 years agoramips: Add back some non-mt7621 code that staging removed
Rosen Penev [Thu, 24 May 2018 02:24:42 +0000 (19:24 -0700)]
ramips: Add back some non-mt7621 code that staging removed

Staging is meant only for mt7621 but for OpenWrt more is needed.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
6 years agobrcm47xx: add switch port mapping to Asus WL-500W
Mirko Parthey [Tue, 22 May 2018 19:23:36 +0000 (21:23 +0200)]
brcm47xx: add switch port mapping to Asus WL-500W

Switch ports 0..3 are connected to external ports LAN{1..4} in sequence,
switch port 4 is not used, and switch port 5 is connected to the CPU.
The WAN port is attached to the CPU's second network interface; it has no
connection to the internal switch.

Reuse the "Dell TrueMobile 2300" entry, which describes the same mapping.

Signed-off-by: Mirko Parthey <mirko.parthey@web.de>
6 years agokernel: mark all v3.18 and v4.4 kernels are source-only
John Crispin [Thu, 24 May 2018 06:55:17 +0000 (08:55 +0200)]
kernel: mark all v3.18 and v4.4 kernels are source-only

These will be removed if not updated to v4.4

Signed-off-by: John Crispin <john@phrozen.org>
6 years agodnsmasq: use "hostsdir" instead of "addn-hosts"
Christian Schoenebeck [Tue, 22 May 2018 18:36:18 +0000 (20:36 +0200)]
dnsmasq: use "hostsdir" instead of "addn-hosts"

1.) "addn-hosts" per default point to a file (but it supports directory)
2.) "hostsdir" only support directory with the additional benefit: New or changed files are read automatically.

Signed-off-by: Christian Schoenebeck <christian.schoenebeck@gmail.com>
6 years agotoolchain/glibc: update to latest 2.26 commit
Hans Dedecker [Wed, 23 May 2018 13:14:43 +0000 (15:14 +0200)]
toolchain/glibc: update to latest 2.26 commit

af7519f7b3 Fix path length overflow in realpath [BZ #22786]
365722ace6 Fix stack overflow with huge PT_NOTE segment [BZ #20419]
be056fae3b Fix blocking pthread_join. [BZ #23137]
02f0dd83a4 Fix signed integer overflow in random_r (bug 17343).
3241353ab2 i386: Fix i386 sigaction sa_restorer initialization (BZ#21269)
677e6d13e0 [BZ #22342] Fix netgroup cache keys.
71d339cb86 Fix i386 memmove issue (bug 22644).
31e2d15b80 Fix crash in resolver on memory allocation failure (bug 23005)
1f7c4748d6 getlogin_r: return early when linux sentinel value is set
7e7a5f0bcd resolv: Fully initialize struct mmsghdr in send_dg [BZ #23037]

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
6 years agouboot-zynq: fix build on hosts lacking pkg-config
Jo-Philipp Wich [Wed, 23 May 2018 07:32:25 +0000 (09:32 +0200)]
uboot-zynq: fix build on hosts lacking pkg-config

The uboot-mvebu package incorrectly used the host pkg-config for the tool
build parts, which broke the build on systems lacking pkg-config and only
worked by accident on those that have it installed.

Export the host-build specific environment variables for the uboot build
to redirect pkg-config invocations to our staged host build pkg-config in
buildroot.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
6 years agouboot-mxs: fix build on hosts lacking pkg-config
Jo-Philipp Wich [Wed, 23 May 2018 07:15:52 +0000 (09:15 +0200)]
uboot-mxs: fix build on hosts lacking pkg-config

The uboot-mvebu package incorrectly used the host pkg-config for the tool
build parts, which broke the build on systems lacking pkg-config and only
worked by accident on those that have it installed.

Export the host-build specific environment variables for the uboot build
to redirect pkg-config invocations to our staged host build pkg-config in
buildroot.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
6 years agouboot-mvebu: fix build on hosts lacking pkg-config
Jo-Philipp Wich [Wed, 23 May 2018 07:02:59 +0000 (09:02 +0200)]
uboot-mvebu: fix build on hosts lacking pkg-config

The uboot-mvebu package incorrectly used the host pkg-config for the tool
build parts, which broke the build on systems lacking pkg-config and only
worked by accident on those that have it installed.

Export the host-build specific environment variables for the uboot build
to redirect pkg-config invocations to our staged host build pkg-config in
buildroot.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
6 years agoramips: fix to mt7620a and add support for i2c on WD03
Matthias Badaire [Tue, 22 May 2018 10:06:55 +0000 (12:06 +0200)]
ramips: fix to mt7620a and add support for i2c on WD03

There was an error on initial commit, the proper soc is mt7620n (which is
more limited than mt7620a). Moreover, there is a battery management
controller connected to the i2c port of the mt7620n. I have a small piece
of i2c code to get battery level coming.

Signed-off-by: Matthias Badaire <mbadaire@gmail.com>
6 years agoath79: preliminary support for TP-Link WDR3600 / WDR4300 (AR9344)
Johann Neuhauser [Fri, 18 May 2018 16:06:03 +0000 (18:06 +0200)]
ath79: preliminary support for TP-Link WDR3600 / WDR4300 (AR9344)

working:
 - leds
 - buttons
 - lan / wan
 - usb (hub port 1 + 2)
 - wifi 5g
 - sysupgrade
 - ...

not working:
 - wifi 2g

Signed-off-by: Johann Neuhauser <johann@it-neuhauser.de>
6 years agokernel: bump 4.14 to 4.14.42
Koen Vandeputte [Tue, 22 May 2018 12:16:12 +0000 (14:16 +0200)]
kernel: bump 4.14 to 4.14.42

Refreshed all patches

Compile-tested on: cns3xxx, imx6, x86_64
Runtime-tested on: cns3xxx, imx6, x86_64

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
6 years agokernel: bump 4.9 to 4.9.101
Koen Vandeputte [Tue, 22 May 2018 12:16:11 +0000 (14:16 +0200)]
kernel: bump 4.9 to 4.9.101

Refreshed all patches

Compile-tested on: ar71xx
Runtime-tested on: ar71xx

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
6 years agoustream-ssl: update to latest git HEAD
John Crispin [Tue, 22 May 2018 18:44:34 +0000 (20:44 +0200)]
ustream-ssl: update to latest git HEAD

5322f9d mbedtls: Fix setting allowed cipher suites
e8a1469 mbedtls: Add support for a session cache

Signed-off-by: John Crispin <john@phrozen.org>
6 years agombedtls: Deactivate platform abstraction
Hauke Mehrtens [Mon, 21 May 2018 11:58:54 +0000 (13:58 +0200)]
mbedtls: Deactivate platform abstraction

This makes mbedtls use the POSIX API directly and not use the own
abstraction layer.
The size of the ipkg decreased by about 100 bytes.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
6 years agombedtls: Activate the session cache
Hauke Mehrtens [Mon, 21 May 2018 11:58:53 +0000 (13:58 +0200)]
mbedtls: Activate the session cache

This make sit possible to store informations about a session and reuse
it later. When used by a server it increases the time to create a new
TLS session from about 1 second to less than 0.1 seconds.

The size of the ipkg file increased by about 800 Bytes.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
6 years agombedtls: update to version 2.9.0
Hauke Mehrtens [Mon, 21 May 2018 11:58:52 +0000 (13:58 +0200)]
mbedtls: update to version 2.9.0

The soversion was changed in this version again and is now aligned with
the 2.7.2 version.
The size of the ipkg file stayed mostly the same.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
6 years agopackage sysfsutils: add support for sysfs settings at boot
Rodolfo Giometti [Wed, 28 Jun 2017 08:49:01 +0000 (10:49 +0200)]
package sysfsutils: add support for sysfs settings at boot

This patch is based on sysfsutils package's behaviour on Debian OS.

Signed-off-by: Rodolfo Giometti <giometti@linux.it>
6 years agoipq806x: drop "mtd: nand: add Winbond manufacturer and chip"
Stefan Lippers-Hollmann [Fri, 18 May 2018 02:54:12 +0000 (04:54 +0200)]
ipq806x: drop "mtd: nand: add Winbond manufacturer and chip"

The W25N01GV NAND is currently not used in any ipq806x device.

Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: drop linux 4.9 support
Stefan Lippers-Hollmann [Fri, 18 May 2018 02:50:09 +0000 (04:50 +0200)]
ipq806x: drop linux 4.9 support

Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: switch to linux 4.14
Stefan Lippers-Hollmann [Fri, 18 May 2018 02:48:20 +0000 (04:48 +0200)]
ipq806x: switch to linux 4.14

Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: remove spi-nor from r7800 dts
Pavel Kubelun [Thu, 18 Jan 2018 12:03:57 +0000 (15:03 +0300)]
ipq806x: remove spi-nor from r7800 dts

There's no spi-nor in R7800, so disable unequipped interfaces.

Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>
[slh: rebase for kernel v4.14 as well]
Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: remove rpm pinctrl from board dts
Pavel Kubelun [Thu, 18 Jan 2018 11:01:13 +0000 (14:01 +0300)]
ipq806x: remove rpm pinctrl from board dts

These pins seem to be used by hw exclusively, so claiming it in
kernel causes an error in syslog in k4.14+.

Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>
[slh: rebase for kernel v4.14 as well]
Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: fix EA8500 switch control
Pavel Kubelun [Thu, 18 Jan 2018 16:45:15 +0000 (19:45 +0300)]
ipq806x: fix EA8500 switch control

EA8500 has pcie2 slot unequipped.
By EA8500 hw design default pcie2 reset gpio (gpio63) is used to
reset the switch. That's why enabling pcie2 brings the switch into
a working state.

So let's just control the gpio63 without enabling the pcie2 slot.

We have to remove the pcie2_pins node so the gpio63 is not defined
twice. Because pcie2 node has a reference to pcie2_pins we have to
remove it as well.

Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>
[slh: rebase for kernel v4.14 as well]
Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: move mmc specific nodes into v1.0 dtsi
Pavel Kubelun [Thu, 18 Jan 2018 14:32:19 +0000 (17:32 +0300)]
ipq806x: move mmc specific nodes into v1.0 dtsi

These nodes are common for all revisions so put it into SoC v1.0
dtsi file.

Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>
[slh: rebase for kernel v4.14 as well]
Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: fix pcie tx termination offset
Pavel Kubelun [Thu, 18 Jan 2018 10:51:25 +0000 (13:51 +0300)]
ipq806x: fix pcie tx termination offset

According to GPL tarballs and QSDK related branch tx termination
offset for ipq8064 SoC version >= 2.0 should be equal to 0 and
not 7.

https://github.com/paul-chambers/netgear-r7800/blob/master/git_home/linux.git/sourcecode/arch/arm/mach-msm/board-ipq806x.c#L1682-L1685

Fix this.

Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>
[slh: rebase for kernel v4.14 as well]
Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: apply updated USB PHY settings to v2.0 SoC
Pavel Kubelun [Thu, 18 Jan 2018 10:38:18 +0000 (13:38 +0300)]
ipq806x: apply updated USB PHY settings to v2.0 SoC

USB PHY power settings introduced for ipq8065 SoC with commit
644a0d5 "ipq8065: adjust SS USB PHY power settings"

According to that commit msg and in correspondence to GPL tarballs
and related QSDK branch those settings are applied to ipq8064
SoCs of version >= 2.0.

https://github.com/paul-chambers/netgear-r7800/blob/master/git_home/linux.git/sourcecode/arch/arm/mach-msm/board-ipq806x.c#L2507-L2514

Now as we have clarified that mass market boards are of SoC v2.0
move those USB PHY settings from ipq8065 (v3.0 SoC) dtsi to
ipq8064 v2.0 dtsi.

Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>
[slh: rebase for kernel v4.14 as well]
Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: reference ipq8065 as ipq8064 v3.0
Pavel Kubelun [Thu, 18 Jan 2018 10:21:49 +0000 (13:21 +0300)]
ipq806x: reference ipq8065 as ipq8064 v3.0

ipq8065 is ipq8064 v3.0
> socinfo_init: v6, id=280, ver=3.0, raw_id=17, raw_ver=17, hw_plat=0,  hw_plat_ver=65536

Include dtsi accordingly and remove the unneeded qcom-ipq8065-v1.0.dtsi

Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>
[slh: rebase for kernel v4.14 as well]
Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: move mass market ipq8064 to v2 dtsi
Pavel Kubelun [Thu, 18 Jan 2018 10:04:33 +0000 (13:04 +0300)]
ipq806x: move mass market ipq8064 to v2 dtsi

According to OEM bootlog entry mass market devices are ipq8064 SoC
v2.0:
> socinfo_init: v6, id=202, ver=2.0, raw_id=2064, raw_ver=2064, hw_plat=0,  hw_plat_ver=65536

I've checked C2600, EA8500 and VR2600v but couldn't find other
boards bootlog. I think it's safe to assume that other boards are
also v2.0. R7500 may be an exception because it was the first
device to hit the market.

So switch to v2.0 dtsi.

Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>
[slh: rebase for kernel v4.14 as well]
Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: introduce ipq8064 SoC v2 dtsi
Pavel Kubelun [Thu, 18 Jan 2018 09:39:50 +0000 (12:39 +0300)]
ipq806x: introduce ipq8064 SoC v2 dtsi

According to QCA internal numbering there are 3 versions of
ipq8064/5 SoC:
ipq8064 v1.0 - probably ipq8064 evaluation boards only
ipq8064 v2.0 - probably ipq8064 mass market boards only
ipq8064 v3.0 - aka ipq8065, boards based on ipq8065.

Each next revision includes configuration differences from
previous revision and adds something new.

Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>
[slh: rebase for kernel v4.14 as well]
Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agokernel: iqp806x low latency kernel does not boot
Marc Benoit [Wed, 4 Apr 2018 22:57:50 +0000 (18:57 -0400)]
kernel: iqp806x low latency kernel does not boot

It keeps failing (R7800) with the stack trace below

BUG: scheduling while atomic: kworker/0:1/26/0x00000002

(unwind_backtrace) from [<c02121d0>] (show_stack+0x10/0x14)
(show_stack) from [<c03932e4>] (dump_stack+0x7c/0x9c)
(dump_stack) from [<c0239b90>] (__schedule_bug+0x5c/0x80)
(__schedule_bug) from [<c05b7260>] (__schedule+0x50/0x3f4)
(__schedule) from [<c05b76a8>] (schedule+0xa4/0xd4)
(schedule) from [<c05ba430>] (schedule_hrtimeout_range_clock+0xc8/0x100)
(schedule_hrtimeout_range_clock) from [<c05ba480>]
       (schedule_hrtimeout_range+0x18/0x20)
(schedule_hrtimeout_range) from [<c05b9f78>] (usleep_range+0x48/0x50)
(usleep_range) from [<c03f333c>] (__clk_hfpll_enable+0x44/0xd0)
(__clk_hfpll_enable) from [<c03f3474>] (clk_hfpll_set_rate+0xac/0xc4)
(clk_hfpll_set_rate) from [<c03ec390>] (clk_change_rate+0xf4/0x1fc)
(clk_change_rate) from [<c03ec510>] (clk_core_set_rate_nolock+0x78/0x94)
(clk_core_set_rate_nolock) from [<c03ec54c>] (clk_set_rate+0x20/0x30)
(clk_set_rate) from [<c0424168>] (dev_pm_opp_set_rate+0x190/0x26c)
(dev_pm_opp_set_rate) from [<c04a8548>] (set_target+0x40/0x108)
(set_target) from [<c04a4.140>] (__cpufreq_driver_target+0x3f4/0x488)
(__cpufreq_driver_target) from [<c04a7494>] (od_dbs_timer+0xcc/0x154)
(od_dbs_timer) from [<c04a7998>] (dbs_work_handler+0x2c/0x54)
(dbs_work_handler) from [<c02309e8>] (process_one_work+0x1c0/0x2f0)
(process_one_work) from [<c02319a8>] (worker_thread+0x2a4/0x404)
(worker_thread) from [<c0235944>] (kthread+0xd8/0xe8)
(kthread) from [<c020eef0>] (ret_from_fork+0x14/0x24)

Signed-off-by: Marc Benoit <marcb62185@gmail.com>
[slh: rebase for kernel v4.14 as well]
Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: define KERNEL_SIZE in KB instead of byte for the image generation
Stefan Lippers-Hollmann [Fri, 18 May 2018 02:23:01 +0000 (04:23 +0200)]
ipq806x: define KERNEL_SIZE in KB instead of byte for the image generation

Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: increase kernel partition size for the Netgear Nighthawk X4 R7500v2
Stefan Lippers-Hollmann [Fri, 18 May 2018 02:18:17 +0000 (04:18 +0200)]
ipq806x: increase kernel partition size for the Netgear Nighthawk X4 R7500v2

Starting with kernel 4.14 and gcc 7, the kernel doesn't fit into the
2 MB reserved for the kernel partition by the OEM firmware anymore.

This patch increases the kernel partition from 2 MB to 4 MB, at the
expense of the rootfs, for all supported kernels.

WARNING: This breaks sysupgrade! Flashing a firmware containing this
changed partitioning from an older image with 2 MB reserved for the
kernel partion requires the tftp recovery procedure, thereby losing
all settings.

This change follows the functional example of the Netgear r7800, but
has not been runtime tested on a Netgear Nighthawk X4 R7500v2.

Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: increase kernel partition size for the Netgear Nighthawk X4 R7500
Stefan Lippers-Hollmann [Fri, 18 May 2018 02:12:04 +0000 (04:12 +0200)]
ipq806x: increase kernel partition size for the Netgear Nighthawk X4 R7500

Starting with kernel 4.14 and gcc 7, the kernel doesn't fit into the
2 MB reserved for the kernel partition by the OEM firmware anymore.

This patch increases the kernel partition from 2 MB to 4 MB, at the
expense of the rootfs, for all supported kernels.

WARNING: This breaks sysupgrade! Flashing a firmware containing this
changed partitioning from an older image with 2 MB reserved for the
kernel partion requires the tftp recovery procedure, thereby losing
all settings.

This change follows the functional example of the Netgear r7800, but
has not been runtime tested on a Netgear Nighthawk X4 R7500

Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
Cc: Jonas Gorski <jonas.gorski@gmail.com>
6 years agoipq806x: increase kernel partition size for the Netgear Nighthawk X4 D7800
Stefan Lippers-Hollmann [Fri, 18 May 2018 01:49:27 +0000 (03:49 +0200)]
ipq806x: increase kernel partition size for the Netgear Nighthawk X4 D7800

Starting with kernel 4.14 and gcc 7, the kernel doesn't fit into the
2 MB reserved for the kernel partition by the OEM firmware anymore.

This patch increases the kernel partition from 2 MB to 4 MB, at the
expense of the rootfs, for all supported kernels.

WARNING: This breaks sysupgrade! Flashing a firmware containing this
changed partitioning from an older image with 2 MB reserved for the
kernel partion requires the tftp recovery procedure, thereby losing
all settings.

This change follows the functional example of the Netgear r7800, but
has not been runtime tested on a Netgear Nighthawk X4 D7800.

Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
Cc: Tathagata Das <tathagata@alumnux.com>
6 years agoipq806x: increase kernel partition size for the TP-Link Archer VR2600v
Stefan Lippers-Hollmann [Fri, 18 May 2018 01:34:44 +0000 (03:34 +0200)]
ipq806x: increase kernel partition size for the TP-Link Archer VR2600v

The default image does not fit 2 MB anymore, expand kernel partition
to 3 MB.

Upgrading should work transparently via sysupgrade in both directions.
Another option would be to merge "kernel" and "rootfs" into a single
"firmware" partition using MTD_SPLIT_TPLINK_FW, but just changing the
sizes of the existing partitioning has been deemed safer in the absence
of an actual runtime test on an affected device; the maximum for rootfs
changes from 10.4 MB to 9.4 MB.

This change follows the example for the TP-Link Archer C2600, but has
not been runtime tested on a TP-Link Archer VR2600v.

Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
Cc: Sebastian Quilitz <zeraphim@x-pantion.de>
6 years agoipq806x: increase kernel partition size for the TP-Link Archer C2600
Stefan Lippers-Hollmann [Fri, 18 May 2018 01:10:18 +0000 (03:10 +0200)]
ipq806x: increase kernel partition size for the TP-Link Archer C2600

The default image does not fit 2 MB anymore, expand os-image partition
to 4 MB.

Upgrading works transparently via sysupgrade in both directions.
Another option would have been to merge "os-image" and "rootfs" into a
single "firmware" partition using MTD_SPLIT_TPLINK_FW, but just
changing the sizes of the existing partitioning has been deemed safer
and actually tested on an affected device; the maximum for rootfs
changes from 27 MB to 25 MB.

Run-tested on TP-Link Archer C2600.

Signed-off-by: Joris de Vries <joris@apptrician.nl>
[slh: extend comments and commit message, rename rootfs]
Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: increase kernel partition size for the Netgear r7800
Stefan Lippers-Hollmann [Fri, 18 May 2018 01:00:41 +0000 (03:00 +0200)]
ipq806x: increase kernel partition size for the Netgear r7800

Starting with kernel 4.14 and gcc 7, the kernel doesn't fit into the
2 MB reserved for the kernel partition by the OEM firmware anymore.

This patch increases the kernel partition from 2 MB to 4 MB, at the
expense of the rootfs, for all supported kernels.

WARNING: This breaks sysupgrade! Flashing a firmware containing this
changed partitioning from an older image with 2 MB reserved for the
kernel partion requires the tftp recovery procedure, thereby losing
all settings.

This patch is based on a corresponding change by Pavel Kubelun
<be.dissent@gmail.com> and has been tested by Michael Yartys
<michael.yartys@protonmail.com>

Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: cleanup kernel config
Ram Chandra Jangir [Thu, 17 May 2018 12:55:29 +0000 (18:25 +0530)]
ipq806x: cleanup kernel config

Disable MSM8960, MSM8974 and APQ8084
 - since these are different SoC's than IPQ806x
Removed unrequired serial configs
 - since ipq806x uses SERIAL_MSM only

Signed-off-by: Ram Chandra Jangir <rjangir@codeaurora.org>
Tested-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq806x: add kernel 4.14 support
Ram Chandra Jangir [Fri, 4 May 2018 16:27:33 +0000 (21:57 +0530)]
ipq806x: add kernel 4.14 support

 - Rebased the patches for 4.14
 - Dropped spi-qup and 0027, 0028, 0029
   clk patches since it's already included
   in upstream.

 Tested on IPQ AP148 Board:
  1) NOR boot and NAND boot
  2) Tested USB and PCIe interfaces
  3) WDOG test
  4) cpu frequency scaling
  5) ethernet, 2G and 5G WiFi
  6) ubi sysupgrade

Signed-off-by: Ram Chandra Jangir <rjangir@codeaurora.org>
Tested-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
6 years agoipq40xx: add eva-image for FRITZ!Box 4040
David Bauer [Tue, 15 May 2018 23:57:16 +0000 (01:57 +0200)]
ipq40xx: add eva-image for FRITZ!Box 4040

This commit adds an EVA flashable image for the FRITZ!Box 4040.

The image contains the U-Boot with OpenWRT appended to it. This way we
remove the need to use UART for initial flashing.

Signed-off-by: David Bauer <mail@david-bauer.net>
6 years agobuild: add apend-uboot command
David Bauer [Tue, 15 May 2018 17:02:48 +0000 (19:02 +0200)]
build: add apend-uboot command

This commit adds an append-uboot command to append U-Boot from the
bin-directory.

Signed-off-by: David Bauer <mail@david-bauer.net>
6 years agoramips: change wifi led trigger for Archer C50v3
David Bauer [Fri, 18 May 2018 21:37:49 +0000 (23:37 +0200)]
ramips: change wifi led trigger for Archer C50v3

This commit alters the TP-Link Archer C50v3 LED settings to use the phy
trigger instead of the netdev one. This way the WiFi status is displayed
even if the wifi interface name is altered.

Signed-off-by: David Bauer <mail@david-bauer.net>
6 years agoramips: fix Archer C50v3 LED mapping
David Bauer [Fri, 18 May 2018 15:48:31 +0000 (17:48 +0200)]
ramips: fix Archer C50v3 LED mapping

This commit fixes the wrong LED mapping of the Archer C50 v3.
Commit was tested with an EU device.

Signed-off-by: David Bauer <mail@david-bauer.net>
6 years agoath79: enable rtl8366rb phy
Lucian Cristian [Fri, 18 May 2018 12:54:04 +0000 (15:54 +0300)]
ath79: enable rtl8366rb phy

is needed for at least tplink wr1043nd-v1

Signed-off-by: Lucian Cristian <lucian.cristian@gmail.com>
6 years agoath79: fix loader-okli, lzma-loader
Lucian Cristian [Mon, 21 May 2018 23:24:02 +0000 (02:24 +0300)]
ath79: fix loader-okli, lzma-loader

booting will hang most of the times on tl-wr1043nd-v1 without a KERNEL_CMDLINE value
add anything as a placeholder as kernel command line is taken from DTS

Signed-off-by: Lucian Cristian <lucian.cristian@gmail.com>
6 years agobuild: prevent spurious package rebuilds under CONFIG_AUTOREMOVE
Jo-Philipp Wich [Tue, 22 May 2018 07:18:33 +0000 (09:18 +0200)]
build: prevent spurious package rebuilds under CONFIG_AUTOREMOVE

When CONFIG_AUTOREMOVE is enabled, the build system touches an additional
".autoremove" stamp file in the cleaned build directory.

Since the autoremove stamp file is touched after the compile process
completed, it ends up being the most recent file of the package build
directory, causing the timestamp.pl check of depends.mk to erroneously
declare the ".built" and ".prepared" stamp files as stale, triggering
a forced clean-build submake process.

Fix the problem by using the ".built" stamp file as modification time
reference when touching the ".autoremove" stamp file.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
6 years agoar71xx: Add support for PISEN TS-D084
Chuanhong Guo [Sun, 22 Apr 2018 10:29:36 +0000 (18:29 +0800)]
ar71xx: Add support for PISEN TS-D084

PISEN TS-D084 is an wireless router with a battery and integrated power supply based on Atheros AR9331.

Specification:

- 400/400/200 MHz (CPU/DDR/AHB)
- 64 MB of RAM (DDR2)
- 8 MB of FLASH (SPI NOR)
- 1x 10/100 Mbps Ethernet
- 1T1R 2.4 GHz (AR9331)
- 1x USB 2.0

Flash instruction:
The manufacturer are using exactly the same firmware header as TP-LINK TL-WR703N (including device ID!). Simply upload the factory firmware into WebUI and flashing is done.

Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
6 years agokernel: enable THIN_ARCHIVES by default
Sergey Ryazanov [Mon, 21 May 2018 09:12:37 +0000 (12:12 +0300)]
kernel: enable THIN_ARCHIVES by default

THIN_ARCHIVES option is enabled by default in the kernel configuration
and no one target config disables it. So enable it by default and remove
this symbol from target specific configs to keep them light.

Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
6 years agokernel: enable FUTEX_PI by default
Sergey Ryazanov [Mon, 21 May 2018 09:12:36 +0000 (12:12 +0300)]
kernel: enable FUTEX_PI by default

New FUTEX_PI configuration symbol enabled if FUTEX and RT_MUTEX symbols
are enabled. Both of these symbols are enabled by default in the
generic config, so enable FUTEX_PI by default too to keep platform
specific configs minimal.

Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
6 years agokernel: enable EXPORTFS by default
Sergey Ryazanov [Mon, 21 May 2018 09:12:35 +0000 (12:12 +0300)]
kernel: enable EXPORTFS by default

OVERLAY_FS config symbol selects EXPORTFS since 4.12 kernel, we have
OVERLAY_FS enabled by default, so enable EXPORTFS in the generic config
of 4.14 and remove this option from platform specific configs.

Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
6 years agokernel: disable DRM_LIB_RANDOM by default
Sergey Ryazanov [Mon, 21 May 2018 09:12:34 +0000 (12:12 +0300)]
kernel: disable DRM_LIB_RANDOM by default

DRM_LIB_RANDOM config symbol selected only by DRM_DEBUG_MM_SELFTEST
which is disable by default, so disable DRM_LIB_RANDOM by default too.

Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
6 years agokernel: disable DMA_{NOOP|VIRT}_OPS by default
Sergey Ryazanov [Mon, 21 May 2018 09:12:33 +0000 (12:12 +0300)]
kernel: disable DMA_{NOOP|VIRT}_OPS by default

These options do not used by any supported arch, so disable them by
default to make arch configs a bit more clean.

Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
6 years agokernel: disable ARCH_WANTS_THP_SWAP by default
Sergey Ryazanov [Mon, 21 May 2018 09:12:32 +0000 (12:12 +0300)]
kernel: disable ARCH_WANTS_THP_SWAP by default

Only one arch (x86_64) enables this option. So disable
ARCH_WANTS_THP_SWAP by default and remove referencies to it from all
configs (except x86_64) to make them clean.

Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
6 years agoarc770: remove source-only
Evgeniy Didin [Mon, 21 May 2018 13:55:30 +0000 (16:55 +0300)]
arc770: remove source-only

In commit 8b9cdebc9c53 ("arc770: mark as source-only") arc770 was marked
as source-only because of iproute2 compile issues.
With uClibc-ng version 1.0.30 issues with iproute2 were fixed.
Lets remove "source-only" for arc770 as soon as uClibc-ng version
will be updated to 1.0.30. Patch for uClibc-ng is here:
https://patchwork.ozlabs.org/patch/917547/

Signed-off-by: Evgeniy Didin <Evgeniy.Didin@synopsys.com>
Cc: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Hauke Mehrtens <hauke@hauke-m.de>
Cc: John Crispin <john@phrozen.org>
6 years agouClibc-ng: update to 1.0.30
Evgeniy Didin [Mon, 21 May 2018 10:50:33 +0000 (13:50 +0300)]
uClibc-ng: update to 1.0.30

uClibc-ng 1.0.28 does not provide PF_VSOCK/AF_VSOCK definitions,
which causes iproute2 v4.16.0 compile errors.
In commit 57f2f80383b5 ("bits/socket.h: add missing defines")
necessary defines were included and iproute2 builds fine.
This commit now is part of uClibc-ng 1.0.30.
Lets update uClibc-ng to latest 1.0.30 version.

Signed-off-by: Evgeniy Didin <Evgeniy.Didin@synopsys.com>
Cc: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Hauke Mehrtens <hauke@hauke-m.de>
Cc: John Crispin <john@phrozen.org>
6 years agoar71xx: Fix build for dap-1330-a1 board
Hauke Mehrtens [Mon, 21 May 2018 13:22:00 +0000 (15:22 +0200)]
ar71xx: Fix build for dap-1330-a1 board

Using a version number of 16 character causes a buffer overflow in the
version number overwriting the first bit of the signature in the
mkdapimg2 tool.
I am not sure if the version number should be null terminated or not.
This patch reduces the size of the version number by removing the number
of private commits from it.

This was the original version number which caused problems:
OpenWrt-r6727+10
Now it uses this version number:
OpenWrt-r6727

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
6 years agoath25: drop 4.9 kernel support
Sergey Ryazanov [Mon, 21 May 2018 09:19:31 +0000 (12:19 +0300)]
ath25: drop 4.9 kernel support

Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
6 years agoath25: switch to 4.14 kernel
Sergey Ryazanov [Mon, 21 May 2018 09:19:30 +0000 (12:19 +0300)]
ath25: switch to 4.14 kernel

Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
6 years agoath25: add kernel 4.14 support
Sergey Ryazanov [Mon, 21 May 2018 09:19:29 +0000 (12:19 +0300)]
ath25: add kernel 4.14 support

Copy and refresh patches and config from 4.9, no more work is need.

Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
6 years agokernel: merge kmod-fbcon with kmod-fb
Tomasz Maciej Nowak [Fri, 30 Mar 2018 22:12:03 +0000 (00:12 +0200)]
kernel: merge kmod-fbcon with kmod-fb

As of commit in kernel:
6104c37094 fbcon: Make fbcon a built-time depency for fbdev
framebuffer console is build in into framebuffer module and there's no
standalone fbcon module. Therefore drop the kmod-fbcon and enable
console in kmod-fb. The only targets which use these modules are imx6
and geode, both are on kernel 4.14 so no fallback for other kernels is
introduced.
Being at that this commit also fixes autoload of fbdev for x86.

Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
6 years agobuild: use busybox gzip compatible force option
Mathew McBride [Wed, 28 Mar 2018 02:34:52 +0000 (13:34 +1100)]
build: use busybox gzip compatible force option

commit 138c763 ("build: add --force option to gzip in Build/gzip")
added the --force flag to the gzip invocation.

Under environments with busybox gzip (e.g Alpine Linux), this fails
as busybox only recognizes "-f".

Signed-off-by: Mathew McBride <matt@traverse.com.au>
6 years agonftables: bump to 0.8.5 version
Rosy Song [Tue, 15 May 2018 03:42:29 +0000 (11:42 +0800)]
nftables: bump to 0.8.5 version

Signed-off-by: Rosy Song <rosysong@rosinson.com>
6 years agolibnftnl: bump to 1.1.0
Rosy Song [Tue, 15 May 2018 02:41:19 +0000 (10:41 +0800)]
libnftnl: bump to 1.1.0

Signed-off-by: Rosy Song <rosysong@rosinson.com>
6 years agomvebu: initial support for Marvell Armada 7k and 8k DB boards
Damir Samardzic [Mon, 7 May 2018 07:25:53 +0000 (09:25 +0200)]
mvebu: initial support for Marvell Armada 7k and 8k DB boards

Add initial support for cortex-a72 based Armada DB-88F8040-Modular and
DB-88F7040-Modular development boards.

DB-88F8040-Modular specifications:
- Quad-core ARMv8 Cortex A72 CPU (up to 2 GHz)
- DDR4 DIMM - 64 bits + ECC
- 2 x 128 Mb SPI NOR flash memory
- 2 x 1G Ethernet port via RGMII (RJ45)
- 2 x SD card ports (4 bit port on CP, 8 bit port on AP)
- 2 SERDES modules with the following interfaces each:
  - 2 x SATA Rev 3.0 port (Port1 via SERDES module CON4 (active port), Port0
    via SERDES Module CON2 or CON1 (optional port))
  - 3 x PCI Express (PCIe) Gen 3.0 (Port2 via SERDES module CON5 (active port),
    Port1 via SERDES module CON7 (optional port), Port0 via SERDES module CON6
    (optional port))
  - 2 x USB3 (USB 2.0 backward compatible) host (via SERDES module CON9 and
    CON10)
  - 1 x 10G port over SFP+ connector (via SERDES module CON8)
- 1 x MCI interface by two over USB Type C connector
- 4 x serial COM port driven by the 88F8040 UART interface and converted to
  USB via FTDI IC
- I2C Master Interface
  - CP I2C 2x EEPROM @ Address 0x50 and 0x57
  - 1 x I/O Expander @ Address 0x21
  - Sample at Reset (SatR) memory device @ Address 0x4C and 0x4E
- I2C Slave Interface (via SERDES module) - Connection to each device on the
  board via an I2C multiplexer
- JTAG interface for CPU emulator
- Board dimensions: 270 mm x 240 mm (main + SERDES module)
- SERDES Module Dimensions: 70 mm x 105 mm

DB-88F7040-Modular specifications:
- Quad-core ARMv8 Cortex A72 CPU
  - CPU core operating speed of up to 1.6 GHz for Dual Core, 1.4 GHz for Quad
    Core
- DDR4 - 32 bit + ECC on Module - SLM1366-V1 (DB-DDR4-40B-MODULE) 4 GByte
  32-bit
- 1 x 128Mb SPI NOR flash memory
- 2 x 1G Ethernet port: 1 over RGMII (RJ45) and 1 over SGMII
- SD card 4 bits port on AP
- eMMc Module on CP
- 1 SERDES Modules with the following interfaces each:
  - 1 x SATA Rev 3.0 port (via SERDES module CON4)
  - 1 x PCI Express (PCIe) Gen 3.0 (via SERDES module CON5)
  - 2 x USB 3.0 (USB 2.0 backward compatible) host (via SERDES module CON9 and
    CON10)
  - 1 x 10G port over SFP+ connector (via SERDES module CON8)
- 2 x MCi interface by one over USB Type C connector
- 4 x Serial COM port driven by the 88F7040 UA
- RT interface and converted to USB via FTDI IC
- I2C Master Interface
  - 2 x EEPROM at address 0x57 and 0x50 in AP and 2 x EEPROM at address 0x57
    and 0x50 in CP
  - 1 x I/O Expander at address 0x21
  - Sample at Reset (SatR) memory device at address 0x4C and 0x4E
- I2C Slave Interface (via SERDES module) - Connection to each device on the
  board via an I2C multiplexer
- JTAG interface for CPU emulator
- Board dimensions - 270 mm x 240 mm (main + SERDES module)
- SERDES Module Dimensions - 70 mm x 105 mm

Booting from USB flash drive (dd sdcard image to the flash drive):
 1. reset U-Boot environment:
      env default -a
      saveenv

 2. prepare U-Boot manually (make sure to set correct dtb file name):
      setenv bootargs_root 'root=/dev/sda2 rw rootdelay=2 ip=dhcp'
      setenv fdtfile armada-7040-db.dtb
      setenv image_name Image
      setenv bootcmd 'usb start; ext4load usb 0:1 $kernel_addr $image_name; ext4load usb 0:1 $fdt_addr $fdtfile; setenv bootargs $console $mtdparts $bootargs_root; booti $kernel_addr - $fdt_addr'
      saveenv
      boot

Signed-off-by: Damir Samardzic <damir.samardzic@sartura.hr>
6 years agomvebu: initial support for Marvell Armada 3720 DB board
Damir Samardzic [Tue, 8 May 2018 11:32:21 +0000 (13:32 +0200)]
mvebu: initial support for Marvell Armada 3720 DB board

Add initial support for Marvell Armada cortex-a53 based
DB-88F3720-DDR3-Modular development board.

Specifications:
- Dual core ARMv8 Cortex-A53 CPU (up to 1.0 GHz)
- 4Gb 16-bit DDR3/3L DRAM memory
- 128Mb SPI NOR flash memory
- 8Gb eMMC NAND flash memory
- 1 x SATA Rev 3.0 port
- 1 x PCI Express (PCIe) Gen 2.0 or 1 x mini PCI Express (PCIe) Gen 2.0
- 1 x 1G Ethernet port via RGMII (RJ45)
- 1 x SD card port
- 1 x USB3 (USB2 backward) host\device port via type C connector
- 1 x USB2 host port via type A connector
- 1 x serial COM port driven by the 88F3720 UART interface and converted to
  USB via FTDI IC (option to connect the UART DB9 adapter)
- I2C Master Interface:
  - 1 x EEPROM @ address 0x57
  - 1 x I/O Expanders @ address 0x22
  - Sample at Reset (SatR) memory device @ address 0x4C
  - RTC clock generator PT7C4337AWE @ address 0x68
  - USB3 switch PI5USB30213XEA @ address 0x0D
  - ID component of PHY module @ address 0x24
- 1 x JTAG interface for CPU emulator
- 1 x SETM and JTAG debug interface
- 1 x power connector for HDD supply
- 1 x 12V DC jack power connector
- Board dimensions: 150 mm x 179 mm
- LED interface for system status

Booting from SD card:
 1. reset U-Boot environment:
      env default -a
      saveenv

 2. prepare U-Boot with boot script:
      setenv bootcmd "load mmc 0:1 0x4d00000 boot.scr; source 0x4d00000"
      saveenv

    or manually:
      setenv fdt_name armada-3720-db.dtb
      setenv image_name Image
      setenv bootcmd 'mmc dev 0; ext4load mmc 0:1 $kernel_addr $image_name;ext4load mmc 0:1 $fdt_addr $fdt_name;setenv bootargs $console root=/dev/mmcblk1p2 rw rootwait; booti $kernel_addr - $fdt_addr'
      saveenv

Signed-off-by: Damir Samardzic <damir.samardzic@sartura.hr>
6 years agokernel: Add support spi-nor, Eon EN25QH32
YuheiOKAWA [Wed, 16 May 2018 10:54:26 +0000 (19:54 +0900)]
kernel: Add support spi-nor, Eon EN25QH32

Support Add spi-nor chip EN25QH32. JEDEC is 1c7016.

Can't boot issue, new revision hardware is EN25QH32 flash chip.
example, MZK-DP150N (ramips).
https://bugs.openwrt.org/index.php?do=details&task_id=1534

Signed-off-by: YuheiOKAWA <tochiro.srchack@gmail.com>
6 years agokernel: Add configfs support for USB HID gadget
Harvey Phillips [Sat, 19 May 2018 19:34:05 +0000 (20:34 +0100)]
kernel: Add configfs support for USB HID gadget

Added a rule to usb.mk to build usb_f_hid.ko for configfs support
Tested on a Raspberry Pi Zero W

Signed-off-by: Harvey Phillips <xcellerator@gmx.com>
6 years agoath10k-firmware: Fix mirror hash sum
Hauke Mehrtens [Sat, 19 May 2018 13:20:46 +0000 (15:20 +0200)]
ath10k-firmware: Fix mirror hash sum

This now matches what was generated locally on my PC and the file on the
mirror server.

Fixes: 349fe46103359 ("ath10k-firmware: Update QCA988X firmware to the latest version")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
6 years agoopenwrt-keyring: bundle latest usign certificates
Jo-Philipp Wich [Sun, 20 May 2018 17:37:58 +0000 (19:37 +0200)]
openwrt-keyring: bundle latest usign certificates

Includes the public usign certificates used by the 18.06.* release builds.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
6 years agobase-files: depend on openwrt-keyring
Jo-Philipp Wich [Sun, 20 May 2018 17:34:36 +0000 (19:34 +0200)]
base-files: depend on openwrt-keyring

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
6 years agoopenwrt-keyring: rename from lede-keyring
Jo-Philipp Wich [Sun, 20 May 2018 17:32:29 +0000 (19:32 +0200)]
openwrt-keyring: rename from lede-keyring

Also let the new openwrt-keyring package provide lede-keyring for backwards
compatibility.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
6 years agowireguard: bump to 20180519
Jason A. Donenfeld [Sat, 19 May 2018 03:55:58 +0000 (05:55 +0200)]
wireguard: bump to 20180519

* chacha20poly1305: add mips32 implementation

"The OpenWRT Commit" - this significantly speeds up performance on cheap
plastic MIPS routers, and presumably the remaining MIPS32r2 super computers
out there.

* timers: reinitialize state on init
* timers: round up instead of down in slack_time
* timers: remove slack_time
* timers: clear send_keepalive timer on sending handshake response
* timers: no need to clear keepalive in persistent keepalive

Andrew He and I have helped simplify the timers and remove some old warts,
making the whole system a bit easier to analyze.

* tools: fix errno propagation and messages

Error messages are now more coherent.

* device: remove allowedips before individual peers

This avoids an O(n^2) traversal in favor of an O(n) one. Before systems with
many peers would grind when deleting the interface.

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
6 years agomt76: update to the latest version
Felix Fietkau [Fri, 18 May 2018 16:13:55 +0000 (18:13 +0200)]
mt76: update to the latest version

73edb22 mt76: discard early received packets if not running yet
0b8d1dd mt76: fix beacon timer drift

Signed-off-by: Felix Fietkau <nbd@nbd.name>
6 years agokernel: whitespace fixes
John Crispin [Fri, 18 May 2018 09:09:06 +0000 (11:09 +0200)]
kernel: whitespace fixes

Signed-off-by: John Crispin <john@phrozen.org>
6 years agox86: disable CONFIG_EFI_VARS
Alif M. Ahmad [Tue, 27 Feb 2018 02:01:04 +0000 (02:01 +0000)]
x86: disable CONFIG_EFI_VARS

Disable CONFIG_EFI_VARS, since it suffers from sysfs limitation (no
support for variable longer than 1024 bytes).

kmod-fs-efivarfs is the replacement of this, which enables mounting
efivarfs file system and doesn't suffer from 1024 bytes limitation.

Signed-off-by: Alif M. Ahmad <alive4ever@live.com>
6 years agohostapd: fix IEEE 802.11r (fast roaming) defaults
Gospod Nassa [Fri, 18 May 2018 08:39:33 +0000 (09:39 +0100)]
hostapd: fix IEEE 802.11r (fast roaming) defaults

Use ft_psk_generate_local=1 by default, as it makes everything else fairly
trivial. All of the r0kh/r1kh and key management stuff goes away and hostapd
fairly much does it all for us.

We do need to provide nas_identifier, which can be derived from the BSSID,
and we need to generate a mobility_domain, for which we default to the first
four chars of the md5sum of the SSID.

The complex manual setup should also still work, but the defaults also
now work easily out of the box. Verified by manually running hostapd
(with the autogenerated config) and watching the debug output:

wlan2: STA ac:37:43:a0:a6:ae WPA: FT authentication already completed - do not start 4-way handshake

 This was previous submitted to LEDE in
 https://github.com/lede-project/source/pull/1382

[dwmw2: Rewrote commit message]
Signed-off-by: Gospod Nassa <devianca@gmail.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
6 years agoiwinfo: bump to latest git HEAD
John Crispin [Fri, 18 May 2018 07:37:53 +0000 (09:37 +0200)]
iwinfo: bump to latest git HEAD

e59f925 hardware: add device ids for QCA9984, 88W8887 and 88W8964 radios
2a82f87 nl80211: back out early when receiving FAIL-BUSY reply
77c32f0 nl80211: fix code calculating average signal and rate

Signed-off-by: John Crispin <john@phrozen.org>
6 years agowireguard: no longer need portability patch
Kevin Darbyshire-Bryant [Thu, 17 May 2018 22:08:21 +0000 (23:08 +0100)]
wireguard: no longer need portability patch

Drop package/network/services/wireguard/patches/100-portability.patch

Instead pass 'PLATFORM=linux' to make since we are always building FOR
linux.

Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
6 years agoramips: add support for YUKAI Engineering Inc. BOCCO
YuheiOKAWA [Thu, 22 Feb 2018 16:58:23 +0000 (01:58 +0900)]
ramips: add support for YUKAI Engineering Inc. BOCCO

BOCCO is a communication robot provided by YUKAI Engineering Inc.

SoC: MT7620A
MEM: 256MB
Flash: 8MB
NAND: 512MB (non support)
Include Sound DAC and AMP.
No Wired Ethernet.

Signed-off-by: YuheiOKAWA <tochiro.srchack@gmail.com>
6 years agoar71xx: WNDR3700: enable RFKILL function for Wifi button
Michal Cieslakiewicz [Thu, 22 Feb 2018 22:11:08 +0000 (23:11 +0100)]
ar71xx: WNDR3700: enable RFKILL function for Wifi button

Wifi button for WNDR3700 dual band routers has been renamed to "rfkill"
and its emitted keycode changed to KEY_RFKILL. This allows OpenWrt/LEDE
to support it 'out of the box' without additional tweaking.

Until this patch, button had been sending BTN_2 keycode which was
ignored by default (no action script present). To get expected behaviour
of switching radios on and off, user had to manually rename/link
'rfkill' script to name 'BTN_2' in /etc/rc.button directory.

This patch follows similar changes for other Netgear ar71xx routers,
for example WNR2000v3. It applies cleanly to both latest trunk and 17.01
branch. Tested on WNDR3700v1.

Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
6 years agobrcm2708: add squashfs rootfs image
Christian Lamparter [Tue, 27 Mar 2018 17:42:18 +0000 (19:42 +0200)]
brcm2708: add squashfs rootfs image

This patch adds a image with squashfs as the root filesystem.
A rootfs_data partition will be generated on the first boot
and placed inside the rootfs partition (just after the squashfs
image).

advantages:
 - it is possible to migrate from an existing -ext4
   installation and back via sysupgrade.
 - existing partition layout will not be lost.
 - slightly smaller image size.
 - support for attendedsysupgrade

disadvantages:
 - needs f2fs + tools as well. This is because fs-tools decides on the
   blocksize of the sdcard. So either f2fs or ext4 can get choosen as
   the rootfs_data filesystem (depends on the size of the root partition).
 - rootfs_data is placed into the rootfs partition. This makes
   it difficult for tools that expect a /dev/mmc0pX device.
   It also makes it difficult for data recovery tools since they
   might not expect to find a embedded partition or will be
   confused.

For people with existing build configurations: make sure to include mkf2fs
and f2fsck package into the image... Otherwise the new -squashfs image will
boot of a ram-overlay and won't keep the configurations after a reboot.

Cc: Álvaro Fernández Rojas <noltari@gmail.com>
Cc: Paul Spooren <spooren@informatik.uni-leipzig.de>
Cc: Daniel Golle <daniel@makrotopia.org>
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
Acked-by: Daniel Golle <daniel@makrotopia.org>
6 years agox86: Add APU3 reference to x86 board.d
Kristian Evensen [Thu, 15 Mar 2018 12:30:27 +0000 (13:30 +0100)]
x86: Add APU3 reference to x86 board.d

There is a new APU-model available, APU3. The device is configured in
the same way as the APU1 and APU2, so the same LED/network setup can be
used.

I considered changing the case to pc-engines-apu*, but I chose to follow
the existing pattern and add the full board name.

Signed-off-by: Kristian Evensen <kristian.evensen@gmail.com>