Commit Graph

1296 Commits

Author SHA1 Message Date
Paul Spooren
f20e414b79
build: refactor JSON info files to profiles.json
JSON info files contain machine readable information of built profiles
and resulting images. These files were added in commit 881ed09ee6
("build: create JSON files containing image info").

They are useful for firmware wizards and script checking for
reproducibility.

Currently all JSON files are stored next to the built images, resulting
in up to 168 individual files for the ath79/generic target.

This patch refactors the JSON creation to store individual per image
(not per profile) files in $(BUILD_DIR)/json_info_files and create an
single overview file called `profiles.json` in the target directory.

Storing per image files and not per profile solves the problem of
parallel file writes. If a profiles sysupgrade and factory image are
finished at the same time both processes would write to the same JSON
file, resulting in randomly broken outputs.

Some target like x86/64 do not use the image code yet, resulting in
missing JSON files. If no JSON info files were created, no
`profiles.json` files is created as it would be empty anyway.

As before, this creation is enabled by default only if `BUILDBOT` is set.

Tested via buildroot & ImageBuilder on ath79/generic, imx6 and x86/64.

Signed-off-by: Paul Spooren <mail@aparcar.org>
[json_info_files dir handling in Make, if case refactoring]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
2020-11-14 23:29:53 +08:00
CN_SZTL
5184fe54e8
kernel: bump to 4.9.243, 4.14.206, 4.19.157
Resolve conflicted:
 - generic/backport-4.19/714-v5.3-net-sfp-Stop-SFP-polling-and-interrupt-handling-duri.patch

Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-11-14 17:43:10 +08:00
Felix Fietkau
68f5817924
build: filter out more autogenerated kernel config options
Define wildcard patterns for filtering in target/linux/generic/config-filter
Preparation for supporting newer kernels

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2020-11-14 13:52:03 +08:00
Thibaut VARÈNE
341983f234
generic: platform/mikrotik: implement multi caldata
MikroTik recently changed again the way they store wlan calibration data
on devices. Prior to this change, ERD calibration data for all available
radios was stored within a single identifier node ("tag" in RouterBoot
parlance).

Recent devices have been seen with calibration (and BDF) data stored in
separate identifiers within LZOR packing for each radio: this patch
addresses this by:
1) ensuring that both variants are properly supported,
2) preserving backward compatibility with existing data consumers,
3) allowing for more than 2 calibration blobs to be exposed via sysfs.

Specifically, before this patch, the driver would provide a single sysfs
file named /sys/firmware/mikrotik/hard_config/wlan_data that contained
whatever calibration data found on the device's flash. After this patch,
when executed on a device that uses the old style storage, this behavior
is unchanged, but when executed on a device that uses new style storage
(for either traditional "ERD" packing or "LZOR" packing), the driver
replaces that single file with a folder containing one or more files
each containing the data encoded within individual identifiers.

As far as OpenWRT is concerned, this means that for devices which are
known to exist with both styles of data storage, a suitable hotplug stub
could look like this for e.g. the second radio:

wdata="/sys/firmware/mikrotik/hard_config/wlan_data"
( [ -f "$wdata" ] && caldata_sysfsload_from_file "$wdata" 0x8000 0x2f20 ) || \
( [ -d "$wdata" ] && caldata_sysfsload_from_file "$wdata/data_2" 0x0 0x2f20 )

This patch has been tested with LZOR old and new style packing on ipq4019,
and with old style on ath79.

Tested-by: John Thomson <git@johnthomson.fastmail.com.au>
Tested-by: Шебанов Алексей <admin@ublaze.ru>
Tested-by: Alen Opačić <subixonfire@gmail.com>
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
Tested-by: Robert Marko <robimarko@gmail.com>
2020-11-14 13:47:42 +08:00
Alberto Bursi
612919afca
x86: generic: disable CONFIG_EFI_VARS
CONFIG_EFI_VARS has been disabled in
64bit x86 target in 2018 by the following commit
b0a51dab8c
the same reasons apply to Generic target, so
now it's disabled here too.
Leaving it enabled is also blocking compile as
a new symbol was added
EFI_CUSTOM_SSDT_OVERLAYS
that depends from CONFIG_EFI_VARS
and the build system stops and waits for
user input on what to do about it.

The Legacy and Geode targets never
had any EFI_xxx configs enabled so they
don't have this issue

Signed-off-by: Alberto Bursi <bobafetthotmail@gmail.com>
2020-11-14 13:45:12 +08:00
CN_SZTL
6e6805917e
linux: refresh shortcut-fe patches 2020-11-14 01:54:33 +08:00
quarkysg
77a15e9d59
shortcut-fe: rework netfilter conntrack notification
The original patch from QCA over rode the nf_conntrack_un/register_notifier API, which
will break other modules relying on the API.  Reworked the notification APIs to play nice
with others.
2020-11-14 01:39:39 +08:00
AmadeusGhost
df12850680
ipq807x: remove yet supported platforms 2020-11-14 01:26:47 +08:00
CN_SZTL
633f8c6e59
autocore-arm: add support for mvebu 2020-11-13 19:46:58 +08:00
Paul Spooren
883dba35b5
imagebuilder: fix sstrip
Without an absolute path to staging_dir/host/bin/sstrip the Makefile
tries to run a host installed version of sstrip, which is likely not
available.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-11-12 11:12:14 +08:00
David Bauer
edd4928df2
ramips: fix logic level for DIR-645 buttons
The D-Link DIR-645 currently uses an incorrect logic level for its
buttons.

Correct them in order to prevent unintentional activation of failsafe
mode.

Reported-by: Perry Melange <isprotejesvalkata@gmail.com>
Signed-off-by: David Bauer <mail@david-bauer.net>
(cherry picked from commit 929e8f0f55)
2020-11-12 10:54:56 +08:00
Adrian Schmutzler
7bbeeba265
ath79: fix LED labels for PowerCloud CAP324
The order of function and color in the labels in inverted for the
LAN LEDs. Fix it.

Fixes: 915966d861 ("ath79: Port PowerCloud Systems CAP324 support")

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
(cherry picked from commit 96023cd4ba)
2020-11-12 10:54:22 +08:00
CN_SZTL
488fa50d9f
kernel: bump 4.19 to 4.19.155
Resolve conflicted:
 - bcm27xx/950-0609-xhci-add-quirk-for-host-controllers-that-don-t-updat.patch
 - bcm53xx/180-usb-xhci-add-support-for-performing-fake-doorbell.patch

Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-11-08 03:24:12 +08:00
CN_SZTL
013dae6201
kernel: bump 4.14 to 4.14.204
Resovle conflicted:
 - layerscape/708-mc-bus-support-layerscape.patch

Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-11-08 02:26:20 +08:00
CN_SZTL
75ea28ec81
treewide: enable openssh-sftp-server for some targets 2020-11-08 01:51:42 +08:00
Petr Štetiar
c1eef0d8f4 sdk: fix missing include directories
It's not possible to compile some applications which are using
`-Werror=missing-include-dirs` compiler flags with the SDK as some
target directories are missing in the SDK tarball:

 cc1: error: staging_dir/target/usr/include: No such file or directory [-Werror=missing-include-dirs]
 cc1: error: staging_dir/target/include: No such file or directory [-Werror=missing-include-dirs]

Fix this by adding the missing directories in the SDK.

Signed-off-by: Petr Štetiar <ynezz@true.cz>
2020-11-03 11:54:13 +08:00
AmadeusGhost
f39e4b370b ar71xx: add support for Lute ZK400
Hardware Highlights:
- SoC: Qualcomm Atheros AR9531 (650MHz)
- RAM: 128 MB
- Flash: 16 MB SPI NOR
- Ethernet: 10/100: 1x WAN, 4x LAN
- Wireless: QCA9531 2.4GHz (bgn)
- Button: 1x reset button
- LED: SYS, WAN, Wireless, LAN 1~4

Installation:
 Configure PC with static IP 192.168.1.x, connect PC with one of RJ45
 ports, press the reset button and power up device. Open 192.168.1.1
 address in your browser and upload sysupgrade image.

Signed-off-by: AmadeusGhost <amadeus@jmu.edu.cn>
2020-11-01 11:50:37 +08:00
AmadeusGhost
22490ac69c ar71xx: build error fixes
Fixes: 207049c82f "kernel: bump 4.9 to 4.9.211"
2020-11-01 11:39:19 +08:00
Paul Spooren
5af7ce9b0b build,IB: reload packages/ only if existing
With the fix of external kmod feeds it is possible to ship the
ImageBuilder without any packages except the pseudo packages kernel and
libc. Therefore the local package feeds becomes optional.

This commit adds a check to the package_reload function to only run if
the local feed is existing.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-10-31 10:26:05 +08:00
Paul Spooren
6dd0a51520 build,IB: include kmods only in local builds
The buildbots generate a kmod archive which should be used instead of a
local copy. This is possible due to the introduction of a kernelversion
specific feed.

This commit adds the ability of using only signed package feeds.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-10-31 10:25:45 +08:00
CN_SZTL
e0aceee93a
kernel: bump to 4.14.203, 4.19.154
Resolve conflicted:
 - 210-dwc2_defaults.patch

Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-10-31 01:29:00 +08:00
CN_SZTL
acb3981c38
kernel: bump 4.9 to 4.9.241
Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-10-29 23:07:32 +08:00
Thibaut VARÈNE
ad8c4d3e8d
ar71xx: mikrotik: bypass id check in __rb_get_wlan_data()
The id parameter in __rb_get_wlan_data() was incorrectly used on the
assumption that id "0" would always be tied to ath9k with RLE encoding
and positive id (in fact, only id "1" was valid) would always be tied to
("external") ath10k with LZO encoding.

Newer hardware revisions of supported devices prove this assumption to
be invalid, with ath9k caldata being now wrapped in MAGIC_ERD and LZO
compressed, so disable this check to allow newer hardware to correctly
decode caldata for ath9k.

Note: this patch assumes that ath9k caldata is never stored with the new
"LZOR" encoding scheme found on some ath10k devices.

Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
(cherry picked from commit 1c6990fe6d)
[keep publishing ath10k caldata in sysfs: it's the way it's done on 18.06]
Signed-off-by: Baptiste Jonglez <git@bitsofnetworks.org>
Tested-by: Baptiste Jonglez <git@bitsofnetworks.org> [Mikrotik RB941-2nD r3]
2020-10-23 17:47:04 +08:00
CN_SZTL
aba9592e41
sunxi: rework nanopi r1s (h5) compilation for kernel 4.14
Known issues:
 - Wireless not working

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-10-18 00:36:02 +08:00
CN_SZTL
733a58b7ee
kernel: bump to 4.9.240, 4.14.202, 4.19.152
Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-10-17 19:46:46 +08:00
Chuanhong Guo
566f57591d
ath79: ar8216: make switch register access atomic
reg accesses on integrated ar8229 sometimes fails. As a result, phy read
got incorrect port status and wan link goes down and up mysteriously.
After comparing ar8216 with the old driver, these local_irq_save/restore
calls are the only meaningful differences I could find and it does fix
the issue.
The same changes were added in svn r26856 by Gabor Juhos:
ar71xx: ag71xx: make switch register access atomic

As I can't find the underlying problem either, this hack is broght
back to fix the unstable link issue.
This hack is only suitable for ath79 mdio and may easily break the
driver on other platform. Limit it to ath79-only as a target patch.

Fixes: FS#2216
Fixes: FS#3226
Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
(cherry picked from commit 86fdc8abed)
2020-10-17 18:38:35 +08:00
Adrian Schmutzler
b28722be0b
oxnas: fix qc_prep return in sata driver after kernel 4.14.200
This fixes a regression after a kernel change in 4.14.200 [1] that
led to build failure on oxnas/ox820:

  drivers/ata/sata_oxnas.c:2238:13: error: initialization of
  'enum ata_completion_errors (*)(struct ata_queued_cmd *)'
  from incompatible pointer type
  'void (*)(struct ata_queued_cmd *)' [-Werror=incompatible-pointer-types]
    .qc_prep = sata_oxnas_qc_prep,
               ^~~~~~~~~~~~~~~~~~
  drivers/ata/sata_oxnas.c:2238:13: note:
  (near initialization for 'sata_oxnas_ops.qc_prep')

Our local driver is changed the same way as prototyped in the
kernel patch, i.e. return type is changed and AC_ERR_OK return
value is added.

[1] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=306a1c5b5683c1d37565e575386139a64bdbec6f

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
(cherry picked from commit f6ca57e4f4)
2020-10-17 18:37:26 +08:00
Thomas Albers
5f00c3dc56 linux/generic: remove obsolete config option LEDS_TRIGGER_IDE_DISK
Kernel config option LEDS_TRIGGER_IDE_DISK was renamed in kernel 4.8 to
CONFIG_LEDS_TRIGGER_DISK in upstream commit eb25cb9956cc ("leds: convert
IDE trigger to common disk trigger").

Removing it as it should be added only on targets which has usage for
this trigger.

Signed-off-by: Thomas Albers <thomas.gameiro@googlemail.com>
[commit description facelift]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
2020-10-13 18:37:58 +08:00
Adrian Schmutzler
b69fb2bf2f ath79: fix rssi-low LED for My Net Range Extender
The LED color was missing in 01_leds.

Fixes: 745dee11ac ("ath79: add support for WD My Net Wi-Fi Range
Extender")

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-10-12 17:31:04 +08:00
CN_SZTL
3988c2ef29
x86: apply MMC config to kernel 4.9 2020-10-07 03:06:34 +08:00
Jeff Collins
e966db7fee
x86: Fix when booting from internal MMC. 2020-10-06 00:03:14 +08:00
LGA1150
84bfad692c
build: enable ccache by default 2020-10-04 21:45:07 +08:00
CN_SZTL
0a7b738e09
kernel: bump 4.9 to 4.9.238
Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-10-03 01:14:39 +08:00
CN_SZTL
21e29cc2df
kernel: bump 4.19 to 4.19.149
Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-10-01 21:53:50 +08:00
CN_SZTL
8fe562e7e3
kernel: bump 4.14 to 4.14.200
Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-10-01 21:53:20 +08:00
CN_SZTL
fc101d4c5f
kernel: bump 4.19 to 4.19.148
Remove upstreamed:
- generic/pending: 607-tcp_bbr-adapt-cwnd-based-on-ack-aggregation-estimation.patch

Resolve conflicted:
- generic/backport: 011-kbuild-export-SUBARCH.patch

Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-09-30 21:08:22 +08:00
CN_SZTL
e4574017c2
kernel: bump 4.14 to 4.14.199
Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-09-30 20:09:04 +08:00
CN_SZTL
b99cee288f
kernel: bump 4.9 to 4.9.237
Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-09-30 20:08:29 +08:00
Paul Spooren
038a832abe imagebuilder: add missing libfakeroot files
The `libfakeroot` files are currently missing in the ImageBuilder. As
`fakeroot` is always built, copy those files unconditionally.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-09-29 11:29:57 +08:00
AmadeusGhost
d7d9d6e504 ipq40xx: add support for Century WR142AC
This commit add support for the yyets_le router.

Hardware Highlights:

SoC:	  Qualcomm IPQ4019 717 MHz
RAM:	  512M NT5CC256M16ER-EK
Flash:    32M SPI NOR MX25L25635F
WIFI1:    2.4 GHz 2T2R integrated
WIFI2:    5 GHz 2T2R integrated
Ethernet: Qualcomm QCA8075 (4x LAN, 1x WAN)
USB:      1x 3.0
LEDS:     power, wlan2g, wlan5g, usb
Button:   Reset

Installation:
 Upload the firmware on the upgrade page of the stcok, and this will take a few minutes.

This commit also supports the addition of a 128M nand flash version,
just use the P&W R619AC's opboot to overwrite the original uboot.

Signed-off-by: AmadeusGhost <amadeus@jmu.edu.cn>
2020-09-28 15:54:24 +08:00
Chen Minqiang
a66bea8539 ramips: thunder_timecloud support sdcard 2020-09-28 11:35:13 +08:00
Christian Lamparter
5cc4a3de81 ipq40xx: fix DTS warning in qcom-ipq4029-gl-s1300.dts
.dts:226.17-230.4: Warning (spi_bus_reg): /soc/spi@78b6000/spi@1:
	SPI bus unit address format error, expected "0"

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
2020-09-26 11:38:40 +08:00
Christian Lamparter
df3e28c485 build: define PWM_SUPPORT arch feature flag
As the PWM has its own sub-system in the Linux kernel,
I think it should be handled in the same way as GPIO, RTC, PCI...

This patch introduces a specific feature flag "pwm" and the
"leds-pwm" kernel module as the first customer.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
2020-09-26 11:34:00 +08:00
Jo-Philipp Wich
759b1497ca
Revert "ramips: ethernet: fix to interrupt handling"
This reverts commit 7ac454014a.

The change reportedly causes regressions in ethernet performance.

Fixes: FS#3332
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-09-24 23:23:41 +08:00
Sungbo Eo
50a054a3a1 build: image: move IMAGE_SIZE to image.mk
IMAGE_SIZE is widely used in many targets. Declare it in the default template to
clean up redundant code. This also prevents deriving IMAGE_SIZE unintentionally
from the previously defined device.

While at it, remove duplicate KERNEL_SIZE declaration.

Signed-off-by: Sungbo Eo <mans0n@gorani.run>
2020-09-21 20:00:35 +08:00
Chen Minqiang
46c05bf04b
ramips: youku_yk-l2 add support sdcard 2020-09-19 19:15:19 +08:00
Adrian Schmutzler
7709df69e9 treewide: remove empty default cases
There is no apparent reason to have an empty default case.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-09-18 16:37:37 +08:00
AmadeusGhost
1e4accd9bd ipq40xx: sync upstream source code 2020-09-16 11:38:38 +08:00
CN_SZTL
1ecb19072b
kernel: bump 4.19 to 4.19.145
Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-09-12 23:08:12 +08:00
CN_SZTL
8588e8694a
kernel: bump 4.14 to 4.14.198
Refreshed all patches.

Signed-off-by: CN_SZTL <cnsztl@project-openwrt.eu.org>
2020-09-12 23:07:39 +08:00