openwrt/staging/wigyori.git
5 years agoramips: fix multi colour led handling
Mathias Kresin [Sat, 18 Aug 2018 10:22:25 +0000 (12:22 +0200)]
ramips: fix multi colour led handling

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>
5 years agoramips: rt-n12p: use the boardname helper variable
Mathias Kresin [Wed, 29 Aug 2018 06:59:46 +0000 (08:59 +0200)]
ramips: rt-n12p: use the boardname helper variable

Use the helper variable for the Asus RT-N12P as it is done by all
boards.

Signed-off-by: Mathias Kresin <dev@kresin.me>
5 years agocomgt: increase timeout on runcommands
Giuseppe Lippolis [Sun, 26 Aug 2018 08:52:27 +0000 (10:52 +0200)]
comgt: increase timeout on runcommands

Some combination of modem/wireless operator requires more time to
execute the commands.
Tested on DWR-512 embedded wwan modem and italian operator iliad (new
virtual operator).

Signed-off-by: Giuseppe Lippolis <giu.lippolis@gmail.com>
5 years agobase-files: provide more tolerant xterm detection
Paul Wassi [Thu, 23 Aug 2018 07:24:43 +0000 (09:24 +0200)]
base-files: provide more tolerant xterm detection

Set the window title not only in "xterm", but also in
e.g. "xterm-256color", "xterm-color", etc.
The case statement is taken from Debian / Ubuntu.

Signed-off-by: Paul Wassi <p.wassi@gmx.at>
5 years agougps: Update to fix position calculation
Bruno Randolf [Fri, 24 Aug 2018 15:59:08 +0000 (16:59 +0100)]
ugps: Update to fix position calculation

This is necessary to get my position right.
Without this my longitude is incorrecty -15.85xxxx instead of -16.52yyyy

Signed-off-by: Bruno Randolf <br1@einfach.org>
5 years agougps: Add option disabled
Bruno Randolf [Thu, 23 Aug 2018 20:59:58 +0000 (21:59 +0100)]
ugps: Add option disabled

Like many other packages, an option to disable can be practical.

Signed-off-by: Bruno Randolf <br1@einfach.org>
5 years agokernel: bump 4.14 to 4.14.67
Koen Vandeputte [Tue, 28 Aug 2018 14:10:40 +0000 (16:10 +0200)]
kernel: bump 4.14 to 4.14.67

Refreshed all patches.

Removed upstreamed patches:
- 037-v4.18-0008-ARM-dts-BCM5301x-Fix-i2c-controller-interrupt-type.patch

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

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
5 years agokernel: bump 4.9 to 4.9.124
Koen Vandeputte [Tue, 28 Aug 2018 14:09:37 +0000 (16:09 +0200)]
kernel: bump 4.9 to 4.9.124

Refreshed all patches.

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

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
5 years agomediatek: remove duplicate RPS patch
Koen Vandeputte [Tue, 28 Aug 2018 11:28:45 +0000 (13:28 +0200)]
mediatek: remove duplicate RPS patch

Commit 7af1fb9faafb ("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 7762c07c8898 ("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: 7af1fb9faafb ("kernel: add a RPS balancer")
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
5 years agoethtool: Update to 4.18
Robert Marko [Sat, 25 Aug 2018 21:26:24 +0000 (23:26 +0200)]
ethtool: Update to 4.18

Tested on 8devices Jalapeno(ipq40xx)
Introduces following changes:
Feature: Add support for WAKE_FILTER (WoL using filters)
Feature: Add support for action value -2 (wake-up filter)
Fix: document WoL filters option also in help message
Feature: ixgbe dump strings for security registers

Signed-off-by: Robert Marko <robimarko@gmail.com>
5 years agoath79: fix remove irq code from pci driver patch
John Crispin [Tue, 28 Aug 2018 09:58:50 +0000 (11:58 +0200)]
ath79: fix remove irq code from pci driver patch

This patch got mangled in the void while rebasing it.

Signed-off-by: John Crispin <john@phrozen.org>
5 years agogeneric: add flow_offload accounting
John Crispin [Mon, 13 Aug 2018 15:00:14 +0000 (17:00 +0200)]
generic: add flow_offload accounting

This patch makes the flow offloading layer account for the traffic inside
the conntack entries.

Signed-off-by: John Crispin <john@phrozen.org>
5 years agokernel: add a RPS balancer
John Crispin [Mon, 13 Aug 2018 14:24:17 +0000 (16:24 +0200)]
kernel: add a RPS balancer

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>
5 years agobuild: add mkrasimage
David Bauer [Wed, 22 Aug 2018 15:30:44 +0000 (17:30 +0200)]
build: add mkrasimage

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>
5 years agoath79: fix ar7100 PCI IRQ handling
Dmitry Tunin [Fri, 24 Aug 2018 08:56:57 +0000 (11:56 +0300)]
ath79: fix ar7100 PCI IRQ handling

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>
5 years agoath79: ag71xx: apply interface mode to MII0/1_CTRL on ar71xx/ar913x
Chuanhong Guo [Tue, 21 Aug 2018 11:39:16 +0000 (19:39 +0800)]
ath79: ag71xx: apply interface mode to MII0/1_CTRL on ar71xx/ar913x

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>
5 years agoath79: replace patches
John Crispin [Wed, 22 Aug 2018 04:20:13 +0000 (06:20 +0200)]
ath79: replace patches

replace our downstream version of the patches with the ones
that were sent upstream.

Signed-off-by: John Crispin <john@phrozen.org>
5 years agostrace: update strace to version 4.24
Hauke Mehrtens [Sat, 25 Aug 2018 12:32:08 +0000 (14:32 +0200)]
strace: update strace to version 4.24

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
5 years agoar71xx: WNR612v2: fix kernel panic due to wrong Wifi LED init
Michal Cieslakiewicz [Mon, 27 Aug 2018 18:24:04 +0000 (20:24 +0200)]
ar71xx: WNR612v2: fix kernel panic due to wrong Wifi LED init

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: 1f5ea4eae46e ("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>
5 years agoar71xx/generic: enable Zyxel NBG6616 in kernel config again
Matthias Schiffer [Mon, 27 Aug 2018 18:25:01 +0000 (20:25 +0200)]
ar71xx/generic: enable Zyxel NBG6616 in kernel config again

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: 0cd5e85e7ad6 ("ar71xx: create new ar71xx/tiny subtarget for 4MB flash devices")
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
5 years agoath79: initial support for Ubiquiti RouterStation and RouterStation Pro
Matt Merhar [Mon, 27 Aug 2018 13:59:09 +0000 (09:59 -0400)]
ath79: initial support for Ubiquiti RouterStation and RouterStation Pro

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 3e9d9f62258f80298710441e0db557e59e152dcf "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>
5 years agotreewide: fix some cosmetic glitches in dts files
Paul Wassi [Thu, 23 Aug 2018 07:35:04 +0000 (09:35 +0200)]
treewide: fix some cosmetic glitches in dts files

- 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>
5 years agoramips: fix mt7620 pinmux for second SPI
Mathias Kresin [Wed, 22 Aug 2018 05:30:36 +0000 (07:30 +0200)]
ramips: fix mt7620 pinmux for second SPI

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>
5 years agolinux-firmware: realtek: Add FW for rtl8192eu, rtl8723au and rtl8723bu
Hauke Mehrtens [Mon, 27 Aug 2018 16:10:14 +0000 (18:10 +0200)]
linux-firmware: realtek: Add FW for rtl8192eu, rtl8723au and rtl8723bu

These devices are more or less supported by the kmod-rtl8xxxu driver.

Fixes: FS#1789
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
5 years agoscripts: bundle-libraries: prevent loading host locales (FS#1803)
Jo-Philipp Wich [Sat, 25 Aug 2018 12:46:57 +0000 (14:46 +0200)]
scripts: bundle-libraries: prevent loading host locales (FS#1803)

Binary patch the bundled glibc library to inhibit loading of host locale
archives in order to avoid triggering internal libc assertions when
invoking shipped, bundled executables.

The problem has been solved with upstream Glibc commit
0062ace229 ("Gracefully handle incompatible locale data") but we still
need to deal with older Glibc binaries for some time to come.

Fixes FS#1803
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
5 years agonghttp2: bump to 1.32.1
Hans Dedecker [Mon, 27 Aug 2018 08:02:10 +0000 (10:02 +0200)]
nghttp2: bump to 1.32.1

4c76aaee Update manual pages
2b51ad67 Bump up version number to 1.32.1, LT revision to 30:3:16
708379dc Tweak nghttp2_session_set_stream_user_data
73106b0d Compile with clang-6.0

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
5 years agoath10k-firmware: update both QCA988X CT variants
Stijn Tintel [Sun, 26 Aug 2018 15:57:42 +0000 (17:57 +0200)]
ath10k-firmware: update both QCA988X CT variants

This fixes slow performance with 802.11w enabled.

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
5 years agoath10k-ct: bump to git HEAD
Stijn Tintel [Thu, 23 Aug 2018 13:46:23 +0000 (16:46 +0300)]
ath10k-ct: bump to git HEAD

e0d2ce0 ath10k:  Support setting tx_antenna in descriptor field.
29c644f Update to latest 4.13 and 4.16 ath10k-ct drivers.
20db9db ath10k:  Support vdev stats for 4.9, 4.16  kernel
fd92066 ath10k:  Support 'ct-sta-mode' for 9984 firmware that supports it.
34954f0 ath10k:  get_tsf, PMF

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
5 years agox86: geode: Add missing config options
Hauke Mehrtens [Sun, 26 Aug 2018 10:20:24 +0000 (12:20 +0200)]
x86: geode: Add missing config options

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>
5 years agoiproute2: update to 4.18.0
Hans Dedecker [Thu, 23 Aug 2018 19:58:14 +0000 (21:58 +0200)]
iproute2: update to 4.18.0

Update to the latest version of iproute2; see https://lwn.net/Articles/762515/
for a full overview of the changes in 4.18.
Remove upstream patch 001-rdma-sync-some-IP-headers-with-glibc

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
5 years agoath9k: fix setting up tx99 with a monitor mode interface
Felix Fietkau [Mon, 20 Aug 2018 09:40:48 +0000 (11:40 +0200)]
ath9k: fix setting up tx99 with a monitor mode interface

Signed-off-by: Felix Fietkau <nbd@nbd.name>
5 years agoath79: fix mac address increment for embedded wireless Dorin
Felix Fietkau [Mon, 20 Aug 2018 09:11:30 +0000 (11:11 +0200)]
ath79: fix mac address increment for embedded wireless Dorin

Use mtd-mac-address-increment-byte to match ar71xx behavior

Signed-off-by: Felix Fietkau <nbd@nbd.name>
5 years agokernel: make mtd mac address increment more flexible
Felix Fietkau [Mon, 20 Aug 2018 09:10:27 +0000 (11:10 +0200)]
kernel: make mtd mac address increment more flexible

Allow selecting the byte on which the increment should be added.

Signed-off-by: Felix Fietkau <nbd@nbd.name>
5 years agokernel: add missing dependency to regmap to kmod-gpio-mcp23s08
Hauke Mehrtens [Sat, 25 Aug 2018 16:11:03 +0000 (18:11 +0200)]
kernel: add missing dependency to regmap to kmod-gpio-mcp23s08

This fixes a build problem recently introduced.

Fixes: a904003b9b5f ("kernel: fix kmod-gpio-mcp23s08 for linux 4.14")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
5 years agobrcm47xx: Enable USB power on WNDR3400v3
Tuomas Tynkkynen [Sun, 19 Aug 2018 19:11:50 +0000 (22:11 +0300)]
brcm47xx: Enable USB power on WNDR3400v3

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>
5 years agokernel: add kmod-tcp-bbr
Keith Wong [Thu, 12 Apr 2018 03:21:08 +0000 (11:21 +0800)]
kernel: add kmod-tcp-bbr

This adds support for BBR (Bottleneck Bandwidth and RTT) TCP
congestion control. Applications (e.g. webservers, VPN client/server)
which initiate connections from router side can benefit from this.

This provide an easier way for users to use BBR by selecting /
installing kmod-tcp-bbr instead of altering kernel config and
compiling firmware by themselves.

Signed-off-by: Keith Wong <keithwky@gmail.com>
5 years agolibbsd: Update to 0.8.7
Daniel Engberg [Wed, 2 May 2018 08:23:45 +0000 (10:23 +0200)]
libbsd: Update to 0.8.7

Update libbsd to 0.8.7
Remove glibc dependency
Clean up InstallDev and install entries
Use /usr path for consistency
Cherry pick patches from upstream to fix musl compilation

Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
5 years agoimx6: Initial support for SolidRun CuBox-i devices based on i.MX6 processors (i1...
Vladimir Vid [Mon, 9 Jul 2018 09:09:53 +0000 (11:09 +0200)]
imx6: Initial support for SolidRun CuBox-i devices based on i.MX6 processors (i1, i2, i2eX, and i4Pro).

- 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>
5 years agomac80211: mwl8k: Expand non-DFS 5G channels
Antonio Silverio [Fri, 10 Aug 2018 10:05:14 +0000 (12:05 +0200)]
mac80211: mwl8k: Expand non-DFS 5G channels

Add non-DFS 5G upper channels (149-165) besides existed 4 lower channels
(36, 40, 44, 48).

Signed-off-by: Antonio Silverio <menion@gmail.com>
5 years agokernel: fix kmod-gpio-mcp23s08 for linux 4.14
Martin Schiller [Fri, 24 Aug 2018 09:35:35 +0000 (11:35 +0200)]
kernel: fix kmod-gpio-mcp23s08 for linux 4.14

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
5 years agox86/64: enable X86_INTEL_LPSS to select PINCTRL
Martin Schiller [Fri, 24 Aug 2018 09:31:13 +0000 (11:31 +0200)]
x86/64: enable X86_INTEL_LPSS to select PINCTRL

This makes it possible to use the MCP23S08 i/o expander
on x86_64 platforms with linux 4.14.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
5 years agox86/geode: enable X86_INTEL_LPSS to select PINCTRL
Martin Schiller [Fri, 24 Aug 2018 09:29:37 +0000 (11:29 +0200)]
x86/geode: enable X86_INTEL_LPSS to select PINCTRL

This makes it possible to use the MCP23S08 i/o expander
on geode platforms with linux 4.14.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
5 years agozynq: add support for the Zybo Z7 board
Luis Araneda [Fri, 24 Aug 2018 03:40:26 +0000 (00:40 -0300)]
zynq: add support for the Zybo Z7 board

The board is manufactured by Digilent
Main features:
- Soc: XC7Z010 (Z7-10) or XC7Z020 (Z7-20)
- RAM: 1 GB DDR3L
- FLASH: 16 MB QSPI
- 1 Gbps Ethernet
- USB 2.0
- microSD slot
- Pcam camera connector
- HDMI Tx and Rx
- Audio codec: stereo out, stereo in, mic
- 5 (Z7-10) or 6 (Z7-20) Pmod ports
- 6 push-buttons, 4 switches, 5 LEDs
- 1 (Z7-10) or 2 (Z7-20) RGB LEDs

Signed-off-by: Luis Araneda <luaraneda@gmail.com>
5 years agouboot-zynq: add support for the zybo z7 board
Luis Araneda [Fri, 24 Aug 2018 03:40:25 +0000 (00:40 -0300)]
uboot-zynq: add support for the zybo z7 board

Backport board support from the upcoming v2018.09 release,
and add an additional patch to read the MAC address
from flash memory

Signed-off-by: Luis Araneda <luaraneda@gmail.com>
5 years agox86: add UHCI and XHCI USB host drivers to 4.14
Alex Maclean [Thu, 23 Aug 2018 13:30:36 +0000 (14:30 +0100)]
x86: add UHCI and XHCI USB host drivers to 4.14

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>
5 years agolibevent2: Switch to using release tarball
Rosen Penev [Fri, 17 Aug 2018 20:31:48 +0000 (13:31 -0700)]
libevent2: Switch to using release tarball

Starting with version 2.1.8, a release tarball is available.

Simplifies the Makefile slightly.

Updated the project URL. HTTPS is broken. Issue has been reported upstream

Adjusted patches. CMake support is not present in the tarball. It's made
for Windows anyway.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
5 years agobuild: Unset CDPATH to avoid problems
Thomas Langer [Mon, 20 Aug 2018 10:13:29 +0000 (12:13 +0200)]
build: Unset CDPATH to avoid problems

In some places the output of commands, which include "cd" are used.
In case of CDPATH the new path is printed, which might not be expected.
Disable the variable to avoid these problem.

When CDPATH was set by the user to some value like "export CDPATH=."
the git checkout done by the build system did not work anymore, the
git cloning aborted with such an error message for example:
....
Packing checkout...
tar: /disk/fs1/tmp2/mehrtens/pon-ugw/ugw-haps/openwrt/tmp/dl/ppa-drv-1.0\n@1534240258: Cannot stat: No such file or directory
tar: Date sample file not found
Try 'tar --help' or 'tar --usage' for more information.
.....

To avoid this, this patch makes the build system unset CDPATH inside
the build system, so the build system will still work even when the
user set this variable in his local environment.

Signed-off-by: Thomas Langer <thomas.langer@intel.com>
Signed-off-by: Hauke Mehrtens <hauke.mehrtens@intel.com>
Acked-by: Hans Dedecker <dedeckeh@gmail.com>
5 years agomt76: update to the latest version
Felix Fietkau [Wed, 22 Aug 2018 10:31:55 +0000 (12:31 +0200)]
mt76: update to the latest version

7daf962 mt7603: add survey support
980c606 mt7603: add fix for CCA signal configuration
30b8371 mt7603: fix BAR rate

Signed-off-by: Felix Fietkau <nbd@nbd.name>
5 years agodropbear: backport upstream fix for CVE-2018-15599
Hans Dedecker [Fri, 24 Aug 2018 13:02:24 +0000 (15:02 +0200)]
dropbear: backport upstream fix for CVE-2018-15599

CVE description :
The recv_msg_userauth_request function in svr-auth.c in Dropbear through
2018.76 is prone to a user enumeration vulnerability because username
validity affects how fields in SSH_MSG_USERAUTH messages are handled,
a similar issue to CVE-2018-15473 in an unrelated codebase.

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
5 years agoramips: fix RBM11G partitioning
Thibaut VARÈNE [Sat, 4 Aug 2018 13:44:26 +0000 (15:44 +0200)]
ramips: fix RBM11G partitioning

This patch improves faf64056ddd46992a75b1e277d94541c7251035c by correcting
the partition scheme for the "RouterBoot" section of the flash.

The partition scheme initially submitted is incorrect and does not reflect
the actual flash structure.

The "RouterBoot" section (name matching OEM) is subdivided in several
static segments, as they are on ar71xx RB devices albeit with different
offsets and sizes.
The naming convention from ar71xx has been preserved, except for the
bootloaders which are named "bootloader1" and "bootloader2" to avoid
confusion with the master "RouterBoot" partition.
The preferred 'fixed-partitions' DTS node syntax is used, with nesting
support as introduced in 2a598bbaa3.
"partition" is used for node names, with associated "label" to match
policy set by 6dd94c2781.

Leave a note in DTS to explain how the original author selected the SPI speed.

Tested-by: Tobias Schramm <tobleminer@gmail.com>
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
Reviewed-by: Rafał Miłecki <rafal@milecki.pl>
5 years agoramips: fix RBM33G partitioning
Thibaut VARÈNE [Sat, 4 Aug 2018 13:44:25 +0000 (15:44 +0200)]
ramips: fix RBM33G partitioning

This patch improves 5684d087418d176cfdef4e045e1950ca7ba3b09f by correcting
the partition scheme for the "RouterBoot" section of the flash.

The partition scheme initially submitted is incorrect and does not reflect
the actual flash structure.

The "RouterBoot" section (name matching OEM) is subdivided in several
static segments, as they are on ar71xx RB devices albeit with different
offsets and sizes.
The naming convention from ar71xx has been preserved, except for the
bootloaders which are named "bootloader1" and "bootloader2" to avoid
confusion with the master "RouterBoot" partition.
The preferred 'fixed-partitions' DTS node syntax is used, with nesting
support as introduced in 2a598bbaa3.
"partition" is used for node names, with associated "label" to match
policy set by 6dd94c2781.

The OEM source code also define a "RouterBootFake" partition at the
beginning of the secondary flash chip: to avoid trouble if OEM ever makes
use of that space, it is also defined here.

The resulting partition scheme looks like this:
[   10.114241] m25p80 spi0.0: w25x40 (512 Kbytes)
[   10.118708] 1 fixed-partitions partitions found on MTD device spi0.0
[   10.125049] Creating 1 MTD partitions on "spi0.0":
[   10.129824] 0x000000000000-0x000000040000 : "RouterBoot"
[   10.136215] 5 fixed-partitions partitions found on MTD device RouterBoot
[   10.142894] Creating 5 MTD partitions on "RouterBoot":
[   10.148032] 0x000000000000-0x00000000f000 : "bootloader1"
[   10.154336] 0x00000000f000-0x000000010000 : "hard_config"
[   10.160665] 0x000000010000-0x00000001f000 : "bootloader2"
[   10.167046] 0x000000020000-0x000000021000 : "soft_config"
[   10.173461] 0x000000030000-0x000000031000 : "bios"
[   10.190191] m25p80 spi0.1: w25q128 (16384 Kbytes)
[   10.194950] 2 fixed-partitions partitions found on MTD device spi0.1
[   10.201271] Creating 2 MTD partitions on "spi0.1":
[   10.206071] 0x000000000000-0x000000040000 : "RouterBootFake"
[   10.212746] 0x000000040000-0x000001000000 : "firmware"
[   10.307216] 2 minor-fw partitions found on MTD device firmware
[   10.313044] 0x000000040000-0x000000220000 : "kernel"
[   10.319002] 0x000000220000-0x000001000000 : "rootfs"
[   10.324906] mtd: device 9 (rootfs) set to be root filesystem
[   10.330678] 1 squashfs-split partitions found on MTD device rootfs
[   10.336886] 0x000000b40000-0x000001000000 : "rootfs_data"

Leave a note in DTS to explain how the original author selected the SPI speed.

Tested-by: Tobias Schramm <tobleminer@gmail.com>
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
Reviewed-by: Rafał Miłecki <rafal@milecki.pl>
[rmilecki: dropped "RouterBootFake" partition]
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
5 years agoar71xx: fix typo in rb91x nand source
Koen Vandeputte [Fri, 24 Aug 2018 07:10:29 +0000 (09:10 +0200)]
ar71xx: fix typo in rb91x nand source

Fixes: 3b1ea0996f83 ("ar71xx: fix build error due to bad include")
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
5 years agoath79: ubnt-xm: create mapping for RSSI LEDs
Lech Perczak [Tue, 21 Aug 2018 21:20:36 +0000 (23:20 +0200)]
ath79: ubnt-xm: create mapping for RSSI LEDs

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>
5 years agoath79: ubnt-xm: hijack LED4 as booting/failsafe
Lech Perczak [Tue, 21 Aug 2018 21:17:00 +0000 (23:17 +0200)]
ath79: ubnt-xm: hijack LED4 as booting/failsafe

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>
5 years agoath79: ubnt-xm: disable WAN on (rocket|bullet)-m
Lech Perczak [Tue, 21 Aug 2018 21:06:59 +0000 (23:06 +0200)]
ath79: ubnt-xm: disable WAN on (rocket|bullet)-m

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>
5 years agoath79: ubnt-xm: support ath9k firmware loading
Lech Perczak [Tue, 21 Aug 2018 18:43:45 +0000 (20:43 +0200)]
ath79: ubnt-xm: support ath9k firmware loading

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>
5 years agoath79: add support for I-O DATA ETG3-R
INAGAKI Hiroshi [Mon, 20 Aug 2018 07:32:42 +0000 (16:32 +0900)]
ath79: add support for I-O DATA ETG3-R

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>
5 years agoramips: mt7620: add dir-810l network config
Roger Pueyo Centelles [Thu, 23 Aug 2018 13:04:31 +0000 (15:04 +0200)]
ramips: mt7620: add dir-810l network config

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>
5 years agoramips: add support for ELECOM WRC-1900GST
NOGUCHI Hiroshi [Sat, 18 Aug 2018 23:05:15 +0000 (08:05 +0900)]
ramips: add support for ELECOM WRC-1900GST

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>
5 years agoramips: fix compatibles in SoC dtsi
Mathias Kresin [Wed, 22 Aug 2018 04:57:48 +0000 (06:57 +0200)]
ramips: fix compatibles in SoC dtsi

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>
5 years agoramips: fix GL-MT300N-V2 SoC compatible
Mathias Kresin [Wed, 22 Aug 2018 04:40:28 +0000 (06:40 +0200)]
ramips: fix GL-MT300N-V2 SoC compatible

According to abbfcc85259a ("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>
5 years agoramips: drop not existing groups from pinmux
Mathias Kresin [Wed, 22 Aug 2018 04:26:36 +0000 (06:26 +0200)]
ramips: drop not existing groups from pinmux

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>
5 years agogeneric: revert workarounds for AR8337 switch
Mathias Kresin [Wed, 15 Aug 2018 06:20:33 +0000 (08:20 +0200)]
generic: revert workarounds for AR8337 switch

The intention of 967b6be118e3 ("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>
5 years agowolfssl: disable broken shipped Job server macro
Jo-Philipp Wich [Thu, 23 Aug 2018 18:03:29 +0000 (20:03 +0200)]
wolfssl: disable broken shipped Job server macro

The AX_AM_JOBSERVER macro shipped with m4/ax_am_jobserver.m4 is broken on
plain POSIX shells due to the use of `let`.

Shells lacking `let` will fail to run the generated m4sh code and end up
invoking "make" with "-jyes" as argument, fialing the build.

Since there is no reason in the first place for some random package to
muck with the make job server settings and since we do not want it to
randomly override "-j" either, simply remove references to this defunct
macro to let the build succeed on platforms which not happen to use bash
as default shell.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
5 years agogrub2: rebase patches
Jo-Philipp Wich [Thu, 23 Aug 2018 17:08:58 +0000 (19:08 +0200)]
grub2: rebase patches

Patch 300-CVE-2015-8370.patch was added without proper rebasing on the
version used by OpenWrt, make it apply and refresh the patch to fix
compilation.

Fixes: 7e73e9128f ("grub2: Fix CVE-2015-8370")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
5 years agouhttpd: support multiple Lua prefixes
Jo-Philipp Wich [Thu, 23 Aug 2018 07:07:23 +0000 (09:07 +0200)]
uhttpd: support multiple Lua prefixes

Update to latest git HEAD in order to support configuring multiple
concurrent Lua prefixes in a single uhttpd instance:

  b741dec lua: support multiple Lua prefixes

Additionally rework the init script and update the default configuration
example to treat the lua_prefix option as key=value uci list, similar to
the interpreter extension mapping. Support for the old "option lua_prefix"
plus "option lua_handler" notation is still present.

Finally drop the sed postinstall hack in uhttpd-mod-lua to avoid mangling
files belonging to other packages. Since Lua prefixes have precedence
over CGI prefixes, simply register `/cgi-bin/luci` as Lua handler which
will only become active if both luci-base and uhttpd-mod-lua is installed.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
5 years agogrub2: Fix CVE-2015-8370
Rosen Penev [Thu, 23 Aug 2018 02:07:57 +0000 (19:07 -0700)]
grub2: Fix CVE-2015-8370

This CVE is a culmination of multiple integer overflow issues that cause
multiple issues like Denial of Service and authentication bypass.

More info: https://nvd.nist.gov/vuln/detail/CVE-2015-8370

Taken from Fedora.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
5 years agobzip2: Fix CVE-2016-3189
Rosen Penev [Thu, 23 Aug 2018 02:07:56 +0000 (19:07 -0700)]
bzip2: Fix CVE-2016-3189

Issue causes a crash with specially crafted bzip2 files.

More info: https://nvd.nist.gov/vuln/detail/CVE-2016-3189

Taken from Fedora.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
5 years agokernel: bump 4.14 to 4.14.66
Koen Vandeputte [Wed, 22 Aug 2018 09:22:30 +0000 (11:22 +0200)]
kernel: bump 4.14 to 4.14.66

Refreshed all patches

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

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
5 years agokernel: bump 4.9 to 4.9.123
Koen Vandeputte [Wed, 22 Aug 2018 09:21:12 +0000 (11:21 +0200)]
kernel: bump 4.9 to 4.9.123

Refreshed all patches

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

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
5 years agoar71xx: fix build error due to bad include
Koen Vandeputte [Wed, 22 Aug 2018 11:00:22 +0000 (13:00 +0200)]
ar71xx: fix build error due to bad include

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: 318e19ba6755 ("ar71xx: add v4.14 support")
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
5 years agoar71xx: add missing include for checking kernel version
Koen Vandeputte [Wed, 22 Aug 2018 11:00:21 +0000 (13:00 +0200)]
ar71xx: add missing include for checking kernel version

Fixes these build errors:

arch/mips/ath79/mach-rb2011.c:20:5: error: "LINUX_VERSION_CODE" is not defined, evaluates to 0 [-Werror=undef]
 #if LINUX_VERSION_CODE < KERNEL_VERSION(4,14,0)
     ^~~~~~~~~~~~~~~~~~
arch/mips/ath79/mach-rb2011.c:20:26: error: "KERNEL_VERSION" is not defined, evaluates to 0 [-Werror=undef]
 #if LINUX_VERSION_CODE < KERNEL_VERSION(4,14,0)
                          ^~~~~~~~~~~~~~
arch/mips/ath79/mach-rb2011.c:20:40: error: missing binary operator before token "("
 #if LINUX_VERSION_CODE < KERNEL_VERSION(4,14,0)
                                        ^

Fixes: 318e19ba6755 ("ar71xx: add v4.14 support")
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
5 years agosamba36: Enable umdnsd support
Rosen Penev [Fri, 17 Aug 2018 02:32:59 +0000 (19:32 -0700)]
samba36: Enable umdnsd support

Allows discovery without having to use NetBIOS. Useful for mobile devices.

Could eventually throw nbmd away. But that requires Windows 10...

Tested on Fedora 28 with avahi-discover.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
5 years agoyamonenv: Remove dead URLs
Rosen Penev [Fri, 17 Aug 2018 02:38:58 +0000 (19:38 -0700)]
yamonenv: Remove dead URLs

uscan errors on the URL as it is no longer available.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
5 years agofconfig: Remove dead URLs
Rosen Penev [Fri, 17 Aug 2018 02:38:57 +0000 (19:38 -0700)]
fconfig: Remove dead URLs

uscan errors on the URL as it is no longer available.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
5 years agoapex: Remove dead URL.
Rosen Penev [Fri, 17 Aug 2018 02:38:56 +0000 (19:38 -0700)]
apex: Remove dead URL.

uscan errors on the URL as it is no longer available.

Also switched the download URL to HTTPS.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
5 years agoar71xx: add v4.14 support
John Crispin [Thu, 9 Aug 2018 13:59:41 +0000 (15:59 +0200)]
ar71xx: add v4.14 support

adds v4.14 patches for testing but leaves v4.9 as default for now.

Signed-off-by: John Crispin <john@phrozen.org>
5 years agoiptables: make iptables-mod-conntrack-extra depend on kmod-ipt-raw
Jo-Philipp Wich [Wed, 22 Aug 2018 05:12:47 +0000 (07:12 +0200)]
iptables: make iptables-mod-conntrack-extra depend on kmod-ipt-raw

Since kernel 4.14 there is no auto assignment of conntrack helpers anymore
so fw3 needs raw table support in order to stage ct helper assignment rules.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
5 years agodnsmasq: remove creation of /etc/ethers
Hans Dedecker [Sun, 19 Aug 2018 18:52:00 +0000 (20:52 +0200)]
dnsmasq: remove creation of /etc/ethers

Remove creation of file /etc/ethers in dnsmasq init script as the
file is now created by default in the base-files package by
commit fa3301a28e

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
5 years agobase-files: create /etc/ethers by default
Luiz Angelo Daros de Luca [Sun, 19 Aug 2018 01:53:07 +0000 (22:53 -0300)]
base-files: create /etc/ethers by default

/etc/ethers is missing on /rom but always created when dnsmasq
runs. It is better to have it in place and avoid an extra change
in flash after firstboot.

It will generate an extra /etc/ethers-opkg when it has changed.

Signed-off-by: Luiz Angelo Daros de Luca <luizluca@gmail.com>
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
5 years agouhttpd: update to latest Git head
Jo-Philipp Wich [Tue, 21 Aug 2018 12:48:47 +0000 (14:48 +0200)]
uhttpd: update to latest Git head

952bf9d build: use _DEFAULT_SOURCE
30a18cb uhttpd: recognize PATCH, PUT and DELETE HTTP methods

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
5 years agomwlwifi: Update to 10.3.8.0-20180810
Daniel Engberg [Fri, 17 Aug 2018 08:00:02 +0000 (10:00 +0200)]
mwlwifi: Update to 10.3.8.0-20180810

Update mwlwifi to 10.3.8.0-20180810

Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
5 years agonetifd: update to latest git HEAD
Hans Dedecker [Mon, 20 Aug 2018 14:25:10 +0000 (16:25 +0200)]
netifd: update to latest git HEAD

7454d12 interface: let interface_set_down() return void
32f11a8 interface: make __interface_set_down() static
b9d5a8c interface: extend interface error messages in interface_set_up()
de394b3 interface: ensure NO_DEVICE error is always reported

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
5 years agokernel: bump 3.18 to 3.18.119
Koen Vandeputte [Mon, 20 Aug 2018 08:43:09 +0000 (10:43 +0200)]
kernel: bump 3.18 to 3.18.119

Refreshed all patches.

Compile-tested on: adm5120, adm8668, au1000, mcs814x, ppc40x, ppc44x, xburst
Runtime-tested on: none

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
5 years agokernel: bump 4.14 to 4.14.65
Koen Vandeputte [Mon, 20 Aug 2018 08:33:19 +0000 (10:33 +0200)]
kernel: bump 4.14 to 4.14.65

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>
5 years agokernel: bump 4.9 to 4.9.122
Koen Vandeputte [Mon, 20 Aug 2018 08:32:54 +0000 (10:32 +0200)]
kernel: bump 4.9 to 4.9.122

Refreshed all patches.

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

Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
5 years agohostapd: process all CSA parameters
Yury Shvedov [Mon, 16 Jul 2018 12:15:10 +0000 (15:15 +0300)]
hostapd: process all CSA parameters

This adds processing of all CSA arguments from ubus switch_chan request
in the same manner as in the control interface API.

Signed-off-by: Yury Shvedov <yshvedov@wimarksystems.com>
5 years agotoolchain/gcc: update 8.x to 8.2.0
Syrone Wong [Fri, 27 Jul 2018 10:32:03 +0000 (18:32 +0800)]
toolchain/gcc: update 8.x to 8.2.0

This release fixes LTO link-time performance problems and C++ bug introduced in GCC 8.1

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
5 years agotoolchain/gcc: add config symbol to determine how to apply path remapping
Syrone Wong [Thu, 26 Jul 2018 14:38:57 +0000 (22:38 +0800)]
toolchain/gcc: add config symbol to determine how to apply path remapping

Added boolean symbol for GCC 8 and higher, when we add newer GCC, we don't have
to modify rules.mk to keep things consistant.

Fixes: da9d760 ("rules.mk: replace iremap when using GCC 8")
Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
5 years agotarget.mk: Remove obsolete octeon CPU_CFLAGS
Daniel Engberg [Sun, 19 Aug 2018 06:14:50 +0000 (08:14 +0200)]
target.mk: Remove obsolete octeon CPU_CFLAGS

As of commit c6e02b49f65cb4eff624a0831d3db265b3fadd2a the octeon target
uses octeonplus instead of octeon

Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
5 years agoath79: fix TL-MR3020 image metadata
David Bauer [Sat, 18 Aug 2018 12:01:59 +0000 (14:01 +0200)]
ath79: fix TL-MR3020 image metadata

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>
5 years agoath79: cleanup PISEN WMM003N image metadata
Chuanhong Guo [Sun, 19 Aug 2018 13:47:06 +0000 (21:47 +0800)]
ath79: cleanup PISEN WMM003N image metadata

PISEN WMM003N is never supported by ar71xx, this commit also removed
SUPPORTED_DEVICES for it because it's completely useless.

Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
5 years agoath79: add support for Fritz!Box 4020
David Bauer [Sat, 18 Aug 2018 16:30:46 +0000 (18:30 +0200)]
ath79: add support for Fritz!Box 4020

This commit adds support for the AVM Fritz!Box 4020 WiFi-router.

SoC:   Qualcomm Atheros QCA9561 (Dragonfly) 750MHz
RAM:   Winbond W971GG6KB-25
FLASH: Macronix MX25L12835F
WiFi:  QCA9561 b/g/n 3x3 450Mbit/s
USB:   1x USB 2.0
IN:    WPS button, WiFi button
OUT:   Power LED green, Internet LED green, WLAN LED green,
       LAN LED green, INFO LED green, INFO LED red
UART:  Header Next to Black metal shield
       Pinout is 3.3V - RX - TX - GND (Square Pad is 3.3V)
       The Serial setting is 115200-8-N-1.

Tested and working:
 - Ethernet (LAN + WAN)
 - WiFi (correct MAC)
 - Installation via EVA bootloader
 - OpenWRT sysupgrade
 - Buttons
 - LEDs

The USB port doesn't work. Both Root Hubs are detected as having 0 Ports:

[    3.670807] kmodloader: loading kernel modules from /etc/modules-boot.d/*
[    3.723267] usbcore: registered new interface driver usbfs
[    3.729058] usbcore: registered new interface driver hub
[    3.734616] usbcore: registered new device driver usb
[    3.744181] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    3.758357] SCSI subsystem initialized
[    3.766026] ehci-platform: EHCI generic platform driver
[    3.771548] ehci-platform ehci-platform.0: EHCI Host Controller
[    3.777708] ehci-platform ehci-platform.0: new USB bus registered, assigned bus number 1
[    3.788169] ehci-platform ehci-platform.0: irq 48, io mem 0x1b000000
[    3.816647] ehci-platform ehci-platform.0: USB 2.0 started, EHCI 0.00
[    3.824001] hub 1-0:1.0: USB hub found
[    3.828219] hub 1-0:1.0: config failed, hub doesn't have any ports! (err -19)
[    3.835825] ehci-platform ehci-platform.1: EHCI Host Controller
[    3.842009] ehci-platform ehci-platform.1: new USB bus registered, assigned bus number 2
[    3.852481] ehci-platform ehci-platform.1: irq 49, io mem 0x1b400000
[    3.886631] ehci-platform ehci-platform.1: USB 2.0 started, EHCI 0.00
[    3.894011] hub 2-0:1.0: USB hub found
[    3.898190] hub 2-0:1.0: config failed, hub doesn't have any ports! (err -19)
[    3.908928] usbcore: registered new interface driver usb-storage
[    3.915634] kmodloader: done loading kernel modules from /etc/modules-boot.d/*

A few words about the shift-register:

AVM used a trick to control the shift-register for the LEDs with only 2
pins, SERCLK and MOSI. Q7S, normally used for daisy-chaining multiple
shift-registers, pulls the latch, moving the shift register-state to
the storage register. It also pulls down MR (normally pulled up) to
clear the storage register, so the latch gets released and will not be
pulled by the remaining bits in the shift-register. Shift register is
all-zero after this.

For that we need to make sure output 7 is set to high on driver probe.
We accomplish this by using gpio-hogging.

Installation via EVA:
In the first seconds after Power is connected, the bootloader will
listen for FTP connections on 169.254.157.1 (Might also be 192.168.178.1).
Firmware can be uploaded like following:

  ftp> quote USER adam2
  ftp> quote PASS adam2
  ftp> binary
  ftp> debug
  ftp> passive
  ftp> quote MEDIA FLSH
  ftp> put openwrt-sysupgrade.bin mtd1

Note that this procedure might take up to two minutes. After transfer is
complete you need to powercycle the device to boot OpenWRT.

Signed-off-by: David Bauer <mail@david-bauer.net>
5 years agoath79: add support for TP-Link Archer C7 v1
Christian Lamparter [Fri, 17 Aug 2018 16:36:32 +0000 (18:36 +0200)]
ath79: add support for TP-Link Archer C7 v1

TP-Link Archer C7 v1 is a dual band router
based on Qualcomm/Atheros QCA9558 + QCA9880.

Specification:

 - 720 MHz CPU
 - 128 MB of RAM (Various chips)
 - 8 MB of FLASH (Various chips)
 - SoC QCA9558 integrated 3T3R 2.4 GHz Wi-Fi
 - minipcie slot with 3T3R 5 GHz QCA9880-AR1A (unsupported by ath10k!)
 - 5x 10/100/1000 Mbps Ethernet (AR8327N Switch)
 - 10x LEDs, 2x software buttons

For further informwation on the device, visit the wiki:
<https://openwrt.org/toh/tp-link/archer-c7-1750>

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
5 years agoutil-linux: Update to 2.32.1
Daniel Engberg [Sun, 12 Aug 2018 22:01:56 +0000 (00:01 +0200)]
util-linux: Update to 2.32.1

Update util-linux to 2.32.1
For release notes see https://lwn.net/Articles/759922/

Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
5 years agoath79: add support for I-O DATA WN-AC1167DGR
INAGAKI Hiroshi [Thu, 16 Aug 2018 08:08:28 +0000 (17:08 +0900)]
ath79: add support for I-O DATA WN-AC1167DGR

I-O DATA WN-AC1167DGR is a 2.4/5 GHz band 11ac router, based on
Qualcomm Atheros QCA9557.

Specification:

- Qualcomm Atheros QCA9557
- 128 MB of RAM (DDR2)
- 16 MB of Flash (SPI)
- 2T2R 2.4/5 GHz wifi
  - 2.4 GHz: SoC internal
  - 5 GHz: QCA988x
- 5x 10/100/1000 Mbps Ethernet
- 6x LEDs, 6x keys (4x buttons, 1x slide switch)
- UART header on PCB
  - Vcc, GND, TX, RX from ethernet port side
  - 115200n8

Flash instruction using factory image:

1. Connect the computer to the LAN port of WN-AC1167DGR
2. Connect power cable to WN-AC1167DGR and turn on it
3. Access to "http://192.168.0.1/" and open firmware update page
("ファームウェア")
4. Select the OpenWrt factory image and click update ("更新") button
5. Wait ~150 seconds to complete flashing

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
5 years agoath79: fix leds and network for TP-Link TL-WR841 v9/v11
Johann Neuhauser [Thu, 16 Aug 2018 08:30:17 +0000 (10:30 +0200)]
ath79: fix leds and network for TP-Link TL-WR841 v9/v11

Adding tl-wr841-v11 and the rename of tl-wr841n-v9 to tl-wr841-v9 in 01_leds
and 02_network script files are missing in commits cc35c91 and 8db6522.

Signed-off-by: Johann Neuhauser <johann@it-neuhauser.de>
[merged with identical case in 02_network]
Signed-off-by: Mathias Kresin <dev@kresin.me>
5 years agoath79: don't use the pcs,cr5000 wps led as usb led
Mathias Kresin [Thu, 16 Aug 2018 07:53:26 +0000 (09:53 +0200)]
ath79: don't use the pcs,cr5000 wps led as usb led

If it isn't a usb led, it shouldn't be used as one by default. It is up
to the user to add such a (mis)configuration for the board.

Signed-off-by: Mathias Kresin <dev@kresin.me>
5 years agoath79: add support for TP-Link MR-3040 v2
Dmitry Tunin [Mon, 13 Aug 2018 14:14:54 +0000 (17:14 +0300)]
ath79: add support for TP-Link MR-3040 v2

Add support for the ar71xx supported TP-Link MR-3040 v2.

Signed-off-by: Dmitry Tunin <hanipouspilot@gmail.com>
5 years agoath79: add support for Buffalo WHR-G301N
INAGAKI Hiroshi [Tue, 14 Aug 2018 06:01:05 +0000 (15:01 +0900)]
ath79: add support for Buffalo WHR-G301N

Buffalo WHR-G301N is a 2.4 GHz 11n router, based on Atheros AR7240.
Ported from ar71xx target.

Specification:

- Atheros AR7240
- 32 MB of RAM
- 4 MB of Flash
- 2.4 GHz 2T2R wifi
- 5x 10/100 Mbps Ethernet
- 9x LEDs, 4x keys
  - LED: 8x gpio-leds, 1x ath9k-leds
  - key: 2x buttons, 1x slide switch
- UART header on PCB
  - Vcc, GND, TX, RX from LEDs side
  - 115200n8

Flash instruction using factory image:

1. Connect the computer to the LAN port of WHR-G301N
2. Connect power cable to WHR-G301N and turn on it
3. Access to "http://192.168.11.1/" and open firmware update page
("ファーム更新")
4. Select the OpenWrt factory image and click execute ("実行") button
5. Wait ~150 seconds to complete flashing

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
[fix the SUPPORTED_DEVICES to be compatible with the ar71xx image]
Signed-off-by: Mathias Kresin <dev@kresin.me>