mirror of
https://github.com/padavanonly/immortalwrt-mt798x.git
synced 2025-12-16 16:56:38 +00:00
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
This commit is contained in:
commit
60710e8cc3
@ -43,7 +43,9 @@ else
|
||||
rmdir $(LINUX_DIR); \
|
||||
fi
|
||||
ln -s $(CONFIG_EXTERNAL_KERNEL_TREE) $(LINUX_DIR)
|
||||
$(_SINGLE) [ -d $(LINUX_DIR)/user_headers ] && rm -rf $(LINUX_DIR)/user_headers
|
||||
if [ -d $(LINUX_DIR)/user_headers ]; then \
|
||||
rm -rf $(LINUX_DIR)/user_headers; \
|
||||
fi
|
||||
endef
|
||||
endif
|
||||
|
||||
|
||||
@ -91,21 +91,28 @@ generate_static_network() {
|
||||
|
||||
addr_offset=2
|
||||
generate_network() {
|
||||
local ifname macaddr protocol type ipaddr netmask vlan
|
||||
local ports ifname macaddr protocol type ipaddr netmask vlan
|
||||
local bridge=$2
|
||||
|
||||
json_select network
|
||||
json_select "$1"
|
||||
json_get_values ports ports
|
||||
json_get_vars ifname macaddr protocol ipaddr netmask vlan
|
||||
json_select ..
|
||||
json_select ..
|
||||
|
||||
[ -n "$ifname" ] || return
|
||||
[ -n "$ifname" -o -n "$ports" ] || return
|
||||
|
||||
# force bridge for multi-interface devices (and lan)
|
||||
case "$1:$ifname" in
|
||||
*\ * | lan:*) type="bridge" ;;
|
||||
esac
|
||||
# Force bridge for "lan" as it may have other devices (e.g. wireless)
|
||||
# bridged
|
||||
[ "$1" = "lan" -a -z "$ports" ] && {
|
||||
ports="$ifname"
|
||||
}
|
||||
|
||||
[ -n "$ports" ] && {
|
||||
type="bridge"
|
||||
ifname="$ports"
|
||||
}
|
||||
|
||||
[ -n "$bridge" ] && {
|
||||
if [ -z "$vlan" ]; then
|
||||
|
||||
@ -39,7 +39,13 @@ ucidef_set_interface() {
|
||||
|
||||
[ -n "$opt" -a -n "$val" ] || break
|
||||
|
||||
json_add_string "$opt" "$val"
|
||||
[ "$opt" = "ifname" -a "$val" != "${val/ //}" ] && {
|
||||
json_select_array "ports"
|
||||
for e in $val; do json_add_string "" "$e"; done
|
||||
json_close_array
|
||||
} || {
|
||||
json_add_string "$opt" "$val"
|
||||
}
|
||||
done
|
||||
|
||||
if ! json_is_a protocol string; then
|
||||
|
||||
@ -18,6 +18,8 @@ PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-3.$(PKG_VERSION).$(PKG_RELEASE)
|
||||
|
||||
PKG_LICENSE_FILE:=LICENSE.amd-ucode
|
||||
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/amd64-microcode
|
||||
|
||||
@ -18,6 +18,8 @@ PKG_SOURCE_URL:=https://github.com/openwrt/cypress-nvram.git
|
||||
|
||||
PKG_MAINTAINER:=Álvaro Fernández Rojas <noltari@gmail.com>
|
||||
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/cypress-nvram-default
|
||||
|
||||
@ -24,6 +24,8 @@ else
|
||||
MICROCODE:="intel-microcode"
|
||||
endif
|
||||
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/intel-microcode
|
||||
|
||||
@ -16,6 +16,8 @@ PKG_SOURCE_URL:=https://github.com/NXP/qoriq-fm-ucode.git
|
||||
PKG_SOURCE_VERSION:=c275e91392e2adab1ed22f3867b8269ca3c54014
|
||||
PKG_MIRROR_HASH:=90b619ed501462b92f34f2fabfa09d6aaa5235990891d1c3132821c7d18a39bd
|
||||
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/layerscape-fman
|
||||
|
||||
@ -18,6 +18,8 @@ PKG_BUILD_DEPENDS:=tfa-layerscape/host
|
||||
PKG_LICENSE:=EULA
|
||||
PKG_LICENSE_FILES:=NXP-Binary-EULA.txt
|
||||
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/layerscape-ddr-phy
|
||||
|
||||
@ -16,6 +16,8 @@ PKG_SOURCE_URL:=https://source.codeaurora.org/external/qoriq/qoriq-components/mc
|
||||
PKG_SOURCE_VERSION:=8672a5f5abcd3a354dcab07e03f2a8a69b2e962d
|
||||
PKG_MIRROR_HASH:=4b8ad3148aee1e0c034206543472aebb435655fd03a661c4c1be545dcac7ddf0
|
||||
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
include $(INCLUDE_DIR)/kernel.mk
|
||||
|
||||
|
||||
@ -16,6 +16,8 @@ PKG_SOURCE_URL:=https://github.com/NXP/qoriq-mc-binary.git
|
||||
PKG_SOURCE_VERSION:=f73683596a7b72124d67b62e64f3dc2bb36b9321
|
||||
PKG_MIRROR_HASH:=1cba30c2a6814763c3e155c1cc5fa21998bb6ad5814fcb09e99f98bf36f65d9e
|
||||
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/layerscape-mc
|
||||
|
||||
@ -16,6 +16,8 @@ PKG_SOURCE_URL:=https://source.codeaurora.org/external/qoriq/qoriq-components/rc
|
||||
PKG_SOURCE_VERSION:=e0fab6d9b61003caef577f7474c2fac61e6ba2ff
|
||||
PKG_MIRROR_HASH:=b6bc66e27b7c6db31101fdc2e6be7255181861bd38d8f25eb5eb80c468983eb2
|
||||
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/layerscape-rcw
|
||||
|
||||
@ -16,6 +16,8 @@ PKG_SOURCE_URL:=https://github.com/NXP/qoriq-engine-pfe-bin.git
|
||||
PKG_SOURCE_VERSION:=d3a8ef0760c54ddc243039c86389497e37be90ab
|
||||
PKG_MIRROR_HASH:=64be93b8249d298e7b5fd0846787835f0659b6ab6c55b40b809366c79e272eb8
|
||||
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
RSTRIP:=:
|
||||
|
||||
@ -16,6 +16,8 @@ PKG_SOURCE_URL:=https://source.codeaurora.org/external/qoriq/qoriq-components/re
|
||||
PKG_SOURCE_VERSION:=f0cec094e4c6d1c975b377203a3bf994ba9325a9
|
||||
PKG_MIRROR_HASH:=1863acfaef319e6b277671fead51df0a31bdddb59022080d86b7d81da0bc8490
|
||||
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/restool
|
||||
|
||||
@ -20,6 +20,8 @@ PKG_BUILD_DEPENDS:=USE_UCLIBC:argp-standalone USE_MUSL:argp-standalone
|
||||
PKG_MAINTAINER:=Zoltan HERPAI <wigyori@uid0.hu>
|
||||
PKG_LICENSE:=GPL-2.0
|
||||
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
PKG_INSTALL:=1
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
@ -5,6 +5,8 @@ include $(TOPDIR)/rules.mk
|
||||
PKG_NAME:=bcm4908img
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
PKG_BUILD_DEPENDS := bcm4908img/host
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
@ -1,34 +0,0 @@
|
||||
From cf0d2fbaae9e962d91a321de75e0d4f9f9ccbdfe Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?=C3=81lvaro=20Fern=C3=A1ndez=20Rojas?= <noltari@gmail.com>
|
||||
Date: Thu, 21 Jan 2021 18:17:37 +0100
|
||||
Subject: [PATCH] nand: brcmnand: fix OOB R/W with Hamming ECC
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Hamming ECC doesn't cover the OOB data, so reading or writing OOB shall
|
||||
always be done without ECC enabled.
|
||||
This is a problem when adding JFFS2 cleanmarkers to erased blocks. When JFFS2
|
||||
clenmarkers are added to the OOB with ECC enabled, OOB bytes will be changed
|
||||
from ff ff ff to 00 00 00, reporting incorrect ECC errors.
|
||||
|
||||
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
|
||||
---
|
||||
drivers/mtd/nand/raw/brcmnand/brcmnand.c | 6 ++++++
|
||||
1 file changed, 6 insertions(+)
|
||||
|
||||
--- a/drivers/mtd/nand/raw/brcmnand/brcmnand.c
|
||||
+++ b/drivers/mtd/nand/raw/brcmnand/brcmnand.c
|
||||
@@ -2432,6 +2432,12 @@ static int brcmnand_attach_chip(struct n
|
||||
chip->ecc.read_oob = brcmnand_read_oob_raw;
|
||||
}
|
||||
|
||||
+ /* If OOB is written with ECC enabled it will cause ECC errors */
|
||||
+ if (is_hamming_ecc(host->ctrl, &host->hwcfg)) {
|
||||
+ chip->ecc.write_oob = brcmnand_write_oob_raw;
|
||||
+ chip->ecc.read_oob = brcmnand_read_oob_raw;
|
||||
+ }
|
||||
+
|
||||
return ret;
|
||||
}
|
||||
|
||||
@ -0,0 +1,33 @@
|
||||
From fa2632f74e57bbc869c8ad37751a11b6147a3acc Mon Sep 17 00:00:00 2001
|
||||
From: Chris Packham <chris.packham@alliedtelesis.co.nz>
|
||||
Date: Mon, 16 Mar 2020 20:49:07 +1300
|
||||
Subject: [PATCH] net: mvmdio: avoid error message for optional IRQ
|
||||
|
||||
Per the dt-binding the interrupt is optional so use
|
||||
platform_get_irq_optional() instead of platform_get_irq(). Since
|
||||
commit 7723f4c5ecdb ("driver core: platform: Add an error message to
|
||||
platform_get_irq*()") platform_get_irq() produces an error message
|
||||
|
||||
orion-mdio f1072004.mdio: IRQ index 0 not found
|
||||
|
||||
which is perfectly normal if one hasn't specified the optional property
|
||||
in the device tree.
|
||||
|
||||
Signed-off-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
|
||||
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
|
||||
Signed-off-by: David S. Miller <davem@davemloft.net>
|
||||
---
|
||||
drivers/net/ethernet/marvell/mvmdio.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
--- a/drivers/net/ethernet/marvell/mvmdio.c
|
||||
+++ b/drivers/net/ethernet/marvell/mvmdio.c
|
||||
@@ -347,7 +347,7 @@ static int orion_mdio_probe(struct platf
|
||||
}
|
||||
|
||||
|
||||
- dev->err_interrupt = platform_get_irq(pdev, 0);
|
||||
+ dev->err_interrupt = platform_get_irq_optional(pdev, 0);
|
||||
if (dev->err_interrupt > 0 &&
|
||||
resource_size(r) < MVMDIO_ERR_INT_MASK + 4) {
|
||||
dev_err(&pdev->dev,
|
||||
@ -66,7 +66,7 @@ Signed-off-by: René van Dorst <opensource@vdorst.com>
|
||||
+ eeecr &= 0xFFFF0000;
|
||||
+ if (!e->tx_lpi_enabled)
|
||||
+ eeecr |= LPI_MODE_EN;
|
||||
+ eeecr = LPI_THRESH(e->tx_lpi_timer);
|
||||
+ eeecr |= LPI_THRESH(e->tx_lpi_timer);
|
||||
+ mt7530_write(priv, MT7530_PMEEECR_P(port), eeecr);
|
||||
+ } else {
|
||||
+ priv->eee_enable &= ~(BIT(port));
|
||||
|
||||
@ -0,0 +1,107 @@
|
||||
From 35639bac13927d1476398b740b11cbed0ee3ddb2 Mon Sep 17 00:00:00 2001
|
||||
From: Robert Marko <robert.marko@sartura.hr>
|
||||
Date: Tue, 18 May 2021 13:24:30 +0200
|
||||
Subject: [PATCH] Revert "cpufreq: armada-37xx: Fix setting TBG parent for load
|
||||
levels"
|
||||
|
||||
This reverts commit a13b110e7c9e0dc2edcc7a19d4255fc88abd83cc.
|
||||
|
||||
This patch actually corrects the things so that 1 or 1.2GHz models would
|
||||
actually get scaled to their native frequency.
|
||||
|
||||
However, due to a AVS setting voltages too low this will cause random
|
||||
crashes on 1.2GHz models.
|
||||
|
||||
So, until a new safe for everybody voltage is agreed on
|
||||
lets revert the patch.
|
||||
|
||||
Signed-off-by: Robert Marko <robert.marko@sartura.hr>
|
||||
---
|
||||
drivers/cpufreq/armada-37xx-cpufreq.c | 35 +++++++++------------------
|
||||
1 file changed, 12 insertions(+), 23 deletions(-)
|
||||
|
||||
--- a/drivers/cpufreq/armada-37xx-cpufreq.c
|
||||
+++ b/drivers/cpufreq/armada-37xx-cpufreq.c
|
||||
@@ -25,10 +25,6 @@
|
||||
|
||||
#include "cpufreq-dt.h"
|
||||
|
||||
-/* Clk register set */
|
||||
-#define ARMADA_37XX_CLK_TBG_SEL 0
|
||||
-#define ARMADA_37XX_CLK_TBG_SEL_CPU_OFF 22
|
||||
-
|
||||
/* Power management in North Bridge register set */
|
||||
#define ARMADA_37XX_NB_L0L1 0x18
|
||||
#define ARMADA_37XX_NB_L2L3 0x1C
|
||||
@@ -126,15 +122,10 @@ static struct armada_37xx_dvfs *armada_3
|
||||
* will be configured then the DVFS will be enabled.
|
||||
*/
|
||||
static void __init armada37xx_cpufreq_dvfs_setup(struct regmap *base,
|
||||
- struct regmap *clk_base, u8 *divider)
|
||||
+ struct clk *clk, u8 *divider)
|
||||
{
|
||||
- u32 cpu_tbg_sel;
|
||||
int load_lvl;
|
||||
-
|
||||
- /* Determine to which TBG clock is CPU connected */
|
||||
- regmap_read(clk_base, ARMADA_37XX_CLK_TBG_SEL, &cpu_tbg_sel);
|
||||
- cpu_tbg_sel >>= ARMADA_37XX_CLK_TBG_SEL_CPU_OFF;
|
||||
- cpu_tbg_sel &= ARMADA_37XX_NB_TBG_SEL_MASK;
|
||||
+ struct clk *parent;
|
||||
|
||||
for (load_lvl = 0; load_lvl < LOAD_LEVEL_NR; load_lvl++) {
|
||||
unsigned int reg, mask, val, offset = 0;
|
||||
@@ -153,11 +144,6 @@ static void __init armada37xx_cpufreq_dv
|
||||
mask = (ARMADA_37XX_NB_CLK_SEL_MASK
|
||||
<< ARMADA_37XX_NB_CLK_SEL_OFF);
|
||||
|
||||
- /* Set TBG index, for all levels we use the same TBG */
|
||||
- val = cpu_tbg_sel << ARMADA_37XX_NB_TBG_SEL_OFF;
|
||||
- mask = (ARMADA_37XX_NB_TBG_SEL_MASK
|
||||
- << ARMADA_37XX_NB_TBG_SEL_OFF);
|
||||
-
|
||||
/*
|
||||
* Set cpu divider based on the pre-computed array in
|
||||
* order to have balanced step.
|
||||
@@ -176,6 +162,14 @@ static void __init armada37xx_cpufreq_dv
|
||||
|
||||
regmap_update_bits(base, reg, mask, val);
|
||||
}
|
||||
+
|
||||
+ /*
|
||||
+ * Set cpu clock source, for all the level we keep the same
|
||||
+ * clock source that the one already configured. For this one
|
||||
+ * we need to use the clock framework
|
||||
+ */
|
||||
+ parent = clk_get_parent(clk);
|
||||
+ clk_set_parent(clk, parent);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -401,16 +395,11 @@ static int __init armada37xx_cpufreq_dri
|
||||
struct platform_device *pdev;
|
||||
unsigned long freq;
|
||||
unsigned int cur_frequency, base_frequency;
|
||||
- struct regmap *nb_clk_base, *nb_pm_base, *avs_base;
|
||||
+ struct regmap *nb_pm_base, *avs_base;
|
||||
struct device *cpu_dev;
|
||||
int load_lvl, ret;
|
||||
struct clk *clk, *parent;
|
||||
|
||||
- nb_clk_base =
|
||||
- syscon_regmap_lookup_by_compatible("marvell,armada-3700-periph-clock-nb");
|
||||
- if (IS_ERR(nb_clk_base))
|
||||
- return -ENODEV;
|
||||
-
|
||||
nb_pm_base =
|
||||
syscon_regmap_lookup_by_compatible("marvell,armada-3700-nb-pm");
|
||||
|
||||
@@ -487,7 +476,7 @@ static int __init armada37xx_cpufreq_dri
|
||||
armada37xx_cpufreq_avs_configure(avs_base, dvfs);
|
||||
armada37xx_cpufreq_avs_setup(avs_base, dvfs);
|
||||
|
||||
- armada37xx_cpufreq_dvfs_setup(nb_pm_base, nb_clk_base, dvfs->divider);
|
||||
+ armada37xx_cpufreq_dvfs_setup(nb_pm_base, clk, dvfs->divider);
|
||||
clk_put(clk);
|
||||
|
||||
for (load_lvl = ARMADA_37XX_DVFS_LOAD_0; load_lvl < LOAD_LEVEL_NR;
|
||||
@ -25,6 +25,9 @@ CMAKE_HOST_OPTIONS += \
|
||||
-DCMAKE_SKIP_RPATH=FALSE \
|
||||
-DCMAKE_INSTALL_RPATH="${STAGING_DIR_HOST}/lib" \
|
||||
|
||||
ifneq (docs-$(CONFIG_BUILD_DOCUMENTATION),docs-y)
|
||||
CMAKE_HOST_OPTIONS += -DENABLE_DOCUMENTATION=OFF
|
||||
endif
|
||||
|
||||
define Host/Install/ccache
|
||||
$(INSTALL_DIR) $(STAGING_DIR_HOST)/bin/
|
||||
|
||||
34
tools/fakeroot/patches/400-alpine-libc.musl-fix.patch
Normal file
34
tools/fakeroot/patches/400-alpine-libc.musl-fix.patch
Normal file
@ -0,0 +1,34 @@
|
||||
Alpine linux libc.musl build error fix
|
||||
|
||||
Prevent build error on Alpine Linux host:
|
||||
libfakeroot.c error: conflicting types for 'id_t'
|
||||
Error relocating openwrt/staging_dir/host/lib/libfakeroot.so: SEND_GET_XATTR: symbol not found
|
||||
|
||||
--- a/libfakeroot.c
|
||||
+++ b/libfakeroot.c
|
||||
@@ -81,12 +81,14 @@
|
||||
#define SEND_STAT64(a,b,c) send_stat64(a,b,c)
|
||||
#define SEND_GET_STAT(a,b) send_get_stat(a,b)
|
||||
#define SEND_GET_STAT64(a,b) send_get_stat64(a,b)
|
||||
+#define SEND_GET_XATTR(a,b,c) send_get_xattr(a,b,c)
|
||||
#define SEND_GET_XATTR64(a,b,c) send_get_xattr64(a,b,c)
|
||||
#else
|
||||
#define SEND_STAT(a,b,c) send_stat(a,b)
|
||||
#define SEND_STAT64(a,b,c) send_stat64(a,b)
|
||||
#define SEND_GET_STAT(a,b) send_get_stat(a)
|
||||
#define SEND_GET_STAT64(a,b) send_get_stat64(a)
|
||||
+#define SEND_GET_XATTR(a,b,c) send_get_xattr(a,b)
|
||||
#define SEND_GET_XATTR64(a,b,c) send_get_xattr64(a,b)
|
||||
#endif
|
||||
|
||||
@@ -125,8 +127,9 @@
|
||||
|
||||
/* 10.10 uses id_t in getpriority/setpriority calls, so pretend
|
||||
id_t is used everywhere, just happens to be int on some OSes */
|
||||
-#ifndef _ID_T
|
||||
+#if !defined(_ID_T) && !defined(__DEFINED_id_t)
|
||||
#define _ID_T
|
||||
+#define __DEFINED_id_t
|
||||
typedef int id_t;
|
||||
#endif
|
||||
#endif
|
||||
Loading…
Reference in New Issue
Block a user