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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
* 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>
The restart event code is used in LEDE to trigger a factory reset on
long press as well.
By using the power event code, the restart functionality can be used
without being prone to trigger a factory reset.
Signed-off-by: Mathias Kresin <dev@kresin.me>
This patch is a follow up to commit 4cf3fd4 "add support for indicating
the boot state using three leds".
At the time of writing the patch, I wasn't aware that it's possible to
switch info failsafe after boot (factory reset).
Enabling the failsafe led without disabling the running led causes an
unexpected led colour on devices using a single multicolour led to
indicate the boot state.
Signed-off-by: Mathias Kresin <dev@kresin.me>
The *_UBIFS_OPTS variables need to be prefixed with DEVICE_ to match
the profile name.
The conditions need to be evaluated after the *_UBIFS_OPTS are set,
otherwise the variables are always empty.
Do not append or pass the DEVICE_ prefixed profile name to the images.
Use the name that is passed by the Image/Build/Profile/ step.
Signed-off-by: Mathias Kresin <dev@kresin.me>
In kernel 4.7 there is upstreamed b53 driver using (mostly?) the same
symbols as our b53 does. Change our symbols so both drivers can coexist
in kernel tree.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Acked-by: Jonas Gorski <jonas.gorski@gmail.com>
So far "kernel" partition didn't contain just a kernel. It also included
Seama header and meta data. This was making kernel update complex and it
wasn't trivial to read kernel size.
Fix it by making "kernel" parition contain just a kernel image.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Despite the MS_SILENT flag being set when probing for ubifs rootfs a
logline indicating an error is generated during boot:
UBIFS error (pid: 1): cannot open "ubi0:rootfs", error -19
This leads to confusion and there shouldn't be lines containing
the word 'error' twice in a bootlog if actually everything is fine
(just the rootfs happens to be something else than ubifs)
The patch added has been submitted and was accepted upstream, see:
http://lists.infradead.org/pipermail/linux-mtd/2016-June/068056.htmlhttp://patchwork.ozlabs.org/patch/637491
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
The generic sysupgrade image attempted to use the wrong filesystem type due
to premature variable interpolation leading to the following error on the
buildbot system:
cp: cannot stat `.../root.squashfs': No such file or directory
make[4]: *** [.../tmp/lede-octeon-generic-ext4-sysupgrade.tar] Error 1
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Reordered the VLANs so the LAN ports are set to VLAN 1 and the WAN port is set to VLAN 2, as in the other routers in the config file. Moreover, this model had this VLAN mapping in OpenWRT Chaos Calmer. It seems that the VLAN were switched when fixing a bug in the port mapping ( OpenWRT changeset 47799 )
Signed-off-by: David Pinilla Caparrós <dpinitux@gmail.com>
The command-line arguments provided by the boot loader will be
appended to a new device tree property: bootloader-args.
If there is a property "append-rootblock" in DT under /chosen
and a root= option in bootloaders command line it will be parsed
and added to DT bootargs with the form: <append-rootblock>XX.
Only command line ATAG will be processed, the rest of the ATAGs
sent by bootloader will be ignored.
This is usefull in dual boot systems, to get the current root partition
without afecting the rest of the system.
Signed-off-by: Adrian Panella <ianchi74@outlook.com>
Already reschedule when 1 or more frames came in.
Checking for a full queue could produce a re-schedule loop as
the checked RX ring location could contain undefined values
depending on activity in previous loops.
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
This can be used to prevent double compression for platforms where the
boot loader already expects compressed images.
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Cisco RV0XX u-boot sets MEM=2048 as boot param. We assume that at least
4MB (mem_alloc_size) of ram is needed to run linux on cavium boards, so
if mem < 4M - ignore it and set default value
Signed-off-by: Michał Osowiecki <michal.osowiecki@gmail.com>
This reverts commit 53147c2237.
These config changes break booting on C2600 and probably other devices.
Signed-off-by: Josh Bendavid <joshbendavid@gmail.com>
Commit 9ff8928bb9 renamed the snd-soc-mt7620-i2s
driver and dropped snd-soc-mt7620-wm8960 which selected CONFIG_SND_SOC_WM8960
breaking all ramips builds due to undefined kernel config symbols.
Rework the kmod-sound-mt7620 package to explicitely select the
CONFIG_SND_SOC_WM8960 symbols and change it to bundle the renamed .ko file.
Also remove the @BROKEN flag and exclude it on the rt288x subtarget instead.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
DuZun DM06 is a develop board based on mt7628
64M RAM, 8M SPI Flash, 1 WAN, 1 LAN.
wm8960 codec with line out, line in and speaker output.
Signed-off-by: Michael Lee <igvtee@gmail.com>
* remove mt7620-wm8960.c use simple card and DTS to do it
* add old chips support
* add 12Mhz refclk setup. this is hard code. need use clock framework
rewrite it
* add interrupt error status support for debug. default disable it.
because it cause to many interrupts
* add setup bclk suport not hard code it
* add 24 bits support for mt7628. not verified
* use regmap api to control registers
* add txdma-req/rxdma-req DTS params for DMA use
Signed-off-by: Michael Lee <igvtee@gmail.com>
* 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>
* fix compiler error. device_control operation not support now.
* add old chips support 8 channels. new chips support 16 channels.
* add mt7621 hsdma driver. data sheet says it has two channels.
but after test only one channel support.
* add memory to memory DMA support. i use dmatest kernel module to
verify this function. on rt305x it will copy more data. on mt7621
only two channels can works at the same time. these two chips
maybe have hardware bugs. because on other chips don't have these bugs.
* use tasklet to handle remaining dma requests.
Signed-off-by: Michael Lee <igvtee@gmail.com>
In commit "regulator: qcom: Rework to single platform device" the smb208
regulator used in IPQ8064 was left out.
Add it to that new framework and update Docs and DT accordingly.
Signed-off-by: Adrian Panella <ianchi74@outlook.com>
this worked in 3.18 but broke at some point. the old code that loaded a
irq table was incorrewct anyhow as it mapped the irqs int he domain which
should really be done when the driver using them loads them and not the
irq driver itself.
Signed-off-by: John Crispin <john@phrozen.org>
The swconfig kernel infrastructure fails to do any permissions checks when
changing settings. As such an ordinary user account on a device with a
switch can change switch settings without any special permissions.
Routers generally have few non-admin users so this isn't a big hole, but it
is a security hole. Likely the greatest danger is for multifunction devices
which have a lot of extra daemons, compromising a low-security daemon would
allow one to modify switch settings and cause the router/switch to appear to
lock-up (or cause other sorts of troublesome nyetwork behavior).
Implement a check for CAP_NET_ADMIN in swconfig_set_attr() and deny any
requests originating from user contexts lacking this capability.
Reported-by: Elliott Mitchell <ehem+openwrt@m5p.com>
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
kmod-sound-soc-digidac1-soundcard is also missing snd-soc-wm8804 dependency
for snd-soc-wm8804-i2c
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
As usual these patches were extracted from the raspberry pi repo:
https://github.com/raspberrypi/linux/tree/rpi-4.4.y
Also alphabetically order sound-soc kernel packages.
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
- Use KERNEL_INITRAMFS_SUFFIX for customizing initramfs name.
- Modifying $(PROFILES) is no longer needed.
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
Now that deviations to the default /etc/config/system are registered via
board.d we can drop the target specific copy.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Now that deviations to the default /etc/config/system are registered via
board.d we can drop the target specific copy.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
The system config file shipped by ath25 is now equivalent to the generic one
in base files, so drop the target specific copy.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
The ath25 target has its own unique button action config support, which is not
used anywhere except for two example logger statements in UCI.
Since there is a generic /etc/rc.button facility since some time already there
is no reason at all to keep this target specific mechanism anymore, so simply
drop it.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
This patch adds the target profile SOM9331 and configures hardware
functionality for the 3x Eth Ports & corresponding LED's, the USB Host,
the USART to USB bridge and the System LED.
Signed-off-by: Allan Nick Pedrana <nik9993@gmail.com>
Upstream dropped the `dapm` member of `struct snd_soc_component`, requiring
users to access it using `snd_soc_codec_get_dapm()` instead so change the
driver code to do just that.
Fixes the following build error spotted by the buildbots:
CC [M] sound/soc/gw-avila/gw-avila.o
sound/soc/gw-avila/gw-avila.c: In function 'avila_aic3x_init':
sound/soc/gw-avila/gw-avila.c:104:44: error: 'struct snd_soc_codec' has no member named 'dapm'
Signed-off-by: Jo-Philipp Wich <jo@mein.io>