openwrt/staging/blogic.git
8 years agokernel: Fix ipv6 mc snooping if bridge has no ipv6 address
daniel [Thu, 30 Jun 2016 21:49:52 +0000 (23:49 +0200)]
kernel: Fix ipv6 mc snooping if bridge has no ipv6 address

This patch is a backport for current LEDE 4.4 Kernels.
It is already upstream, for linux-next and stable.
The initial commit message is below:

The bridge is falsly dropping ipv6 mulitcast packets if there is:
 1. No ipv6 address assigned on the brigde.
 2. No external mld querier present.
 3. The internal querier enabled.

When the bridge fails to build mld queries, because it has no
ipv6 address, it slilently returns, but keeps the local querier enabled.
This specific case causes confusing packet loss.

Ipv6 multicast snooping can only work if:
 a) An external querier is present
 OR
 b) The bridge has an ipv6 address an is capable of sending own queries

Otherwise it has to forward/flood the ipv6 multicast traffic,
because snooping cannot work.

This patch fixes the issue by adding a flag to the bridge struct that
indicates that there is currently no ipv6 address assinged to the bridge
and returns a false state for the local querier in
__br_multicast_querier_exists().

Special thanks to Linus Lüssing.

Signed-off-by: Daniel Danzberger <daniel@dd-wrt.com>
8 years agospidev_test: copy the source code into the package folder
John Crispin [Thu, 30 Jun 2016 11:05:22 +0000 (13:05 +0200)]
spidev_test: copy the source code into the package folder

Signed-off-by: John Crispin <john@phrozen.org>
8 years agokernel: other.mk: add pps-ldisc support
Stephen Walker [Wed, 29 Jun 2016 22:34:50 +0000 (18:34 -0400)]
kernel: other.mk: add pps-ldisc support

The pps-ldisc kernel module supports Pulse-Per-Second connected with the CD (Carrier Detect) pin.

Signed-off-by: Stephen Walker <stephendwalker+github@gmail.com>
8 years agoar71xx: seama: fix making factory images
Yousong Zhou [Thu, 30 Jun 2016 01:54:21 +0000 (09:54 +0800)]
ar71xx: seama: fix making factory images

rootfs part needs to be aligned to erase block size which is passed as
the 6th argument to Image/Build/Seama  and is now 65536 since commit
commit 5119ee9 "ar71xx: fix bogus hardcoded kernel image size for Seama
images (fixes #20585)", but $(($(6) - 64)) still assumes that the
argument is a limit on kernel partition size, i.e. 1310720, so the
generated factory image is wrong in that the kernel will fail to find
the rootfs (FlySpray link at [1])

This patch will workaround it with the following steps

1. Calculate the required space for seama header and META data in step 5
2. Pre-padding 64 bytes to lzma-compressed loader
3. Generate correctly padded image-$(2).tmp
4. Strip out the padding
5. Seal it with seama utility

While at it convert seama to new build method

[1] FS#35 - mynet-n750 factory images don't find root partition,
    https://bugs.lede-project.org/index.php?do=details&task_id=35

Reported-by: Steven Haigh <netwiz@crc.id.au>
Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
8 years agoar71xx: image: unify indentation with 2 whitespaces
Yousong Zhou [Thu, 30 Jun 2016 01:54:20 +0000 (09:54 +0800)]
ar71xx: image: unify indentation with 2 whitespaces

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
8 years agoar71xx: image: remove duplicate IMAGES definition
Yousong Zhou [Thu, 30 Jun 2016 01:54:19 +0000 (09:54 +0800)]
ar71xx: image: remove duplicate IMAGES definition

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
8 years agoar71xx: hiwifi-hc6361: move packages selection to generic.mk
Yousong Zhou [Thu, 30 Jun 2016 01:54:18 +0000 (09:54 +0800)]
ar71xx: hiwifi-hc6361: move packages selection to generic.mk

Remove kmod-crypto-deflate and kmod-ledtrig-gpio as the device works the
same by default without them

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
8 years agoprocd: change /dev/{gpio,hvc*} perms to 0600
John Crispin [Wed, 29 Jun 2016 13:44:30 +0000 (15:44 +0200)]
procd: change /dev/{gpio,hvc*} perms to 0600

Signed-off-by: John Crispin <john@phrozen.org>
8 years agoprocd: adjust /dev entries to desktop distro defaults
neheb [Sat, 25 Jun 2016 05:39:25 +0000 (22:39 -0700)]
procd: adjust /dev entries to desktop distro defaults

This changes the default permissions for /dev entries to be more similar to
a desktop distro. Taken from the defaults of Arch Linux and Ubuntu. Also
changed some that were nonsensical. For example, all 660 permissions on
desktop distros were of the form root:x where x is something other than
root. As such, 660 is useless for LEDE where the specific group is missing.
audio seems to be the only group that isn't.

Signed-off by: Rosen Penev <rosenp@gmail.com>

8 years agoramips: disable the WP pin on the SDK mmc driver
John Crispin [Tue, 28 Jun 2016 09:15:31 +0000 (11:15 +0200)]
ramips: disable the WP pin on the SDK mmc driver

Signed-off-by: John Crispin <john@phrozen.org>
8 years agoramips: fix pinmux typo
John Crispin [Tue, 28 Jun 2016 08:59:56 +0000 (10:59 +0200)]
ramips: fix pinmux typo

Reported-by: Joy Kicer <joykicer@gmail.com>
Signed-off-by: John Crispin <john@phrozen.org>
8 years agobase-files: seed /dev/urandom
Etienne CHAMPETIER [Mon, 27 Jun 2016 15:53:30 +0000 (15:53 +0000)]
base-files: seed /dev/urandom

This commit:
1) seed /dev/urandom with the saved seeds as early as possible
   (see /lib/preinit/81_urandom_seed)
2) save a seed at /etc/urandom.seed if it doesn't exists
3) save a new seed each boot at "system.@system[0].urandom_seed"
   (see /etc/init.d/urandom_seed)

We use getrandom() so we are sure /dev/urandom pool is initialized

Seed size is 512 bytes (ie /proc/sys/kernel/random/poolsize / 8)
it's the same size as in ubuntu 14.04 and all systemd systems

Seeding /dev/urandom doesn't change entropy estimation, so we still have
"random: ubus urandom read with 4 bits of entropy available"
messages in the logs, but we can now ignore them if
after "urandom-seed: Seeding with ..." message

Saving a new seed on each boot is disabled by default to avoid too much
writes without user consent

v2: log preinit messages to /dev/kmsg
v3: use non generic function name for logging, as /lib/preinit/ files
    are all sourced together in /etc/preinit
v4: after a lot of discussion on the ML, use a uci config param
v5: config param is now the path of the seed

Signed-off-by: Etienne CHAMPETIER <champetier.etienne@gmail.com>
Acked-by: Jo-Philipp Wich <jo@mein.io>
8 years agokernel: Add option to make using filesystem ACL support the default
Daniel Dickinson [Thu, 17 Dec 2015 03:58:11 +0000 (22:58 -0500)]
kernel: Add option to make using filesystem ACL support the default

This adds a configuration options that allows to make filesystem ACL support
the default in the kernel, except for old nfs.

Signed-off-by: Daniel Dickinson <openwrt@daniel.thecshore.com>
8 years agopackage/kernel: Enable XATTR by default
Daniel Dickinson [Wed, 18 May 2016 08:59:15 +0000 (04:59 -0400)]
package/kernel: Enable XATTR by default

OpenWrt enables XATTR support pretty much universally, therefore
for filesystems that a loaded as modules also enable XATTR support
so that there are no unexpected missing capabilities.

Signed-off-by: Daniel Dickinson <lede@daniel.thecshore.com>
8 years agoe2fsprogs: fix build problem with very old libmagic
Hauke Mehrtens [Fri, 24 Jun 2016 15:37:40 +0000 (17:37 +0200)]
e2fsprogs: fix build problem with very old libmagic

The libmagic shipped with RedHat 5 does not define
MAGIC_NO_CHECK_ELF and MAGIC_NO_CHECK_COMPRESS. e2fsprogs should
check for that, otherwise the build will fail.

Signed-off-by: Hauke Mehrtens <hauke.mehrtens@intel.com>
8 years agoprism54-firmware: add also other p54 firmware to own package
Hauke Mehrtens [Fri, 24 Jun 2016 13:46:31 +0000 (15:46 +0200)]
prism54-firmware: add also other p54 firmware to own package

Extract the other p54 firmware files into the prism54-firmware package.

Signed-off-by: Hauke Mehrtens <hauke.mehrtens@intel.com>
8 years agofirmware: extract prism54-firmware into own package
Hauke Mehrtens [Wed, 22 Jun 2016 15:46:21 +0000 (17:46 +0200)]
firmware: extract prism54-firmware into own package

Instead of downloading the firmware for prism54 devices in the
wireless.mk do it in an extra package Makefile. To ship the complete
source code Intel ships our modified OpenWrt/LEDE + the content of the
dl directory. We do not want to have any files in the dl/ directory
which are not needed to build our images. The prism54 gets downloaded
every time independently of building kmod-net-prism54 or not. When it
is in a own package it only gets downloaded when the firmware package
is selected.

Signed-off-by: Hauke Mehrtens <hauke.mehrtens@intel.com>
8 years agoramips: set correct LAN/WAN MAC addresses on DIR-860L B1
Matthias Schiffer [Thu, 30 Jun 2016 14:16:30 +0000 (16:16 +0200)]
ramips: set correct LAN/WAN MAC addresses on DIR-860L B1

Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
Reviewed-by: Jo-Philipp Wich <jo@mein.io>
8 years agoramips: add button support and make LEDs known to userspace for DIR-860L B1
Matthias Schiffer [Thu, 30 Jun 2016 13:18:03 +0000 (15:18 +0200)]
ramips: add button support and make LEDs known to userspace for DIR-860L B1

Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
Reviewed-by: Jo-Philipp Wich <jo@mein.io>
8 years agoramips: fix fixseama call on first boot
Matthias Schiffer [Thu, 30 Jun 2016 13:50:11 +0000 (15:50 +0200)]
ramips: fix fixseama call on first boot

Commit "kernel: mtdsplit: calculate kernel partition precisely for Seama"
changed the kernel partition to only contain the kernel itself and not
the Seama header. Adjust the fixseama call to match what is used on
brcm53xx.

This fixes failing to boot a second time after flashing the factory image
on the affected devices.

Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
Reviewed-by: Jo-Philipp Wich <jo@mein.io>
8 years agoodhcp6c: Upstep to latest version
Hans Dedecker [Thu, 30 Jun 2016 10:28:22 +0000 (12:28 +0200)]
odhcp6c: Upstep to latest version

Following fixes are included in the latest version:
    -Script is launched with incorrect action
    -Possible buffer overflows
    -Lots of minor bugfixes

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
8 years agokmod-sched-cake: Switch to COBALT algorithm
Kevin Darbyshire-Bryant [Wed, 29 Jun 2016 12:56:38 +0000 (13:56 +0100)]
kmod-sched-cake: Switch to COBALT algorithm

COBALT is a hybrid codel/blue algo combining best elements of both.
Exhibits improved behaviour in presence of abuse from unresponsive flows
handled by 'blue', whereas responsive flows are still handled by codel.

Signed-off-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
8 years agoiproute2: cake AQM prepare tc for COBALT algorithm
Kevin Darbyshire-Bryant [Mon, 27 Jun 2016 10:16:57 +0000 (11:16 +0100)]
iproute2: cake AQM prepare tc for COBALT algorithm

Cake AQM is experimenting with a codel/blue hybrid AQM COBALT instead
of just using codel alone. This patch updates tc to cope with some new
stats produced by COBALT.

Signed-off-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
8 years agodnsmasq: Add broken realtime clock build switch in full variant
Hans Dedecker [Wed, 29 Jun 2016 12:29:48 +0000 (14:29 +0200)]
dnsmasq: Add broken realtime clock build switch in full variant

By default dnsmasq uses the time function; which returns the time since
Epoch; to retrieve the current time. On boards which have no realtime
clock this can lead to side effects when the time is synced via ntp
as the "time wrap" forces dhcp leases to be considered as expired.
By enabling the broken realtime clock build switch dnsmasq uses the
times utility which returns the number of clock tick.

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
[Jo-Philipp Wich: change symbol name, add sym to PKG_CONFIG_DEPENDS]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
8 years agorpcd: iwinfo plugin fixes
Jo-Philipp Wich [Wed, 29 Jun 2016 22:40:21 +0000 (00:40 +0200)]
rpcd: iwinfo plugin fixes

 - Expose supported HT rate information in info call
 - Zero out ccode buffer when listing countries

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
8 years agokmod-bmp085: add dependency on !LINUX_3_18 !LINUX_4_1
Alexander Couzens [Wed, 29 Jun 2016 00:40:34 +0000 (02:40 +0200)]
kmod-bmp085: add dependency on !LINUX_3_18 !LINUX_4_1

93d5629a introduced a build failure on older platforms (<4.4)
because bmp085 is a boolean and not a tristate.

Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
8 years agomodules: add BMP085 pressure sensor
Dirk Neukirchen [Sat, 4 Jun 2016 16:34:02 +0000 (18:34 +0200)]
modules: add BMP085 pressure sensor

add BMP085 and BMP180 pressure sensors
this driver supports the SPI and I2C and
older chips (BMP280 is supported by iio subsystem)

issue found when cleaning up omap/config

found while writing this patch that a
similar patch was submitted in June/July 2014 but not integrated

only compile tested

Signed-off-by: Dirk Neukirchen <dirkneukirchen@web.de>
8 years agomac80211: fix skb size calculation in 4addr mode (FS#24)
Jo-Philipp Wich [Tue, 28 Jun 2016 20:43:22 +0000 (22:43 +0200)]
mac80211: fix skb size calculation in 4addr mode (FS#24)

The PDU length of incoming LLC frames is set to the total skb payload size
in __ieee80211_data_to_8023() of net/wireless/util.c which incorrectly
includes the length of the IEEE 802.11 header.

The resulting LLC frame header has a too large PDU length, causing the
llc_fixup_skb() function of net/llc/llc_input.c to reject the incoming
skb, effectively breaking STP.

Solve the problem by properly substracting the IEEE 802.11 frame header size
from the PDU length, allowing the LLC processor to pick up the incoming
control messages.

Special thanks to Gerry Rozema for tracking down the regression and proposing
a suitable patch.

Fixes FS#24.

References:
https://bugs.lede-project.org/index.php?do=details&task_id=24

Reported-by: Gerry Rozema <gerryr@rozeware.com>
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
8 years agobase-files: use LEDE NTP vendor pool
Jo-Philipp Wich [Tue, 28 Jun 2016 17:14:31 +0000 (19:14 +0200)]
base-files: use LEDE NTP vendor pool

The vendor NTP pool for the LEDE project got approved, so switch to it now.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
8 years agoopenvpn: fix missing cipher list for polarssl in v2.3.11
Jo-Philipp Wich [Tue, 28 Jun 2016 08:47:22 +0000 (10:47 +0200)]
openvpn: fix missing cipher list for polarssl in v2.3.11

Upstream OpenSSL hardening work introduced a change in shared code that
causes polarssl / mbedtls builds to break when no --tls-cipher is specified.

Import the upstream fix commit as patch until the next OpenVPN release gets
released and packaged.

Reported-by: Sebastian Koch <seb@metafly.info>
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
8 years agolldpd: Use /etc/os-release instead of /etc/openwrt_*
Daniel Dickinson [Wed, 18 May 2016 07:05:42 +0000 (03:05 -0400)]
lldpd: Use /etc/os-release instead of /etc/openwrt_*

With the addition of /etc/os-release patching lldpd to use
/etc/openwrt_release and to have the initscript use
/etc/openwrt_release and/or /etc/openwrt_version becomes
unnecessary.

Signed-off-by: Daniel Dickinson <lede@daniel.thecshore.com>
8 years agoar71xx: further legacy image build fixes
Jo-Philipp Wich [Mon, 27 Jun 2016 13:03:57 +0000 (15:03 +0200)]
ar71xx: further legacy image build fixes

- Add missing macro to trigger the generation of 64k padded squashfs images
- Revert Zcomax image generation to use the prepared 64k squashfs image

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
8 years agoRevert "lantiq: enable SMP for XRX200"
Felix Fietkau [Mon, 27 Jun 2016 10:40:44 +0000 (12:40 +0200)]
Revert "lantiq: enable SMP for XRX200"

This reverts commit cc3bfdb62f941dff3e2983591c78b6d39ca8d88a.

Apparently the ethernet driver is not SMP safe, as reported in
https://bugs.lede-project.org/index.php?do=details&task_id=27

Signed-off-by: Felix Fietkau <nbd@nbd.name>
8 years agoar71xx: disable pdata->use_flow_control for QCA9558
Felix Fietkau [Mon, 27 Jun 2016 08:04:47 +0000 (10:04 +0200)]
ar71xx: disable pdata->use_flow_control for QCA9558

Signed-off-by: Felix Fietkau <nbd@nbd.name>
8 years agoar71xx: rename ethernet pdata->builtin_switch to use_flow_control
Felix Fietkau [Mon, 27 Jun 2016 08:02:58 +0000 (10:02 +0200)]
ar71xx: rename ethernet pdata->builtin_switch to use_flow_control

Signed-off-by: Felix Fietkau <nbd@nbd.name>
8 years agoar71xx: merge profiles into image building code
Jo-Philipp Wich [Fri, 17 Jun 2016 04:53:22 +0000 (06:53 +0200)]
ar71xx: merge profiles into image building code

- Remove old style device profiles and convert them to device definitions
  within the image building code

- Fix the legacy build macros for the changed eval depth in the legacy
  image build wrapper

Signed-off-by: John Crispin <john@phrozen.org>
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
8 years agokernel: fix missing break in ubi auto-mounting patch
Hauke Mehrtens [Tue, 21 Jun 2016 20:07:04 +0000 (22:07 +0200)]
kernel: fix missing break in ubi auto-mounting patch

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Reviewed-by: Jo-Philipp Wich <jo@mein.io>
8 years agokernel: remove igb: Fix Null-pointer dereference patch
Hauke Mehrtens [Sun, 26 Jun 2016 16:47:29 +0000 (18:47 +0200)]
kernel: remove igb: Fix Null-pointer dereference patch

This patch is already included in the Linux mainline kernel since
v3.15, remove it from LEDE, see the lines directly before this patch.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agokernel: remove full cache flush in fuse_copy_do() for MIPS
Hauke Mehrtens [Sat, 2 Apr 2016 12:36:10 +0000 (14:36 +0200)]
kernel: remove full cache flush in fuse_copy_do() for MIPS

This patch was introduced in commit r16412 for the brcm47xx target only
and then moved to generic in commit r32395. It was initially added
because of ticket #5186 and should fix some problems with fuse file
systems and MIPS caches. The commit comment in r32395 says that this a
generic problem in MIPS CPUs, but does not name any specifics about
that. There was a fix added to kernel 2.6.21 in commit commit
7575a49f20 "[MIPS] Implement flush_anon_page()." that should fix this
problem, but that was already available before both commits were done
to OpenWrt.

I just tested fuse with ntfs.3g without this patch on a BCM4704
(BMIPS3300 V0.6) SoC and haven't seen any problems. Someone reported
that removing this patch improves some fuse operations by 5 times on
some modern MIPS cores.
My test was only a simple "dd if=/dev/zero of=/mnt/zero bs=5000" to an
USB stick.

This patch removes the patch to OpenWrt, because I assume that it is
not needed any more and Felix, the orginal author, also thinks so.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agokernel: remove one of two patches deactivating broken vdso support on mips
Hauke Mehrtens [Sun, 26 Jun 2016 12:46:37 +0000 (14:46 +0200)]
kernel: remove one of two patches deactivating broken vdso support on mips

The patch target/linux/generic/patches-4.4/206-mips-disable-vdso.patch
should be sufficient.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agokernel: update to version 4.4.14
Hauke Mehrtens [Sun, 26 Jun 2016 12:45:12 +0000 (14:45 +0200)]
kernel: update to version 4.4.14

Changelog: https://cdn.kernel.org/pub/linux/kernel/v4.x/ChangeLog-4.4.14

Some manual changes to target/linux/generic/patches-4.4/610-
netfilter_match_bypass_default_checks.patch were needed.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agoRevert "ar71xx: prevent spurious ethernet resets from dma hang check false positives"
Felix Fietkau [Sun, 26 Jun 2016 14:53:11 +0000 (16:53 +0200)]
Revert "ar71xx: prevent spurious ethernet resets from dma hang check false positives"

This reverts commit 3d58d7f053eae83b59baf5c8b8a58da78653f605.

8 years agolibnetfilter_queue: fix checksum computation
Alin Năstac [Fri, 24 Jun 2016 12:41:10 +0000 (14:41 +0200)]
libnetfilter_queue: fix checksum computation

There are 2 issues fixed by this patch:
  - UDP checksum is computed incorrectly, the used pseudo IP header
    contains transport protocol 6 iso 17
  - on big endian arches the UDP/TCP checksum is incorrectly
    computed when payload length is odd

Signed-off-by: Alin Nastac <alin.nastac@gmail.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name> [refresh patch]
8 years agobuild: Adds the ability to disable personal initramfs build for target device
Sergey Sergeev [Thu, 16 Jun 2016 19:04:51 +0000 (22:04 +0300)]
build: Adds the ability to disable personal initramfs build for target device

If KERNEL_INITRAMFS := in the target/linux/*/image/Makefile->Device/%NAME% section is set to ''
then personal initramfs file for this target device will not be created.
This var is similar to the Device/Build/kernel KERNEL_INSTALL :=

Signed-off-by: Sergey Sergeev <adron@yapic.net>
8 years agoar71xx: prevent spurious ethernet resets from dma hang check false positives
Felix Fietkau [Fri, 17 Jun 2016 21:58:11 +0000 (23:58 +0200)]
ar71xx: prevent spurious ethernet resets from dma hang check false positives

Signed-off-by: Felix Fietkau <nbd@nbd.name>
8 years agoar71xx: enable flow control for ethernet MACs with built-in switch
Felix Fietkau [Tue, 14 Jun 2016 09:27:20 +0000 (11:27 +0200)]
ar71xx: enable flow control for ethernet MACs with built-in switch

Should fix LAN speed issues on some devices. This is an updated version
of the previously reverted commit with the same name.
It improves the check for MACs connected to a built-in switch

Signed-off-by: Felix Fietkau <nbd@nbd.name>
8 years agolinux-firmware: fix md5sum
Hauke Mehrtens [Sat, 25 Jun 2016 16:55:50 +0000 (18:55 +0200)]
linux-firmware: fix md5sum

The copy on the mirror has a different md5sum as specified in this
package Makefile. The content of the file on the mirror is the same as
in the checkout so just update our md5sum.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agortl8192su-firmware: move firmware to own package
Hauke Mehrtens [Sat, 25 Jun 2016 16:40:00 +0000 (18:40 +0200)]
rtl8192su-firmware: move firmware to own package

Instead of downloading the firmware from some website take it from
linux-firmware package and do not download it separately any more.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agortl8192se-firmware: fix package build
Hauke Mehrtens [Sat, 25 Jun 2016 16:35:52 +0000 (18:35 +0200)]
rtl8192se-firmware: fix package build

The package did not pack the firmware because of a problem which looks
like a copy and past error.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agoRevert "ar71xx: fix legacy image building"
John Crispin [Thu, 23 Jun 2016 17:33:07 +0000 (19:33 +0200)]
Revert "ar71xx: fix legacy image building"

This reverts commit 59e98b27c93d282edb62fad756fd1c1e587c067f.

and

Revert "ar71xx: merge profiles into image building code"

This reverts commit 636089ead6864364798ac988299429d171051c0e.

these are still causing issues

Signed-off-by: John Crispin <john@phrozen.org>
8 years agoebtables: fix segmentation fault due to uninitialized extension data
Jo-Philipp Wich [Fri, 24 Jun 2016 13:04:27 +0000 (15:04 +0200)]
ebtables: fix segmentation fault due to uninitialized extension data

The ebtables code relies on the `-nostartfiles` linker argument to execute the
extension modules' `_init()` functions automatically which is not working
reliably across all supported targets and gcc versions.

Running an ebtables executable linked this way just crashes with a segmentation
fault at runtime on program startup, e.g. on ARM architectures.

In order to fix the issue ...
 - remove the use of the -nostartfiles linker flag
 - rename the init procedures to a generic name without implicit semantics
 - explicitely annotate those init procedures as constructors

The patch has been taken from the Alpine Linux distribution at
http://git.alpinelinux.org/cgit/aports/tree/main/ebtables/fix-extension-init.patch

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
8 years agobase-files: sysfixtime no longer exclude dnsmasq.time
Kevin Darbyshire-Bryant [Thu, 16 Jun 2016 09:50:36 +0000 (10:50 +0100)]
base-files: sysfixtime no longer exclude dnsmasq.time

dnsmasq's dnssec time checking method now uses a ntp hotplug mechanism,
therefore dnsmasq.time is redudant and no longer needs to be explicitly
excluded from sysfixtime.

Signed-off-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
8 years agodnsmasq: dnssec time handling uses ntpd hotplug
Kevin Darbyshire-Bryant [Tue, 14 Jun 2016 10:00:21 +0000 (11:00 +0100)]
dnsmasq: dnssec time handling uses ntpd hotplug

Change dnsmasq's dnssec time check handling to use time validity
indicated by ntpd rather than maintaining a cross boot/upgrade
/etc/dnsmasq.time timestamp file.  This saves flash device wear.

If ntpd client is configured in uci and you're using dnssec, then
dnsmasq will not check dnssec timestamp validity until ntpd hotplug
indicates sync via a stratum change. The ntpd hotplug leaves a status
flag file to indicate to dnsmasq.init that time is valid and that it
should now start in 'check dnssec timestamp valid' mode.

If ntpd client is not configured and you're using dnssec, then it is
presumed you're using an alternate time sync mechanism and that time is
correct, thus dnsmasq checks dnssec timestamps are valid from 1st start.

Signed-off-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
V2 - stratum & step ntp changes indicate time is valid
V3 - on initial flag file step signal dnsmasq with SIGHUP if running
V4 - only accept step ntp changes. Accepting both stratum & step could
result in unpleasant script race conditions
V5 - Actually only accepting stratum is the correct thing to do after
further testing
V6 - improve handling of non busybox ntpd
if sysntpd not executable
  dnsmasq checks dnssec timestamps
else
  sysntp script disabled - look for timestamp file - allows external mechanism to use hotplug flag file
  sysntp script enabled & uci ntp enabled  - look for timestamp file
  sysntp script enabled & uci ntp disabled - dnsmasq checks dnssec
timestamps
fi

8 years agobase-files: Add standard os-release file
Daniel Dickinson [Wed, 18 May 2016 13:07:30 +0000 (09:07 -0400)]
base-files: Add standard os-release file

/etc/os-release is the standard distribution release information
file, therefore add it (and image configuration options for
fields not previously present in LEDE).  Once it is deemed
reasonable the non-standard openwrt_release, openwrt_version,
and device_info files could be removed (that is with this patch
we consider them deprecated in favour of the standard file).

Signed-off-by: Daniel Dickinson <lede@daniel.thecshore.com>
8 years agoar71xx: fix legacy image building
Jo-Philipp Wich [Fri, 24 Jun 2016 11:32:22 +0000 (13:32 +0200)]
ar71xx: fix legacy image building

After the conversion from legacy device profiles to the newer profile
information embedded in the image building code, the legacy recipes got
triggered twice with different eval depths, leading to shell syntax errors
when processing certain images.

The double processing was caused by the remaining Image/Build macro in
legacy.mk which serves as main entry point for the new style image build code
in conjunction with the newly introduced LegacyDevice/* macros which caused
the legacy image build fallback code to kick in.

In order to fix the issue, rework all legacy macros to work under the legacy
image build wrapper and remove the Image/Build macro of legacy.mk to prevent
legacy profiles getting executed in the context of the new build code.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
8 years agotools: e2fsprogs: bump to 1.43.1
Kevin Darbyshire-Bryant [Wed, 22 Jun 2016 20:37:23 +0000 (21:37 +0100)]
tools: e2fsprogs: bump to 1.43.1

Bump e2fsprogs to v1.43.1 & refresh patches

Signed-off-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
8 years agoar71xx: merge profiles into image building code
John Crispin [Fri, 17 Jun 2016 04:53:22 +0000 (06:53 +0200)]
ar71xx: merge profiles into image building code

Signed-off-by: John Crispin <john@phrozen.org>
8 years agoramips: add suport for ZBT APE522II
Roger Pueyo Centelles [Thu, 23 Jun 2016 08:58:08 +0000 (10:58 +0200)]
ramips: add suport for ZBT APE522II

The ZBT APE522II is a dual-radio outdoor CPE based on the MT7620a SoC. It has
64 MB RAM, 8 MB flash, 2 Fast Ethernet ports via internal switch (one with
802.3af 48V PoE support), a 802.11b/g/n SoC 2.4 GHz radio and an 802.11a/n/ac
MT7612E-based 5 GHz radio.

Signed-off-by: Roger Pueyo Centelles <roger.pueyo@guifi.net>
8 years agomountd: update to latest git HEAD
John Crispin [Wed, 22 Jun 2016 09:52:35 +0000 (11:52 +0200)]
mountd: update to latest git HEAD

adds HFS+ support

Signed-off-by: John Crispin <john@phrozen.org>
8 years agoipq806x: enable ieee80211 phy hotplug and patch macaddress
Adrian Panella [Tue, 21 Jun 2016 16:12:26 +0000 (11:12 -0500)]
ipq806x: enable ieee80211 phy hotplug and patch macaddress

Calibration data for QCA99x0 in this device has bogus macaddress.
The data cannot be modified directly, as it breaks checksum control.
Instead change the macaddress from phy add hotplug event.

Signed-off-by: Adrian Panella <ianchi74@outlook.com>
8 years agosquashfs4: use upstream xz compression header format
Hauke Mehrtens [Tue, 21 Jun 2016 20:05:44 +0000 (22:05 +0200)]
squashfs4: use upstream xz compression header format

In the upstream kernel and the upstream squashfs4 tools the xz
compression header looks the following:
struct disk_comp_opts {
        __le32 dictionary_size;
        __le32 flags;
};

We added some other members and also moved some existing members. Place
the members which are already in upstream header at the same position
as in that kernel and add our own at the end. The kernel should not
have a problem when there are some additional members and just ignore
them.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agolantiq: fix network in failsafe
Mathias Kresin [Sun, 19 Jun 2016 14:30:55 +0000 (16:30 +0200)]
lantiq: fix network in failsafe

So far the network in failsafe is setup only for one board. Use the
eth0 interface as lan interface for all boards for now.

If a board has its lan interface(s) on another eth, a special
handling based on the board name can be added.

Signed-off-by: Mathias Kresin <dev@kresin.me>
8 years agolinux: arc: disable kernel unwinding to fix modules loading
Alexey Brodkin [Wed, 22 Jun 2016 12:47:20 +0000 (15:47 +0300)]
linux: arc: disable kernel unwinding to fix modules loading

With update of binutils for ARC (this is now based on upstream 2.26)
we noticed issues with loadable kernel modules.

Something like that was happening:
--------------------->8-------------------
mbcache: unknown relocation: 49
insmod: can't insert './mbcache.ko': invalid module format
--------------------->8-------------------

More details could be found in that discussion in binutils mailing list:
http://thread.gmane.org/gmane.comp.gnu.binutils/74662

As of now the simplest work-around is to disable in-kernel unwinder
for now. That will at least allow us to use modules again.

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Vineet Gupta <vgupta@synopsys.com>
Cc: John Crispin <john@phrozen.org>
8 years agoipq806x: Fix typo in Qualcomm device names
Sven Eckelmann [Wed, 22 Jun 2016 09:35:07 +0000 (11:35 +0200)]
ipq806x: Fix typo in Qualcomm device names

Signed-off-by: Sven Eckelmann <sven.eckelmann@open-mesh.com>
8 years agopackages: prefer http over git for git protocol
Hauke Mehrtens [Tue, 21 Jun 2016 21:52:55 +0000 (23:52 +0200)]
packages: prefer http over git for git protocol

In company networks everything except the http and https protocol is
often causes problems, because the network administrators try to block
everything else. To make it easier to use LEDE in company networks use
the https/http protocol for git access when possible.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agouboot-lantiq: Add Arcadyan ARV7506PW11 support
Mathias Kresin [Mon, 20 Jun 2016 16:47:39 +0000 (18:47 +0200)]
uboot-lantiq: Add Arcadyan ARV7506PW11 support

Signed-off-by: Mathias Kresin <dev@kresin.me>
8 years agolantiq: add support for ARV7506PW11 (Alice/O2 IAD 4421)
Oswald Buddenhagen [Mon, 20 Jun 2016 16:47:38 +0000 (18:47 +0200)]
lantiq: add support for ARV7506PW11 (Alice/O2 IAD 4421)

Ethernet, ADSL2+ and LEDs are fully functional.

Supporting the two TAE ports and SIP gateway was not attempted.

The WiFi is unreliable, due to experimental support for rt35xx family
devices by the rt2800pci driver.

Signed-off-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
[rebase to LEDE HEAD]
[switch to normal image instead of brnboot image]
[remove not required pinmux child nodes keys, leds, ebu, exin, pci_in and pci_out]
[remove switch_rst pinmux child node (no support for hw reset in driver/setting a default GPIO value in DT]
[enable usage of the wireless LED]
[fixup mac address configuration]
Sgned-off-by: Mathias Kresin <dev@kresin.me>
8 years agoar71xx: hiwifi-hc6361: lift size limit on kernel and rootfs parts
Yousong Zhou [Mon, 20 Jun 2016 14:25:50 +0000 (22:25 +0800)]
ar71xx: hiwifi-hc6361: lift size limit on kernel and rootfs parts

The patch has been run-tested and the relevant dmsg logs are as the
following

    [    0.762447] Creating 5 MTD partitions on "spi0.0":
    [    0.767217] 0x000000000000-0x000000010000 : "u-boot"
    [    0.775139] 0x000000010000-0x000000020000 : "bdinfo"
    [    0.781014] 0x000000020000-0x000000fe0000 : "firmware"
    [    0.810558] 2 uimage-fw partitions found on MTD device firmware
    [    0.815043] 0x000000020000-0x000000170000 : "kernel"
    [    0.821925] 0x000000170000-0x000000fe0000 : "rootfs"
    [    0.827587] mtd: device 4 (rootfs) set to be root filesystem
    [    0.831937] 1 squashfs-split partitions found on MTD device rootfs
    [    0.837983] 0x0000005c0000-0x000000fe0000 : "rootfs_data"
    [    0.845621] 0x000000fe0000-0x000000ff0000 : "backup"
    [    0.851445] 0x000000ff0000-0x000001000000 : "art"

While at it, convert to new build method

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
8 years agokernel: Move append-dtb to common image-commands
Ben Whitten [Fri, 17 Jun 2016 14:00:17 +0000 (15:00 +0100)]
kernel: Move append-dtb to common image-commands

This build step is used by various targets, move it to a common section.

Signed-off-by: Ben Whitten <ben.whitten@gmail.com>
8 years agolantiq: Correct ADSL race condition
Daniel Gimpelevich [Thu, 16 Jun 2016 07:18:49 +0000 (00:18 -0700)]
lantiq: Correct ADSL race condition

puts br2684ctl init after ADSL init instead of before, so that the ESI
is set at the right time, and for consistency with the PTM driver.

Signed-off-by: Daniel Gimpelevich <daniel@gimpelevich.san-francisco.ca.us>
8 years agolantiq: Slow down SPI flash on the DGN3500
Daniel Gimpelevich [Thu, 9 Jun 2016 09:12:03 +0000 (02:12 -0700)]
lantiq: Slow down SPI flash on the DGN3500

The bootloader uses 30 MHz as the SPI frequency for flash on the Germany and
North America models, and 50 MHz for it on the worldwide model, but the Lantiq
SPI driver in OpenWrt and LEDE may access the flash differently such that
writes are capped at 20 MHz, leading to read errors reported on the worldwide
model at 30 MHz.

Signed-off-by: Daniel Gimpelevich <daniel@gimpelevich.san-francisco.ca.us>
Acked-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
8 years agolantiq: remove gr7000 support
John Crispin [Tue, 21 Jun 2016 09:57:24 +0000 (11:57 +0200)]
lantiq: remove gr7000 support

this seems to have never worked as the wrong SoC is selected

Signed-off-by: John Crispin <john@phrozen.org>
8 years agoipq806x: add initial support for Netgear R7800
Pavel Kubelun [Tue, 21 Jun 2016 09:55:00 +0000 (11:55 +0200)]
ipq806x: add initial support for Netgear R7800

Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>
8 years agoipq806x: move ath10k firmware selection into device profiles
Pavel Kubelun [Tue, 21 Jun 2016 09:52:52 +0000 (11:52 +0200)]
ipq806x: move ath10k firmware selection into device profiles

Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>
8 years agoipq806x: move smb208 nodes into a regulator subnode
Pavel Kubelun [Tue, 21 Jun 2016 09:50:05 +0000 (11:50 +0200)]
ipq806x: move smb208 nodes into a regulator subnode

Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>
8 years agolantiq: make EASY80920 work with both chip versions
Hauke Mehrtens [Sat, 18 Jun 2016 22:17:39 +0000 (00:17 +0200)]
lantiq: make EASY80920 work with both chip versions

The EASY80920 is available with the A1X and the A2X chip version
depending on the board version. Add both firmware versions to device
tree and make the driver load the correct version depending on the chip
version.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agolantiq: use new partition layout for EASY80920NAND
Hauke Mehrtens [Sat, 11 Jun 2016 15:47:24 +0000 (17:47 +0200)]
lantiq: use new partition layout for EASY80920NAND

This matches the EASY80920NAND boards with UGW.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agolantiq: build fullimage.img for EASY80920NAND
Hauke Mehrtens [Sat, 11 Jun 2016 14:14:52 +0000 (16:14 +0200)]
lantiq: build fullimage.img for EASY80920NAND

This image format is used by Lantiq's / Intel's UGW version 6.1 to 7.1.
These images can be flashed onto a board with the SoC vendor boot
loader as a replacement for the vendor firmware.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agolantiq: remove patch adding support for building without reset controller
Hauke Mehrtens [Tue, 7 Jun 2016 21:10:45 +0000 (23:10 +0200)]
lantiq: remove patch adding support for building without reset controller

The lantiq kernel arch code selects CONFIG_RESET_CONTROLLER always, so
it is always selected when the lantiq target is build. we do not need
support for unselected CONFIG_RESET_CONTROLLER option.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agotools: patch-image: Added optional size option
Vishnu Swaroop Duddu [Thu, 12 May 2016 14:37:29 +0000 (20:07 +0530)]
tools: patch-image: Added optional size option

Added optional command line option for patch-image tool
Default 16KB size is still maintained as this is an optional argument.
if one wants to specify or increase size they can provide this option.
sample usage: patch-dtb <file> <dtb> [dtb max size]

Signed-off-by: Vishnu Swaroop Duddu <duddu.swaroop@intel.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 years agobrcm2708: properly detect the Raspberry Pi Zero
Álvaro Fernández Rojas [Tue, 21 Jun 2016 15:49:43 +0000 (17:49 +0200)]
brcm2708: properly detect the Raspberry Pi Zero

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
8 years agobrcm63xx: simplify block size and image offset options
Álvaro Fernández Rojas [Tue, 21 Jun 2016 12:17:02 +0000 (14:17 +0200)]
brcm63xx: simplify block size and image offset options

Instead of having CFE_EXTRAS for every device that need specific block sizes
and image offset, let's define a couple of vars which can be customized for
each device.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
8 years agobrcm63xx: add sysupgrade images
Álvaro Fernández Rojas [Tue, 21 Jun 2016 11:53:45 +0000 (13:53 +0200)]
brcm63xx: add sysupgrade images

Some devices require padded images in order to prevent CFE from flashing them
to the wrong offset.
For small flashes (4/8) this is no big deal, but for larger flashes (16/32) this
implies 8 and 16 MB images, which is way too large and some devices aren't
capable of flashing them through sysupgrade.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
8 years agolantiq: fix typo in new image generation
Ben Mulvihill [Mon, 20 Jun 2016 16:35:52 +0000 (18:35 +0200)]
lantiq: fix typo in new image generation

Fix typo in commit a6f7536a73c93794812d5e810fb41c3d0ff1fb27
(new image generation)

Signed-off-by: Ben Mulvihill <ben.mulvihill@gmail.com>
8 years agoath10k-ct: Update to latest 10.4.3 CT firmware for 9980 chipsets.
Ben Greear [Tue, 21 Jun 2016 01:12:58 +0000 (18:12 -0700)]
ath10k-ct: Update to latest 10.4.3 CT firmware for 9980 chipsets.

This works around regressions added in the 4.7 kernel.

Signed-off-by: Ben Greear <greearb@candelatech.com>
8 years agosdk: Fix keeping unset as unset
Daniel Dickinson [Tue, 10 May 2016 22:26:42 +0000 (18:26 -0400)]
sdk: Fix keeping unset as unset

The configuration preservation mechanism fails to keep items was are unset
as unset.  For busybox this causes issues when building with custom
settings in the SDK.  Therefore preserve busybox unset settings.
In addition we preserve non-package selection unset settings because
they may be important for making sure we compile and identical
package for packages that are recompiled in the SDK.

Now that SDK not longer ships .config this becomes relevant for
any use of the SDK.

Signed-off-by: Daniel Dickinson <lede@daniel.thecshore.com>
8 years agoath10k-firmware: fix board-2.bin download URL
Kevin Darbyshire-Bryant [Tue, 21 Jun 2016 09:37:49 +0000 (10:37 +0100)]
ath10k-firmware: fix board-2.bin download URL

Original URL got 303 redirect which then also dropped the commit id
leading to different file revision & MD5 mismatch.

Corrected URL & clarified commit ID use in Makefile

Signed-off-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
8 years agobrcm63xx: merge DSL-274X-F1 profiles
Jonas Gorski [Sat, 18 Jun 2016 11:38:46 +0000 (13:38 +0200)]
brcm63xx: merge DSL-274X-F1 profiles

The only difference is a field in the image tag header, so just define
two images for it instead of treating them as separate devices.

Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
8 years agobrcm63xx: move the bootargs into the dtb files
Jonas Gorski [Sat, 12 Sep 2015 19:52:43 +0000 (21:52 +0200)]
brcm63xx: move the bootargs into the dtb files

Instead of using a fixed commandline, allow one per device.

Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
8 years agobrcm63xx: use upstreamed compatible name for the periph intc
Jonas Gorski [Wed, 15 Jun 2016 10:37:33 +0000 (12:37 +0200)]
brcm63xx: use upstreamed compatible name for the periph intc

This makes the eventual migration to bmips easier, as dts files
will require less changes.

Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
8 years agobrcm63xx: fix external IRQs
Daniel Gonzalez [Mon, 11 Apr 2016 11:26:15 +0000 (13:26 +0200)]
brcm63xx: fix external IRQs

External IRQs are currently broken, fix the BCM6345_EXT_IRQ driver.

Since the adoption of the new driver irq-bcm6345-ext, in Chaos Calmer,
external IRQs don't work. It seems there were some minor errors at the initial
development of the driver.

This patch fixes the ticket https://dev.openwrt.org/ticket/21613

Signed-off-by: Daniel Gonzalez <dgcbueu@gmail.com>
Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
8 years agobrcm63xx: fix single profile selection
Álvaro Fernández Rojas [Fri, 17 Jun 2016 08:13:02 +0000 (10:13 +0200)]
brcm63xx: fix single profile selection

Fixes commit c6990347.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
8 years agobcm53xx: backport BCM5301X patches for SRAB
Rafał Miłecki [Mon, 20 Jun 2016 20:57:09 +0000 (22:57 +0200)]
bcm53xx: backport BCM5301X patches for SRAB

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
8 years agokernel: backport bgmac changes from net-next
Rafał Miłecki [Mon, 20 Jun 2016 20:38:01 +0000 (22:38 +0200)]
kernel: backport bgmac changes from net-next

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
8 years agokernel: rename bgmac patches that went into the same kernel
Rafał Miłecki [Mon, 20 Jun 2016 20:29:14 +0000 (22:29 +0200)]
kernel: rename bgmac patches that went into the same kernel

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
8 years agoprocd: properly set /dev/snd permission and group
John Crispin [Thu, 16 Jun 2016 09:52:29 +0000 (11:52 +0200)]
procd: properly set /dev/snd permission and group

Signed-off-by: John Crispin <john@phrozen.org>
8 years agoe2fsprogs: Bump to v1.43.1
Xotic750 [Wed, 15 Jun 2016 22:38:57 +0000 (00:38 +0200)]
e2fsprogs: Bump to v1.43.1

Signed-off-by: Graham Fairweather <xotic750@gmail.com>
8 years agoramips: remove duplicate i2c dts info
Michael Lee [Sat, 18 Jun 2016 02:55:04 +0000 (10:55 +0800)]
ramips: remove duplicate i2c dts info

Signed-off-by: Michael Lee <igvtee@gmail.com>
8 years agoramips: update i2c drivers
Michael Lee [Thu, 7 Jan 2016 13:50:24 +0000 (21:50 +0800)]
ramips: update i2c drivers

* add rt_i2c structure to store driver data
* rewrite read/write check function and add i2c error status check.
  so we don't need to wait until time out.
* add 10 bits address support. according to the data sheet i think
  it is possible. but i haven't verify it.
* the most important is start transfer only need once. otherwise
  it cause I2C_STARTERR status.
* add set i2c clock speed register by dts options "clock-frequency".
  not just hard code it.
* add mt7621 i2c driver. i just copy i2c-ralink.c and change register
  names. and the hardware don't support error status. so i remove it.
  but the logic is the same.

Signed-off-by: Michael Lee <igvtee@gmail.com>
8 years agoipq806x: fix MAC_POWER_SEL switch configuration
Josh Bendavid [Sat, 18 Jun 2016 09:50:29 +0000 (11:50 +0200)]
ipq806x: fix MAC_POWER_SEL switch configuration

Fixes instability/corruption on the ethernet interface connected to port0 on the switch.

Signed-off-by: Josh Bendavid <joshbendavid@gmail.com>