Merge Official Source

This commit is contained in:
ZiMing Mo 2022-07-12 00:37:13 +08:00
commit ab1b6714c5
No known key found for this signature in database
GPG Key ID: 1BED2E3A77AE5ECF
96 changed files with 1545 additions and 631 deletions

View File

@ -1,2 +1,2 @@
LINUX_VERSION-5.15 = .50
LINUX_KERNEL_HASH-5.15.50 = 554d507d37a23810fe8c83912761e4a4f73c40794bc685ff7ca98042fe1bd70f
LINUX_VERSION-5.15 = .53
LINUX_KERNEL_HASH-5.15.53 = f3aa717243051f3fcca90ebfe26fe5c3a596c2f6047846e8d1724ea90df77b07

View File

@ -9,9 +9,9 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=at91bootstrap
PKG_VERSION:=v4.0.1
PKG_MIRROR_HASH:=3d45a4bcb52162097d4cdf042b8fe1ccf53e88b512e7541f42a23f2a73692a69
PKG_SOURCE_VERSION:=4d41296e9ae12379555fb46a941897e7264600a2
PKG_VERSION:=v4.0.3
PKG_MIRROR_HASH:=1ecdc31a13350fcdcaa3f77ed8ad73906f79fc668dbb2f337e1d5dd877bf9882
PKG_SOURCE_VERSION:=1d9e673698d9db4a4f2301559f481274de2e75ae
BINARIES_DIR:=build/binaries
AT91BOOTSTRAP_V4=y

View File

@ -7,13 +7,13 @@
include $(TOPDIR)/rules.mk
PKG_VERSION:=linux4sam-2021.10
PKG_VERSION:=linux4sam-2022.04
PKG_RELEASE:=$(AUTORELEASE)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://github.com/linux4sam/u-boot-at91.git
PKG_MIRROR_HASH:=f1190062f2012b182b45b78263a4cce4ada9b7b8d6f5a66d68fa51437105fc8c
PKG_SOURCE_VERSION:=39854ce82232cdc05c20158d0439bdbc40991e4a
PKG_MIRROR_HASH:=56bbac45f71aaf39b365661db2a76c6c8415e27f7147b27bb58312b12756c8f3
PKG_SOURCE_VERSION:=7b59654a486d39dc8e0343e2554699b8a79c7a54
include $(INCLUDE_DIR)/u-boot.mk
include $(INCLUDE_DIR)/package.mk
@ -174,7 +174,6 @@ UBOOT_TARGETS := \
define Build/Compile
+$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR) \
CROSS_COMPILE=$(TARGET_CROSS) \
DTC=$(PKG_BUILD_DIR)/scripts/dtc/dtc \
KCFLAGS="$(filter-out -fstack-protector \
-mfloat-abi=hard, $(TARGET_CFLAGS)) -mfloat-abi=soft"
endef

View File

@ -10,11 +10,9 @@ Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
drivers/pinctrl/pinctrl-uclass.c | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/cmd/panic.c b/cmd/panic.c
index f13b3f094fab..197e2d0870ff 100644
--- a/cmd/panic.c
+++ b/cmd/panic.c
@@ -11,7 +11,7 @@ static int do_panic(struct cmd_tbl *cmdtp, int flag, int argc,
@@ -11,7 +11,7 @@ static int do_panic(struct cmd_tbl *cmdt
{
char *text = (argc < 2) ? "" : argv[1];
@ -23,11 +21,9 @@ index f13b3f094fab..197e2d0870ff 100644
return CMD_RET_SUCCESS;
}
diff --git a/cmd/version.c b/cmd/version.c
index 3686b8733249..35b52c48171d 100644
--- a/cmd/version.c
+++ b/cmd/version.c
@@ -19,7 +19,7 @@ static int do_version(struct cmd_tbl *cmdtp, int flag, int argc,
@@ -24,7 +24,7 @@ static int do_version(struct cmd_tbl *cm
{
char buf[DISPLAY_OPTIONS_BANNER_LENGTH];
@ -36,11 +32,9 @@ index 3686b8733249..35b52c48171d 100644
#ifdef CC_VERSION_STRING
puts(CC_VERSION_STRING "\n");
#endif
diff --git a/drivers/pinctrl/pinctrl-uclass.c b/drivers/pinctrl/pinctrl-uclass.c
index b0f30aa1f758..aa62a890609a 100644
--- a/drivers/pinctrl/pinctrl-uclass.c
+++ b/drivers/pinctrl/pinctrl-uclass.c
@@ -371,7 +371,7 @@ int pinctrl_get_pin_name(struct udevice *dev, int selector, char *buf,
@@ -375,7 +375,7 @@ int pinctrl_get_pin_name(struct udevice
if (!ops->get_pin_name)
return -ENOSYS;
@ -49,6 +43,3 @@ index b0f30aa1f758..aa62a890609a 100644
return 0;
}
--
2.33.0

View File

@ -0,0 +1,19 @@
[ -e /etc/config/ubootenv ] && exit 0
touch /etc/config/ubootenv
. /lib/uboot-envtools.sh
. /lib/functions.sh
board=$(board_name)
case "$board" in
technexion,imx7d-pico-pi)
ubootenv_add_uci_config "/dev/mmcblk2" "0xc0000" "0x2000" "0x2000"
;;
esac
config_load ubootenv
config_foreach ubootenv_add_app_config ubootenv
exit 0

View File

@ -0,0 +1,144 @@
From f178f7c9550c4fd9c644f79a1eb2dafa5bcdce25 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <rafal@milecki.pl>
Date: Wed, 12 Jan 2022 12:47:05 +0100
Subject: [PATCH] fw_env: make flash_io() take buffer as an argument
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
It's usually easier to understand code & follow it if all arguments are
passed explicitly. Many coding styles also discourage using global
variables.
Behaviour of flash_io() was a bit unintuitive as it was writing to a
buffer referenced in a global struct. That required developers to
remember how it works and sometimes required hacking "environment"
global struct variable to read data into a proper buffer.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
---
tools/env/fw_env.c | 32 ++++++++++++++++----------------
1 file changed, 16 insertions(+), 16 deletions(-)
--- a/tools/env/fw_env.c
+++ b/tools/env/fw_env.c
@@ -346,7 +346,7 @@ static int ubi_write(int fd, const void
return 0;
}
-static int flash_io(int mode);
+static int flash_io(int mode, void *buf, size_t count);
static int parse_config(struct env_opts *opts);
#if defined(CONFIG_FILE)
@@ -516,7 +516,7 @@ int fw_env_flush(struct env_opts *opts)
*environment.crc = crc32(0, (uint8_t *) environment.data, ENV_SIZE);
/* write environment back to flash */
- if (flash_io(O_RDWR)) {
+ if (flash_io(O_RDWR, environment.image, CUR_ENVSIZE)) {
fprintf(stderr, "Error: can't write fw_env to flash\n");
return -1;
}
@@ -1185,7 +1185,8 @@ static int flash_flag_obsolete(int dev,
return rc;
}
-static int flash_write(int fd_current, int fd_target, int dev_target)
+static int flash_write(int fd_current, int fd_target, int dev_target, void *buf,
+ size_t count)
{
int rc;
@@ -1212,11 +1213,10 @@ static int flash_write(int fd_current, i
if (IS_UBI(dev_target)) {
if (ubi_update_start(fd_target, CUR_ENVSIZE) < 0)
return -1;
- return ubi_write(fd_target, environment.image, CUR_ENVSIZE);
+ return ubi_write(fd_target, buf, count);
}
- rc = flash_write_buf(dev_target, fd_target, environment.image,
- CUR_ENVSIZE);
+ rc = flash_write_buf(dev_target, fd_target, buf, count);
if (rc < 0)
return rc;
@@ -1235,17 +1235,17 @@ static int flash_write(int fd_current, i
return 0;
}
-static int flash_read(int fd)
+static int flash_read(int fd, void *buf, size_t count)
{
int rc;
if (IS_UBI(dev_current)) {
DEVTYPE(dev_current) = MTD_ABSENT;
- return ubi_read(fd, environment.image, CUR_ENVSIZE);
+ return ubi_read(fd, buf, count);
}
- rc = flash_read_buf(dev_current, fd, environment.image, CUR_ENVSIZE,
+ rc = flash_read_buf(dev_current, fd, buf, count,
DEVOFFSET(dev_current));
if (rc != CUR_ENVSIZE)
return -1;
@@ -1291,7 +1291,7 @@ err:
return rc;
}
-static int flash_io_write(int fd_current)
+static int flash_io_write(int fd_current, void *buf, size_t count)
{
int fd_target = -1, rc, dev_target;
const char *dname, *target_temp = NULL;
@@ -1322,7 +1322,7 @@ static int flash_io_write(int fd_current
fd_target = fd_current;
}
- rc = flash_write(fd_current, fd_target, dev_target);
+ rc = flash_write(fd_current, fd_target, dev_target, buf, count);
if (fsync(fd_current) && !(errno == EINVAL || errno == EROFS)) {
fprintf(stderr,
@@ -1377,7 +1377,7 @@ static int flash_io_write(int fd_current
return rc;
}
-static int flash_io(int mode)
+static int flash_io(int mode, void *buf, size_t count)
{
int fd_current, rc;
@@ -1391,9 +1391,9 @@ static int flash_io(int mode)
}
if (mode == O_RDWR) {
- rc = flash_io_write(fd_current);
+ rc = flash_io_write(fd_current, buf, count);
} else {
- rc = flash_read(fd_current);
+ rc = flash_read(fd_current, buf, count);
}
if (close(fd_current)) {
@@ -1455,7 +1455,7 @@ int fw_env_open(struct env_opts *opts)
}
dev_current = 0;
- if (flash_io(O_RDONLY)) {
+ if (flash_io(O_RDONLY, environment.image, CUR_ENVSIZE)) {
ret = -EIO;
goto open_cleanup;
}
@@ -1490,7 +1490,7 @@ int fw_env_open(struct env_opts *opts)
* other pointers in environment still point inside addr0
*/
environment.image = addr1;
- if (flash_io(O_RDONLY)) {
+ if (flash_io(O_RDONLY, environment.image, CUR_ENVSIZE)) {
ret = -EIO;
goto open_cleanup;
}

View File

@ -0,0 +1,173 @@
From 07c79dd5fdeaefb39c9e7a97f3b66de63109a18d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <rafal@milecki.pl>
Date: Wed, 12 Jan 2022 12:47:06 +0100
Subject: [PATCH] fw_env: simplify logic & code paths in the fw_env_open()
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Environment variables can be stored in two formats:
1. Single entry with header containing CRC32
2. Two entries with extra flags field in each entry header
For that reason fw_env_open() has two main code paths and there are
pointers for CRC32/flags/data.
Previous implementation was a bit hard to follow:
1. It was checking for used format twice (in reversed order each time)
2. It was setting "environment" global struct fields to some temporary
values that required extra comments explaining it
This change simplifies that code:
1. It introduces two clear code paths
2. It sets "environment" global struct fields values only once it really
knows them
To be fair there are *two* crc32() calls now and an extra pointer
variable but that should be cheap enough and worth it.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
---
tools/env/fw_env.c | 77 +++++++++++++++++++---------------------------
1 file changed, 31 insertions(+), 46 deletions(-)
--- a/tools/env/fw_env.c
+++ b/tools/env/fw_env.c
@@ -1421,9 +1421,6 @@ int fw_env_open(struct env_opts *opts)
int ret;
- struct env_image_single *single;
- struct env_image_redundant *redundant;
-
if (!opts)
opts = &default_opts;
@@ -1439,40 +1436,37 @@ int fw_env_open(struct env_opts *opts)
goto open_cleanup;
}
- /* read environment from FLASH to local buffer */
- environment.image = addr0;
-
- if (have_redund_env) {
- redundant = addr0;
- environment.crc = &redundant->crc;
- environment.flags = &redundant->flags;
- environment.data = redundant->data;
- } else {
- single = addr0;
- environment.crc = &single->crc;
- environment.flags = NULL;
- environment.data = single->data;
- }
-
dev_current = 0;
- if (flash_io(O_RDONLY, environment.image, CUR_ENVSIZE)) {
+ if (flash_io(O_RDONLY, addr0, CUR_ENVSIZE)) {
ret = -EIO;
goto open_cleanup;
}
- crc0 = crc32(0, (uint8_t *)environment.data, ENV_SIZE);
-
- crc0_ok = (crc0 == *environment.crc);
if (!have_redund_env) {
+ struct env_image_single *single = addr0;
+
+ crc0 = crc32(0, (uint8_t *)single->data, ENV_SIZE);
+ crc0_ok = (crc0 == single->crc);
if (!crc0_ok) {
fprintf(stderr,
"Warning: Bad CRC, using default environment\n");
- memcpy(environment.data, default_environment,
+ memcpy(single->data, default_environment,
sizeof(default_environment));
environment.dirty = 1;
}
+
+ environment.image = addr0;
+ environment.crc = &single->crc;
+ environment.flags = NULL;
+ environment.data = single->data;
} else {
- flag0 = *environment.flags;
+ struct env_image_redundant *redundant0 = addr0;
+ struct env_image_redundant *redundant1;
+
+ crc0 = crc32(0, (uint8_t *)redundant0->data, ENV_SIZE);
+ crc0_ok = (crc0 == redundant0->crc);
+
+ flag0 = redundant0->flags;
dev_current = 1;
addr1 = calloc(1, CUR_ENVSIZE);
@@ -1483,14 +1477,9 @@ int fw_env_open(struct env_opts *opts)
ret = -ENOMEM;
goto open_cleanup;
}
- redundant = addr1;
+ redundant1 = addr1;
- /*
- * have to set environment.image for flash_read(), careful -
- * other pointers in environment still point inside addr0
- */
- environment.image = addr1;
- if (flash_io(O_RDONLY, environment.image, CUR_ENVSIZE)) {
+ if (flash_io(O_RDONLY, addr1, CUR_ENVSIZE)) {
ret = -EIO;
goto open_cleanup;
}
@@ -1518,18 +1507,12 @@ int fw_env_open(struct env_opts *opts)
goto open_cleanup;
}
- crc1 = crc32(0, (uint8_t *)redundant->data, ENV_SIZE);
+ crc1 = crc32(0, (uint8_t *)redundant1->data, ENV_SIZE);
- crc1_ok = (crc1 == redundant->crc);
- flag1 = redundant->flags;
+ crc1_ok = (crc1 == redundant1->crc);
+ flag1 = redundant1->flags;
- /*
- * environment.data still points to ((struct
- * env_image_redundant *)addr0)->data. If the two
- * environments differ, or one has bad crc, force a
- * write-out by marking the environment dirty.
- */
- if (memcmp(environment.data, redundant->data, ENV_SIZE) ||
+ if (memcmp(redundant0->data, redundant1->data, ENV_SIZE) ||
!crc0_ok || !crc1_ok)
environment.dirty = 1;
@@ -1540,7 +1523,7 @@ int fw_env_open(struct env_opts *opts)
} else if (!crc0_ok && !crc1_ok) {
fprintf(stderr,
"Warning: Bad CRC, using default environment\n");
- memcpy(environment.data, default_environment,
+ memcpy(redundant0->data, default_environment,
sizeof(default_environment));
environment.dirty = 1;
dev_current = 0;
@@ -1586,13 +1569,15 @@ int fw_env_open(struct env_opts *opts)
*/
if (dev_current) {
environment.image = addr1;
- environment.crc = &redundant->crc;
- environment.flags = &redundant->flags;
- environment.data = redundant->data;
+ environment.crc = &redundant1->crc;
+ environment.flags = &redundant1->flags;
+ environment.data = redundant1->data;
free(addr0);
} else {
environment.image = addr0;
- /* Other pointers are already set */
+ environment.crc = &redundant0->crc;
+ environment.flags = &redundant0->flags;
+ environment.data = redundant0->data;
free(addr1);
}
#ifdef DEBUG

View File

@ -0,0 +1,110 @@
From 8142c4554ffaa927529f24427a35f7ee2861793a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <rafal@milecki.pl>
Date: Thu, 16 Jun 2022 20:59:03 +0200
Subject: [PATCH] fw_env: add fallback to Linux's NVMEM based access
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
A new DT binding for describing environment data block has been added in
Linux's commit 5db1c2dbc04c ("dt-bindings: nvmem: add U-Boot environment
variables binding"). Once we get a proper Linux NVMEM driver it'll be
possible to use Linux's binary interface for user-space as documented
in the:
https://www.kernel.org/doc/html/latest/driver-api/nvmem.html
This commits makes fw_env fallback to looking for a compatible NVMEM
device in case config file isn't present. In a long term this may make
config files redundant and avoid code (info) duplication.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
---
tools/env/fw_env.c | 70 ++++++++++++++++++++++++++++++++++++++++++++--
1 file changed, 67 insertions(+), 3 deletions(-)
--- a/tools/env/fw_env.c
+++ b/tools/env/fw_env.c
@@ -1713,6 +1713,67 @@ static int check_device_config(int dev)
return rc;
}
+static int find_nvmem_device(void)
+{
+ const char *path = "/sys/bus/nvmem/devices";
+ struct dirent *dent;
+ char *nvmem = NULL;
+ char comp[256];
+ char buf[32];
+ int bytes;
+ DIR *dir;
+
+ dir = opendir(path);
+ if (!dir) {
+ return -EIO;
+ }
+
+ while (!nvmem && (dent = readdir(dir))) {
+ FILE *fp;
+
+ if (!strcmp(dent->d_name, ".") || !strcmp(dent->d_name, "..")) {
+ continue;
+ }
+
+ bytes = snprintf(comp, sizeof(comp), "%s/%s/of_node/compatible", path, dent->d_name);
+ if (bytes < 0 || bytes == sizeof(comp)) {
+ continue;
+ }
+
+ fp = fopen(comp, "r");
+ if (!fp) {
+ continue;
+ }
+
+ fread(buf, sizeof(buf), 1, fp);
+
+ if (!strcmp(buf, "u-boot,env")) {
+ bytes = asprintf(&nvmem, "%s/%s/nvmem", path, dent->d_name);
+ if (bytes < 0) {
+ nvmem = NULL;
+ }
+ }
+
+ fclose(fp);
+ }
+
+ closedir(dir);
+
+ if (nvmem) {
+ struct stat s;
+
+ stat(nvmem, &s);
+
+ DEVNAME(0) = nvmem;
+ DEVOFFSET(0) = 0;
+ ENVSIZE(0) = s.st_size;
+
+ return 0;
+ }
+
+ return -ENOENT;
+}
+
static int parse_config(struct env_opts *opts)
{
int rc;
@@ -1723,9 +1784,12 @@ static int parse_config(struct env_opts
#if defined(CONFIG_FILE)
/* Fills in DEVNAME(), ENVSIZE(), DEVESIZE(). Or don't. */
if (get_config(opts->config_file)) {
- fprintf(stderr, "Cannot parse config file '%s': %m\n",
- opts->config_file);
- return -1;
+ if (find_nvmem_device()) {
+ fprintf(stderr, "Cannot parse config file '%s': %m\n",
+ opts->config_file);
+ fprintf(stderr, "Failed to find NVMEM device\n");
+ return -1;
+ }
}
#else
DEVNAME(0) = DEVICE1_NAME;

View File

@ -36,6 +36,14 @@ define U-Boot/mx6cuboxi
BUILD_DEVICES:=solidrun_cubox-i
endef
define U-Boot/pico-pi-imx7d
NAME:=TechNexion PICO-PI-IMX7D
UBOOT_IMAGE:=SPL u-boot-dtb.img
UBOOT_MAKE_FLAGS:=SPL u-boot-dtb.img
BUILD_SUBTARGET:=cortexa7
BUILD_DEVICES:=technexion_imx7d-pico-pi
endef
define U-Boot/wandboard
NAME:=Wandboard Dual Lite/Quad/Solo
BUILD_SUBTARGET:=cortexa9
@ -45,6 +53,7 @@ endef
UBOOT_TARGETS := \
apalis_imx6 \
mx6cuboxi \
pico-pi-imx7d \
wandboard
UBOOT_MAKE_FLAGS += u-boot.imx

View File

@ -8,13 +8,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=binutils
PKG_VERSION:=2.37
PKG_RELEASE:=2
PKG_VERSION:=2.38
PKG_RELEASE:=1
PKG_SOURCE_URL:=@GNU/binutils
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_VERSION:=$(PKG_VERSION)
PKG_HASH:=820d9724f020a3e69cb337893a0b63c2db161dadcb0e06fc11dc29eb1e84a32c
PKG_HASH:=e316477a914f567eccc34d5d29785b8b0f5a10208d36bbacedcc39048ecfe024
PKG_FIXUP:=patch-libtool
PKG_LIBTOOL_PATHS:=. gas bfd opcodes gprof binutils ld libiberty gold intl

View File

@ -81,21 +81,6 @@ endef
$(eval $(call BuildPackage,cypress-firmware-43362-sdio))
# Cypress 4339 SDIO Firmware
define Package/cypress-firmware-4339-sdio
$(Package/cypress-firmware-default)
TITLE:=CYW4339 FullMac SDIO firmware
endef
define Package/cypress-firmware-4339-sdio/install
$(INSTALL_DIR) $(1)/lib/firmware/brcm
$(INSTALL_DATA) \
$(PKG_BUILD_DIR)/firmware/cyfmac4339-sdio.bin \
$(1)/lib/firmware/brcm/brcmfmac4339-sdio.bin
endef
$(eval $(call BuildPackage,cypress-firmware-4339-sdio))
# Cypress 43430 SDIO Firmware
define Package/cypress-firmware-43430-sdio
$(Package/cypress-firmware-default)

View File

@ -106,3 +106,21 @@ define Package/cypress-nvram-43455-sdio-rpi-4b/install
endef
$(eval $(call BuildPackage,cypress-nvram-43455-sdio-rpi-4b))
# Cypress 4339 SDIO PICO-PI-IMX7D
define Package/cypress-nvram-4339-pico-pi-imx7d
$(Package/cypress-nvram-default)
TITLE:=BCM4339 NVRAM for TechNexion PICO-PI-IMX7D
DEPENDS:=@TARGET_imx_cortexa7
PROVIDES:=brcmfmac-firmware-4339-pico-pi-imx7d
CONFLICTS:=brcmfmac-firmware-4339-pico-pi-imx7d
endef
define Package/cypress-nvram-4339-pico-pi-imx7d/install
$(INSTALL_DIR) $(1)/lib/firmware/brcm
$(INSTALL_DATA) \
./files/brcmfmac4339-sdio.technexion,imx7d-pico-pi.txt \
$(1)/lib/firmware/brcm/brcmfmac4339-sdio.technexion,imx7d-pico-pi.txt
endef
$(eval $(call BuildPackage,cypress-nvram-4339-pico-pi-imx7d))

View File

@ -0,0 +1,99 @@
#AP6335_NVRAM_V1.5_03112014
NVRAMRev=$Rev: 410316 $
sromrev=11
boardrev=0x1203
boardtype=0x06c5
boardflags=0x00000c01
boardflags2=0x00002000
boardflags3=0x101188
macaddr=00:90:4c:c5:12:38
ccode=0
regrev=0
antswitch=0
pdgain2g=7
pdgain5g=7
tworangetssi2g=0
tworangetssi5g=0
femctrl=7
pcieingress_war=15
vendid=0x14e4
devid=0x43ae
manfid=0x2d0
nocrc=1
otpimagesize=502
xtalfreq=37400
extpagain2g=2
pdetrange2g=2
extpagain5g=2
pdetrange5g=2
rxgains2gelnagaina0=0
rxgains2gtrisoa0=7
rxgains2gtrelnabypa0=0
rxgains5gelnagaina0=0
rxgains5gtrisoa0=11
rxgains5gtrelnabypa0=0
rxchain=1
txchain=1
aa2g=1
aa5g=1
tssipos5g=0
tssipos2g=0
pa2ga0=-161,6269,-723
pa2gccka0=-116,7568,-852
pa5ga0=0xFF61,0x163C,0xFD55,0xFF5D,0x1671,0xFD4F,0xFF5F,0x16CA,0xFD45,0xFF60,0x1676,0xFD4D
pa5gbw40a0=0xFF61,0x163C,0xFD55,0xFF5D,0x1671,0xFD4F,0xFF5F,0x16CA,0xFD45,0xFF60,0x1676,0xFD4D
pa5gbw80a0=0xFF61,0x163C,0xFD55,0xFF5D,0x1671,0xFD4F,0xFF5F,0x16CA,0xFD45,0xFF60,0x1676,0xFD4D
pdoffset40ma0=0
pdoffset80ma0=0
pdoffsetcckma0=0
maxp2ga0=75
maxp5ga0=64,64,72,72
cckbw202gpo=0x0000
cckbw20ul2gpo=0x0
mcsbw202gpo=0x99445533
mcsbw402gpo=0x99775533
dot11agofdmhrbw202gpo=0x2233
ofdmlrbw202gpo=0x0000
tssifloor2g=500
mcsbw205glpo=0x66333330
mcsbw405glpo=0x66665530
mcsbw805glpo=0xAA555530
mcsbw1605glpo=0x99555530
mcsbw205gmpo=0x99BB5530
mcsbw405gmpo=0x99BB5530
mcsbw805gmpo=0xEE555530
mcsbw1605gmpo=0x99555530
mcsbw205ghpo=0x99995530
mcsbw405ghpo=0x99BB5530
mcsbw805ghpo=0xEE555530
mcsbw1605ghpo=0x99555530
mcslr5glpo=0x0000
mcslr5gmpo=0x0000
mcslr5ghpo=0x0000
sb20in40hrrpo=0x0
sb20in80and160hr5glpo=0x0
sb40and80hr5glpo=0x0
sb20in80and160hr5gmpo=0x0
sb40and80hr5gmpo=0x0
sb20in80and160hr5ghpo=0x0
sb40and80hr5ghpo=0x0
sb20in40lrpo=0x0
sb20in80and160lr5glpo=0x0
sb40and80lr5glpo=0x0
sb20in80and160lr5gmpo=0x0
sb40and80lr5gmpo=0x0
sb20in80and160lr5ghpo=0x0
sb40and80lr5ghpo=0x0
dot11agduphrpo=0x0
dot11agduplrpo=0x0
phycal_tempdelta=25
cckdigfilttype=2
pacalidx2g=65
dacrate2g=160
swctrlmap_5g=0x00000008,0x00000010,0x00000008,0x000000,0x038
swctrlmap_2g=0x00000001,0x00000002,0x00000001,0x040002,0x0ff
swctrlmapext_5g=0x00000000,0x00000000,0x00000000,0x000000,0x000
swctrlmapext_2g=0x00000000,0x00000000,0x00000000,0x000000,0x000
rssicorrnorm_c0=3,3
rssicorrnorm5g_c0=2,3,4,2,3,3,0,1,2,0,1,2
muxenab=0x10

View File

@ -0,0 +1,8 @@
Package/cypress-firmware-4339-sdio = $(call Package/firmware-default,Broadcom BCM4339 FullMac SDIO firmware)
define Package/cypress-firmware-4339-sdio/install
$(INSTALL_DIR) $(1)/lib/firmware/brcm
$(INSTALL_DATA) \
$(PKG_BUILD_DIR)/cypress/cyfmac4339-sdio.bin \
$(1)/lib/firmware/brcm/brcmfmac4339-sdio.bin
endef
$(eval $(call BuildPackage,cypress-firmware-4339-sdio))

View File

@ -193,6 +193,27 @@ endef
$(eval $(call KernelPackage,input-touchscreen-ads7846))
define KernelPackage/input-touchscreen-edt-ft5x06
SUBMENU:=$(INPUT_MODULES_MENU)
TITLE:=EDT FT5x06 and Focaltech FT6236 based touchscreens
DEPENDS:=+kmod-i2c-core +kmod-input-core
KCONFIG:= \
CONFIG_INPUT_TOUCHSCREEN=y \
CONFIG_TOUCHSCREEN_PROPERTIES=y@lt5.13 \
CONFIG_TOUCHSCREEN_EDT_FT5X06
FILES:=$(LINUX_DIR)/drivers/input/touchscreen/edt-ft5x06.ko \
$(LINUX_DIR)/drivers/input/touchscreen/of_touchscreen.ko@lt5.13
AUTOLOAD:=$(call AutoProbe,edt-ft5x06)
endef
define KernelPackage/input-touchscreen-edt-ft5x06/description
Kernel module for EDT FT5206, FT5306, FT5406, FT5506, Evervision FT5726 \
and Focaltech FT6236 based touchscreens
endef
$(eval $(call KernelPackage,input-touchscreen-edt-ft5x06))
define KernelPackage/keyboard-imx
SUBMENU:=$(INPUT_MODULES_MENU)
TITLE:=IMX keypad support

View File

@ -119,6 +119,24 @@ endef
$(eval $(call KernelPackage,btmrvl))
define KernelPackage/btsdio
SUBMENU:=$(OTHER_MENU)
TITLE:=Bluetooth HCI SDIO driver
DEPENDS:=+kmod-bluetooth +kmod-mmc
KCONFIG:= \
CONFIG_BT_HCIBTSDIO
FILES:= \
$(LINUX_DIR)/drivers/bluetooth/btsdio.ko
AUTOLOAD:=$(call AutoProbe,btsdio)
endef
define KernelPackage/btsdio/description
Kernel support for Bluetooth device with SDIO interface
endef
$(eval $(call KernelPackage,btsdio))
define KernelPackage/dma-buf
SUBMENU:=$(OTHER_MENU)
TITLE:=DMA shared buffer support

View File

@ -451,6 +451,7 @@ define KernelPackage/brcmfmac/config
bool "Enable SDIO bus interface support"
default y if TARGET_bcm27xx
default y if TARGET_rockchip
default y if TARGET_imx_cortexa7
default y if TARGET_sunxi
default n
help

View File

@ -8,15 +8,16 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=jansson
PKG_VERSION:=2.13.1
PKG_VERSION:=2.14
PKG_RELEASE:=2
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/akheron/$(PKG_NAME)/tar.gz/v$(PKG_VERSION)?
PKG_HASH:=c739578bf6b764aa0752db9a2fdadcfe921c78f1228c7ec0bb47fa804c55d17b
PKG_LICENSE:=MIT
PKG_LICENSE_FILES:=LICENSE
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_URL:=http://www.digip.org/jansson/releases/
PKG_HASH:=ee90a0f879d2b7b7159124ff22b937a2a9a8c36d3bb65d1da7dd3f04370a10bd
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/cmake.mk
@ -32,7 +33,7 @@ define Package/jansson
CATEGORY:=Libraries
TITLE:=Jansson library
URL:=http://www.digip.org/jansson/
ABI_VERSION:=4
ABI_VERSION:=5
endef
define Package/jansson/description

View File

@ -6,12 +6,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=libnl
PKG_VERSION:=3.6.0
PKG_VERSION:=3.7.0
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://github.com/thom311/libnl/releases/download/libnl$(subst .,_,$(PKG_VERSION))
PKG_HASH:=532155fd011e5a805bd67121b87a01c757e2bb24112ac17e69cb86013b970009
PKG_HASH:=9fe43ccbeeea72c653bdcf8c93332583135cda46a79507bfd0a483bb57f65939
PKG_LICENSE:=LGPL-2.1
PKG_LICENSE_FILES:=COPYING

View File

@ -21,6 +21,8 @@ PKG_LICENSE_FILES:=LICENSE
PKG_ASLR_PIE_REGULAR:=1
PKG_CONFIG_DEPENDS := CONFIG_PACKAGE_rpcapd
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/cmake.mk

View File

@ -8,12 +8,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=libtool
PKG_VERSION:=2.4.6
PKG_RELEASE:=2
PKG_VERSION:=2.4.7
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=@GNU/libtool
PKG_HASH:=7c87a8c2c8c0fc9cd5019e402bed4292462d00a718a7cd5f11218153bf28b26f
PKG_HASH:=4f7f217f057ce655ff22559ad221a0fd8ef84ad1fc5fcb6990cecc333aa1635d
PKG_LICENSE:=GPL-2.0+
PKG_LICENSE_FILES:=COPYING

View File

@ -8,14 +8,14 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=libusb
PKG_VERSION:=1.0.24
PKG_VERSION:=1.0.26
PKG_RELEASE:=$(AUTORELEASE)
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_URL:=\
https://github.com/libusb/libusb/releases/download/v$(PKG_VERSION) \
@SF/$(PKG_NAME)
PKG_HASH:=7efd2685f7b327326dcfb85cee426d9b871fd70e22caa15bb68d595ce2a2b12a
PKG_HASH:=12ce7a61fc9854d1d2a1ffe095f7b5fac19ddba095c259e6067a46500381b5a5
PKG_MAINTAINER:= Felix Fietkau <nbd@nbd.name>
PKG_LICENSE:=LGPL-2.1-or-later
@ -30,7 +30,7 @@ define Package/libusb-1.0
SECTION:=libs
CATEGORY:=Libraries
TITLE:=A library for accessing Linux USB devices
DEPENDS:=+libpthread +librt
DEPENDS:=+libpthread +librt +libatomic
URL:=http://libusb.info/
ABI_VERSION:=0
endef

View File

@ -1,29 +0,0 @@
From 369af149e3ad92514a2d24f112cedfeb7acaf558 Mon Sep 17 00:00:00 2001
From: Chris Dickens <christopher.a.dickens@gmail.com>
Date: Sun, 13 Dec 2020 15:46:27 -0800
Subject: [PATCH] Correct a typo in the Changelog and clean up a stray file
Signed-off-by: Chris Dickens <christopher.a.dickens@gmail.com>
---
ChangeLog | 2 +-
libusb/version_nano.h | 2 +-
test | 0
3 files changed, 2 insertions(+), 2 deletions(-)
delete mode 100644 test
--- a/ChangeLog
+++ b/ChangeLog
@@ -12,7 +12,7 @@ visit: http://log.libusb.info
* Darwin (macOS): use IOUSBDevice as darwin_device_class explicitly (#693)
* Linux: Drop support for kernel older than 2.6.32
* Linux: Provide an event thread name (#689)
-* Linux: Wait until all USBs have been reaped before freeing them (#607)
+* Linux: Wait until all URBs have been reaped before freeing them (#607)
* NetBSD: Recognize device timeouts (#710)
* OpenBSD: Allow opening ugen devices multiple times (#763)
* OpenBSD: Support libusb_get_port_number() (#764)
--- a/libusb/version_nano.h
+++ b/libusb/version_nano.h
@@ -1 +1 @@
-#define LIBUSB_NANO 11584
+#define LIBUSB_NANO 11585

View File

@ -1,61 +0,0 @@
From f6d2cb561402c3b6d3627c0eb89e009b503d9067 Mon Sep 17 00:00:00 2001
From: Chris Dickens <christopher.a.dickens@gmail.com>
Date: Sun, 13 Dec 2020 15:49:19 -0800
Subject: [PATCH] linux_usbfs: Fix parsing of descriptors for
multi-configuration devices
Commit e2be556bd2 ("linux_usbfs: Parse config descriptors during device
initialization") introduced a regression for devices with multiple
configurations. The logic that verifies the reported length of the
configuration descriptors failed to count the length of the
configuration descriptor itself and would truncate the actual length by
9 bytes, leading to a parsing error for subsequent descriptors.
Closes #825
Signed-off-by: Chris Dickens <christopher.a.dickens@gmail.com>
---
libusb/os/linux_usbfs.c | 12 ++++++++----
libusb/version_nano.h | 2 +-
2 files changed, 9 insertions(+), 5 deletions(-)
--- a/libusb/os/linux_usbfs.c
+++ b/libusb/os/linux_usbfs.c
@@ -641,7 +641,12 @@ static int seek_to_next_config(struct li
uint8_t *buffer, size_t len)
{
struct usbi_descriptor_header *header;
- int offset = 0;
+ int offset;
+
+ /* Start seeking past the config descriptor */
+ offset = LIBUSB_DT_CONFIG_SIZE;
+ buffer += LIBUSB_DT_CONFIG_SIZE;
+ len -= LIBUSB_DT_CONFIG_SIZE;
while (len > 0) {
if (len < 2) {
@@ -718,7 +723,7 @@ static int parse_config_descriptors(stru
}
if (priv->sysfs_dir) {
- /*
+ /*
* In sysfs wTotalLength is ignored, instead the kernel returns a
* config descriptor with verified bLength fields, with descriptors
* with an invalid bLength removed.
@@ -727,8 +732,7 @@ static int parse_config_descriptors(stru
int offset;
if (num_configs > 1 && idx < num_configs - 1) {
- offset = seek_to_next_config(ctx, buffer + LIBUSB_DT_CONFIG_SIZE,
- remaining - LIBUSB_DT_CONFIG_SIZE);
+ offset = seek_to_next_config(ctx, buffer, remaining);
if (offset < 0)
return offset;
sysfs_config_len = (uint16_t)offset;
--- a/libusb/version_nano.h
+++ b/libusb/version_nano.h
@@ -1 +1 @@
-#define LIBUSB_NANO 11585
+#define LIBUSB_NANO 11586

View File

@ -0,0 +1,32 @@
From f374d52079111a4340acb6df835f45ac6b5f3f60 Mon Sep 17 00:00:00 2001
From: Andre Heider <a.heider@gmail.com>
Date: Wed, 22 Jun 2022 14:13:55 +0200
Subject: OpenSSL: Include rsa.h for all OpenSSL versions
This fixes the build with OpenSSL 1.1.1:
../src/crypto/crypto_openssl.c: In function 'crypto_rsa_oaep_sha256_decrypt':
../src/crypto/crypto_openssl.c:4404:49: error: 'RSA_PKCS1_OAEP_PADDING' undeclared (first use in this function)
Signed-off-by: Andre Heider <a.heider@gmail.com>
---
src/crypto/crypto_openssl.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/src/crypto/crypto_openssl.c
+++ b/src/crypto/crypto_openssl.c
@@ -16,6 +16,7 @@
#include <openssl/dh.h>
#include <openssl/hmac.h>
#include <openssl/rand.h>
+#include <openssl/rsa.h>
#include <openssl/pem.h>
#ifdef CONFIG_ECC
#include <openssl/ec.h>
@@ -25,7 +26,6 @@
#include <openssl/provider.h>
#include <openssl/core_names.h>
#include <openssl/param_build.h>
-#include <openssl/rsa.h>
#include <openssl/encoder.h>
#include <openssl/decoder.h>
#else /* OpenSSL version >= 3.0 */

View File

@ -8,12 +8,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=lldpd
PKG_VERSION:=1.0.13
PKG_RELEASE:=3
PKG_VERSION:=1.0.14
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://media.luffy.cx/files/lldpd
PKG_HASH:=d639827fd8a27720d1bfd94bc52eca24af63ddcc3c9d2da60788778889d84701
PKG_SOURCE_URL:=https://codeload.github.com/lldpd/lldpd/tar.gz/$(PKG_VERSION)?
PKG_HASH:=0cb77fd7634401347b8311db1bf64d4fc3890acba90915e2cc2c5f79045ddbf0
PKG_MAINTAINER:=Stijn Tintel <stijn@linux-ipv6.be>
PKG_LICENSE:=ISC

View File

@ -9,12 +9,12 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=iptables
PKG_VERSION:=1.8.7
PKG_RELEASE:=7
PKG_VERSION:=1.8.8
PKG_RELEASE:=1
PKG_SOURCE_URL:=https://netfilter.org/projects/iptables/files
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_HASH:=c109c96bb04998cd44156622d36f8e04b140701ec60531a10668cfdff5e8d8f0
PKG_HASH:=71c75889dc710676631553eb1511da0177bbaaf1b551265b912d236c3f51859f
PKG_FIXUP:=autoreconf
PKG_FLAGS:=nonshared
@ -650,7 +650,6 @@ define Build/InstallDev
$(CP) $(PKG_BUILD_DIR)/include/iptables/*.h $(1)/usr/include/iptables/
$(CP) $(PKG_BUILD_DIR)/include/iptables.h $(1)/usr/include/
$(CP) $(PKG_BUILD_DIR)/include/ip6tables.h $(1)/usr/include/
$(CP) $(PKG_BUILD_DIR)/include/libipulog $(1)/usr/include/
$(CP) $(PKG_BUILD_DIR)/include/libiptc $(1)/usr/include/
$(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/

View File

@ -1,68 +0,0 @@
From e727ccad036e2cdba3339536c65c7ceef43c0740 Mon Sep 17 00:00:00 2001
From: Erik Wilson <erik.e.wilson@gmail.com>
Date: Tue, 13 Jul 2021 16:48:23 -0700
Subject: [PATCH] xtables: Call init_extensions6() for static builds
Initialize extensions from libext6 for cases where xtables is built statically.
Closes: https://bugzilla.netfilter.org/show_bug.cgi?id=1550
Signed-off-by: Erik Wilson <Erik.E.Wilson@gmail.com>
Signed-off-by: Florian Westphal <fw@strlen.de>
---
iptables/xtables-monitor.c | 1 +
iptables/xtables-restore.c | 1 +
iptables/xtables-save.c | 1 +
iptables/xtables-standalone.c | 1 +
iptables/xtables-translate.c | 1 +
5 files changed, 5 insertions(+)
--- a/iptables/xtables-monitor.c
+++ b/iptables/xtables-monitor.c
@@ -628,6 +628,7 @@ int xtables_monitor_main(int argc, char
#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
init_extensions();
init_extensions4();
+ init_extensions6();
#endif
if (nft_init(&h, AF_INET, xtables_ipv4)) {
--- a/iptables/xtables-restore.c
+++ b/iptables/xtables-restore.c
@@ -364,6 +364,7 @@ xtables_restore_main(int family, const c
#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
init_extensions();
init_extensions4();
+ init_extensions6();
#endif
break;
case NFPROTO_ARP:
--- a/iptables/xtables-save.c
+++ b/iptables/xtables-save.c
@@ -202,6 +202,7 @@ xtables_save_main(int family, int argc,
#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
init_extensions();
init_extensions4();
+ init_extensions6();
#endif
tables = xtables_ipv4;
d.commit = true;
--- a/iptables/xtables-standalone.c
+++ b/iptables/xtables-standalone.c
@@ -57,6 +57,7 @@ xtables_main(int family, const char *pro
#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
init_extensions();
init_extensions4();
+ init_extensions6();
#endif
if (nft_init(&h, family, xtables_ipv4) < 0) {
--- a/iptables/xtables-translate.c
+++ b/iptables/xtables-translate.c
@@ -469,6 +469,7 @@ static int xtables_xlate_main_common(str
#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
init_extensions();
init_extensions4();
+ init_extensions6();
#endif
tables = xtables_ipv4;
break;

View File

@ -1,107 +0,0 @@
A modified version of this patch was commited upstream
as part of a fixup series
https://bugzilla.netfilter.org/show_bug.cgi?id=1593
https://git.netfilter.org/iptables/commit/?id=0836524f093c0fd9c39604a46a949e43d9b47ef2
--- a/iptables/xtables-monitor.c
+++ b/iptables/xtables-monitor.c
@@ -629,6 +629,8 @@ int xtables_monitor_main(int argc, char
init_extensions();
init_extensions4();
init_extensions6();
+ init_extensionsa();
+ init_extensionsb();
#endif
if (nft_init(&h, AF_INET, xtables_ipv4)) {
--- a/iptables/xtables-restore.c
+++ b/iptables/xtables-restore.c
@@ -368,9 +368,17 @@ xtables_restore_main(int family, const c
#endif
break;
case NFPROTO_ARP:
+#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
+ init_extensions();
+ init_extensionsa();
+#endif
tables = xtables_arp;
break;
case NFPROTO_BRIDGE:
+#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
+ init_extensions();
+ init_extensionsb();
+#endif
tables = xtables_bridge;
break;
default:
--- a/iptables/xtables-save.c
+++ b/iptables/xtables-save.c
@@ -208,9 +208,17 @@ xtables_save_main(int family, int argc,
d.commit = true;
break;
case NFPROTO_ARP:
+#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
+ init_extensions();
+ init_extensionsa();
+#endif
tables = xtables_arp;
break;
case NFPROTO_BRIDGE: {
+#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
+ init_extensions();
+ init_extensionsb();
+#endif
const char *ctr = getenv("EBTABLES_SAVE_COUNTER");
if (!(d.format & FMT_NOCOUNTS)) {
--- a/iptables/xtables-standalone.c
+++ b/iptables/xtables-standalone.c
@@ -58,6 +58,8 @@ xtables_main(int family, const char *pro
init_extensions();
init_extensions4();
init_extensions6();
+ init_extensionsa();
+ init_extensionsb();
#endif
if (nft_init(&h, family, xtables_ipv4) < 0) {
--- a/iptables/xtables-translate.c
+++ b/iptables/xtables-translate.c
@@ -474,9 +474,17 @@ static int xtables_xlate_main_common(str
tables = xtables_ipv4;
break;
case NFPROTO_ARP:
+#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
+ init_extensions();
+ init_extensionsa();
+#endif
tables = xtables_arp;
break;
case NFPROTO_BRIDGE:
+#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
+ init_extensions();
+ init_extensionsb();
+#endif
tables = xtables_bridge;
break;
default:
--- a/iptables/xtables-arp.c
+++ b/iptables/xtables-arp.c
@@ -438,6 +438,7 @@ int nft_init_arp(struct nft_handle *h, c
}
#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
+ init_extensions();
init_extensionsa();
#endif
--- a/iptables/xtables-eb.c
+++ b/iptables/xtables-eb.c
@@ -685,6 +685,7 @@ int nft_init_eb(struct nft_handle *h, co
}
#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
+ init_extensions();
init_extensionsb();
#endif

View File

@ -0,0 +1,144 @@
From f319389525b066b7dc6d389c88f16a0df3b8f189 Mon Sep 17 00:00:00 2001
From: Nick Hainke <vincent@systemli.org>
Date: Mon, 16 May 2022 18:16:41 +0200
Subject: treewide: use uint* instead of u_int*
Gcc complains about missing types. Some commits introduced u_int* instead
of uint*. Use uint treewide.
Fixes errors in the form of:
In file included from xtables-legacy-multi.c:5:
xshared.h:83:56: error: unknown type name 'u_int16_t'; did you mean 'uint16_t'?
83 | set_option(unsigned int *options, unsigned int option, u_int16_t *invflg,
| ^~~~~~~~~
| uint16_t
make[6]: *** [Makefile:712: xtables_legacy_multi-xtables-legacy-multi.o] Error 1
Avoid libipq API breakage by adjusting libipq.h include accordingly. For
arpt_mangle.h kernel uAPI header, apply same change as in kernel commit
e91ded8db5747 ("uapi: netfilter_arp: use __u8 instead of u_int8_t").
Signed-off-by: Nick Hainke <vincent@systemli.org>
Signed-off-by: Phil Sutter <phil@nwl.cc>
---
extensions/libxt_conntrack.c | 2 +-
include/libipq/libipq.h | 8 ++++----
include/libiptc/libxtc.h | 2 +-
include/linux/netfilter_arp/arpt_mangle.h | 2 +-
iptables/xshared.c | 2 +-
iptables/xshared.h | 2 +-
libipq/ipq_create_handle.3 | 2 +-
libipq/ipq_set_mode.3 | 2 +-
8 files changed, 11 insertions(+), 11 deletions(-)
--- a/extensions/libxt_conntrack.c
+++ b/extensions/libxt_conntrack.c
@@ -778,7 +778,7 @@ matchinfo_print(const void *ip, const st
static void
conntrack_dump_ports(const char *prefix, const char *opt,
- u_int16_t port_low, u_int16_t port_high)
+ uint16_t port_low, uint16_t port_high)
{
if (port_high == 0 || port_low == port_high)
printf(" %s%s %u", prefix, opt, port_low);
--- a/include/libipq/libipq.h
+++ b/include/libipq/libipq.h
@@ -24,7 +24,7 @@
#include <errno.h>
#include <unistd.h>
#include <fcntl.h>
-#include <sys/types.h>
+#include <stdint.h>
#include <sys/socket.h>
#include <sys/uio.h>
#include <asm/types.h>
@@ -48,19 +48,19 @@ typedef unsigned long ipq_id_t;
struct ipq_handle
{
int fd;
- u_int8_t blocking;
+ uint8_t blocking;
struct sockaddr_nl local;
struct sockaddr_nl peer;
};
-struct ipq_handle *ipq_create_handle(u_int32_t flags, u_int32_t protocol);
+struct ipq_handle *ipq_create_handle(uint32_t flags, uint32_t protocol);
int ipq_destroy_handle(struct ipq_handle *h);
ssize_t ipq_read(const struct ipq_handle *h,
unsigned char *buf, size_t len, int timeout);
-int ipq_set_mode(const struct ipq_handle *h, u_int8_t mode, size_t len);
+int ipq_set_mode(const struct ipq_handle *h, uint8_t mode, size_t len);
ipq_packet_msg_t *ipq_get_packet(const unsigned char *buf);
--- a/include/libiptc/libxtc.h
+++ b/include/libiptc/libxtc.h
@@ -10,7 +10,7 @@ extern "C" {
#endif
#ifndef XT_MIN_ALIGN
-/* xt_entry has pointers and u_int64_t's in it, so if you align to
+/* xt_entry has pointers and uint64_t's in it, so if you align to
it, you'll also align to any crazy matches and targets someone
might write */
#define XT_MIN_ALIGN (__alignof__(struct xt_entry))
--- a/include/linux/netfilter_arp/arpt_mangle.h
+++ b/include/linux/netfilter_arp/arpt_mangle.h
@@ -13,7 +13,7 @@ struct arpt_mangle
union {
struct in_addr tgt_ip;
} u_t;
- u_int8_t flags;
+ __u8 flags;
int target;
};
--- a/iptables/xshared.c
+++ b/iptables/xshared.c
@@ -1025,7 +1025,7 @@ static const int inverse_for_options[NUM
};
void
-set_option(unsigned int *options, unsigned int option, u_int16_t *invflg,
+set_option(unsigned int *options, unsigned int option, uint16_t *invflg,
bool invert)
{
if (*options & option)
--- a/iptables/xshared.h
+++ b/iptables/xshared.h
@@ -80,7 +80,7 @@ struct xtables_target;
#define IPT_INV_ARPHRD 0x0800
void
-set_option(unsigned int *options, unsigned int option, u_int16_t *invflg,
+set_option(unsigned int *options, unsigned int option, uint16_t *invflg,
bool invert);
/**
--- a/libipq/ipq_create_handle.3
+++ b/libipq/ipq_create_handle.3
@@ -24,7 +24,7 @@ ipq_create_handle, ipq_destroy_handle \(
.br
.B #include <libipq.h>
.sp
-.BI "struct ipq_handle *ipq_create_handle(u_int32_t " flags ", u_int32_t " protocol ");"
+.BI "struct ipq_handle *ipq_create_handle(uint32_t " flags ", uint32_t " protocol ");"
.br
.BI "int ipq_destroy_handle(struct ipq_handle *" h );
.SH DESCRIPTION
--- a/libipq/ipq_set_mode.3
+++ b/libipq/ipq_set_mode.3
@@ -24,7 +24,7 @@ ipq_set_mode \(em set the ip_queue queui
.br
.B #include <libipq.h>
.sp
-.BI "int ipq_set_mode(const struct ipq_handle *" h ", u_int8_t " mode ", size_t " range );
+.BI "int ipq_set_mode(const struct ipq_handle *" h ", uint8_t " mode ", size_t " range );
.SH DESCRIPTION
The
.B ipq_set_mode

View File

@ -0,0 +1,60 @@
From 0e7cf0ad306cdf95dc3c28d15a254532206a888e Mon Sep 17 00:00:00 2001
From: Phil Sutter <phil@nwl.cc>
Date: Wed, 18 May 2022 16:04:09 +0200
Subject: Revert "fix build for missing ETH_ALEN definition"
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
This reverts commit c5d9a723b5159a28f547b577711787295a14fd84 as it broke
compiling against musl libc. Might be a bug in the latter, but for the
time being try to please both by avoiding the include and instead
defining ETH_ALEN if unset.
While being at it, move netinet/ether.h include up.
Fixes: 1bdb5535f561a ("libxtables: Extend MAC address printing/parsing support")
Signed-off-by: Phil Sutter <phil@nwl.cc>
Reviewed-by: Maciej Żenczykowski <maze@google.com>
---
libxtables/xtables.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
--- a/libxtables/xtables.c
+++ b/libxtables/xtables.c
@@ -28,6 +28,7 @@
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
+#include <netinet/ether.h>
#include <sys/socket.h>
#include <sys/stat.h>
#include <sys/statfs.h>
@@ -45,7 +46,6 @@
#include <xtables.h>
#include <limits.h> /* INT_MAX in ip_tables.h/ip6_tables.h */
-#include <linux/if_ether.h> /* ETH_ALEN */
#include <linux/netfilter_ipv4/ip_tables.h>
#include <linux/netfilter_ipv6/ip6_tables.h>
#include <libiptc/libxtc.h>
@@ -72,6 +72,10 @@
#define PROC_SYS_MODPROBE "/proc/sys/kernel/modprobe"
#endif
+#ifndef ETH_ALEN
+#define ETH_ALEN 6
+#endif
+
/* we need this for ip6?tables-restore. ip6?tables-restore.c sets line to the
* current line of the input file, in order to give a more precise error
* message. ip6?tables itself doesn't need this, so it is initialized to the
@@ -2245,8 +2249,6 @@ void xtables_print_num(uint64_t number,
printf(FMT("%4lluT ","%lluT "), (unsigned long long)number);
}
-#include <netinet/ether.h>
-
static const unsigned char mac_type_unicast[ETH_ALEN] = {};
static const unsigned char msk_type_unicast[ETH_ALEN] = {1};
static const unsigned char mac_type_multicast[ETH_ALEN] = {1};

View File

@ -0,0 +1,23 @@
From b72eb12ea5a61df0655ad99d5048994e916be83a Mon Sep 17 00:00:00 2001
From: Phil Sutter <phil@nwl.cc>
Date: Fri, 13 May 2022 16:51:58 +0200
Subject: [PATCH] xshared: Fix build for -Werror=format-security
Gcc complains about the omitted format string.
Signed-off-by: Phil Sutter <phil@nwl.cc>
---
iptables/xshared.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/iptables/xshared.c
+++ b/iptables/xshared.c
@@ -1307,7 +1307,7 @@ static void check_empty_interface(struct
return;
if (args->family != NFPROTO_ARP)
- xtables_error(PARAMETER_PROBLEM, msg);
+ xtables_error(PARAMETER_PROBLEM, "%s", msg);
fprintf(stderr, "%s", msg);
}

View File

@ -0,0 +1,28 @@
From 0ebf52fc951b2a4d98a166afb34af4f364bbeece Mon Sep 17 00:00:00 2001
From: Ben Brown <ben@demerara.io>
Date: Wed, 25 May 2022 16:26:13 +0100
Subject: build: Fix error during out of tree build
Fixes the following error:
../../libxtables/xtables.c:52:10: fatal error: libiptc/linux_list.h: No such file or directory
52 | #include <libiptc/linux_list.h>
Fixes: f58b0d7406451 ("libxtables: Implement notargets hash table")
Signed-off-by: Ben Brown <ben@demerara.io>
Signed-off-by: Phil Sutter <phil@nwl.cc>
---
libxtables/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/libxtables/Makefile.am
+++ b/libxtables/Makefile.am
@@ -1,7 +1,7 @@
# -*- Makefile -*-
AM_CFLAGS = ${regular_CFLAGS}
-AM_CPPFLAGS = ${regular_CPPFLAGS} -I${top_builddir}/include -I${top_srcdir}/include -I${top_srcdir}/iptables ${kinclude_CPPFLAGS}
+AM_CPPFLAGS = ${regular_CPPFLAGS} -I${top_builddir}/include -I${top_srcdir}/include -I${top_srcdir}/iptables -I${top_srcdir} ${kinclude_CPPFLAGS}
lib_LTLIBRARIES = libxtables.la
libxtables_la_SOURCES = xtables.c xtoptions.c getethertype.c

View File

@ -0,0 +1,82 @@
From ef108943f69a6e20533d58823740d3f0534ea8ec Mon Sep 17 00:00:00 2001
From: Phil Sutter <phil@nwl.cc>
Date: Wed, 1 Jun 2022 19:15:06 +0200
Subject: libxtables: Unexport init_extensions*() declarations
The functions are used for static builds to initialize extensions after
libxtables init. Regular library users should not need them, but the
empty declarations introduced in #else case (and therefore present in
user's env) may clash with existing symbol names.
Avoid problems and guard the whole block declaring the function
prototypes and mangling extensions' _init functions by XTABLES_INTERNAL.
Reported-by: Nick Hainke <vincent@systemli.org>
Fixes: 6c689b639cf8e ("Simplify static build extension loading")
Signed-off-by: Phil Sutter <phil@nwl.cc>
---
include/xtables.h | 44 ++++++++++++++++++++++----------------------
1 file changed, 22 insertions(+), 22 deletions(-)
--- a/include/xtables.h
+++ b/include/xtables.h
@@ -585,27 +585,6 @@ static inline void xtables_print_mark_ma
xtables_print_val_mask(mark, mask, NULL);
}
-#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
-# ifdef _INIT
-# undef _init
-# define _init _INIT
-# endif
- extern void init_extensions(void);
- extern void init_extensions4(void);
- extern void init_extensions6(void);
- extern void init_extensionsa(void);
- extern void init_extensionsb(void);
-#else
-# define _init __attribute__((constructor)) _INIT
-# define EMPTY_FUNC_DEF(x) static inline void x(void) {}
- EMPTY_FUNC_DEF(init_extensions)
- EMPTY_FUNC_DEF(init_extensions4)
- EMPTY_FUNC_DEF(init_extensions6)
- EMPTY_FUNC_DEF(init_extensionsa)
- EMPTY_FUNC_DEF(init_extensionsb)
-# undef EMPTY_FUNC_DEF
-#endif
-
extern const struct xtables_pprot xtables_chain_protos[];
extern uint16_t xtables_parse_protocol(const char *s);
@@ -663,9 +642,30 @@ void xtables_announce_chain(const char *
# define ARRAY_SIZE(x) (sizeof(x) / sizeof(*(x)))
# endif
+#if defined(ALL_INCLUSIVE) || defined(NO_SHARED_LIBS)
+# ifdef _INIT
+# undef _init
+# define _init _INIT
+# endif
+ extern void init_extensions(void);
+ extern void init_extensions4(void);
+ extern void init_extensions6(void);
+ extern void init_extensionsa(void);
+ extern void init_extensionsb(void);
+#else
+# define _init __attribute__((constructor)) _INIT
+# define EMPTY_FUNC_DEF(x) static inline void x(void) {}
+ EMPTY_FUNC_DEF(init_extensions)
+ EMPTY_FUNC_DEF(init_extensions4)
+ EMPTY_FUNC_DEF(init_extensions6)
+ EMPTY_FUNC_DEF(init_extensionsa)
+ EMPTY_FUNC_DEF(init_extensionsb)
+# undef EMPTY_FUNC_DEF
+#endif
+
extern void _init(void);
-#endif
+#endif /* XTABLES_INTERNAL */
#ifdef __cplusplus
} /* extern "C" */

View File

@ -1,6 +1,6 @@
--- a/libxtables/xtables.c
+++ b/libxtables/xtables.c
@@ -968,12 +968,6 @@ void xtables_register_match(struct xtabl
@@ -1093,12 +1093,6 @@ void xtables_register_match(struct xtabl
struct xtables_match **pos;
bool seen_myself = false;
@ -13,7 +13,7 @@
if (me->version == NULL) {
fprintf(stderr, "%s: match %s<%u> is missing a version\n",
xt_params->program_name, me->name, me->revision);
@@ -1152,12 +1146,6 @@ void xtables_register_target(struct xtab
@@ -1277,12 +1271,6 @@ void xtables_register_target(struct xtab
struct xtables_target **pos;
bool seen_myself = false;

View File

@ -1,6 +1,15 @@
--- a/libxtables/xtables.c
+++ b/libxtables/xtables.c
@@ -403,6 +403,7 @@ static char *get_modprobe(void)
@@ -476,7 +476,7 @@ char *xtables_strdup(const char *s)
return dup;
}
-static char *get_modprobe(void)
+__attribute__((unused)) static char *get_modprobe(void)
{
int procfile;
char *ret;
@@ -511,6 +511,7 @@ static char *get_modprobe(void)
int xtables_insmod(const char *modname, const char *modprobe, bool quiet)
{
@ -8,7 +17,7 @@
char *buf = NULL;
char *argv[4];
int status;
@@ -437,6 +438,7 @@ int xtables_insmod(const char *modname,
@@ -545,6 +546,7 @@ int xtables_insmod(const char *modname,
free(buf);
if (WIFEXITED(status) && WEXITSTATUS(status) == 0)
return 0;

View File

@ -60,7 +60,7 @@
.SECONDARY:
@@ -161,11 +181,11 @@ libext4.a: initext4.o ${libext4_objs}
@@ -163,11 +183,11 @@ libext4.a: initext4.o ${libext4_objs}
libext6.a: initext6.o ${libext6_objs}
${AM_VERBOSE_AR} ${AR} crs $@ $^;

View File

@ -18,7 +18,7 @@
-include .*.d
@@ -164,22 +164,22 @@ xt_connlabel_LIBADD = @libnetfilter_conn
@@ -166,22 +166,22 @@ xt_connlabel_LIBADD = @libnetfilter_conn
# handling code in the Makefiles.
#
lib%.o: ${srcdir}/lib%.c

View File

@ -1,6 +1,6 @@
--- a/extensions/libxt_conntrack.c
+++ b/extensions/libxt_conntrack.c
@@ -1395,6 +1395,7 @@ static int conntrack3_mt6_xlate(struct x
@@ -1399,6 +1399,7 @@ static int conntrack3_mt6_xlate(struct x
}
static struct xtables_match conntrack_mt_reg[] = {
@ -8,7 +8,7 @@
{
.version = XTABLES_VERSION,
.name = "conntrack",
@@ -1470,6 +1471,7 @@ static struct xtables_match conntrack_mt
@@ -1474,6 +1475,7 @@ static struct xtables_match conntrack_mt
.alias = conntrack_print_name_alias,
.x6_options = conntrack2_mt_opts,
},
@ -16,7 +16,7 @@
{
.version = XTABLES_VERSION,
.name = "conntrack",
@@ -1502,6 +1504,7 @@ static struct xtables_match conntrack_mt
@@ -1506,6 +1508,7 @@ static struct xtables_match conntrack_mt
.x6_options = conntrack3_mt_opts,
.xlate = conntrack3_mt6_xlate,
},
@ -24,7 +24,7 @@
{
.family = NFPROTO_UNSPEC,
.name = "state",
@@ -1532,6 +1535,8 @@ static struct xtables_match conntrack_mt
@@ -1536,6 +1539,8 @@ static struct xtables_match conntrack_mt
.x6_parse = state_ct23_parse,
.x6_options = state_opts,
},
@ -33,7 +33,7 @@
{
.family = NFPROTO_UNSPEC,
.name = "state",
@@ -1561,6 +1566,7 @@ static struct xtables_match conntrack_mt
@@ -1565,6 +1570,7 @@ static struct xtables_match conntrack_mt
.x6_parse = state_parse,
.x6_options = state_opts,
},
@ -77,7 +77,7 @@
void _init(void)
--- a/extensions/libxt_multiport.c
+++ b/extensions/libxt_multiport.c
@@ -571,6 +571,7 @@ static int multiport_xlate6_v1(struct xt
@@ -591,6 +591,7 @@ static int multiport_xlate6_v1(struct xt
}
static struct xtables_match multiport_mt_reg[] = {
@ -85,7 +85,7 @@
{
.family = NFPROTO_IPV4,
.name = "multiport",
@@ -601,6 +602,7 @@ static struct xtables_match multiport_mt
@@ -621,6 +622,7 @@ static struct xtables_match multiport_mt
.x6_options = multiport_opts,
.xlate = multiport_xlate6,
},

View File

@ -1,18 +1,17 @@
# SPDX-License-Identifier: GPL-2.0-only
#
# Copyright (C) 2015 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=wpan-tools
PKG_VERSION:=0.7
PKG_VERSION:=0.9
PKG_RELEASE=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=http://wpan.cakelab.org/releases/
PKG_HASH:=c16de9d7861c2d9b6a4436a0fac730f9f545ee290b92bc770c538ec6a3f22309
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://github.com/linux-wpan/wpan-tools/releases/download/$(PKG_NAME)-$(PKG_VERSION)/$(PKG_NAME)-$(PKG_VERSION).tar.gz?
PKG_HASH:=fa76d9c1874220e4b1f91c226f42baf1e372ea8ccf4b892effaf0d164448f608
include $(INCLUDE_DIR)/package.mk
@ -20,7 +19,7 @@ define Package/wpan-tools
SECTION:=net
CATEGORY:=Network
TITLE:=cfg802154 interface configuration utility
URL:=http://wpan.cakelab.org/
URL:=https://linux-wpan.org/wpan-tools.html
DEPENDS:= +libnl
endef

View File

@ -1,44 +0,0 @@
From bb522bd584f05e6658d5dba97f48ca018f46394c Mon Sep 17 00:00:00 2001
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Date: Sat, 6 May 2017 14:36:08 +0200
Subject: [PATCH] src/nl_extras.h: fix compatibility with libnl 3.3.0
nl_extras.h defines a set of nla_set_s*() functions if not provided by
libnl. They are provided by libnl since version 3.2.26. The test
(LIBNL_VER_MIC <= 26) was working fine while libnl was in the 3.2.x
series, but now that they have incremented the minor version, the
micro version was reset to 0, with the latest libnl version being
3.3.0.
Due to this, the condition (LIBNL_VER_MIC <= 26) is true, and we get
redefinition errors because nl_extras.h redefines functions already
provided by libnl.
This commit improves the condition so that nl_extras.h provides the
missing functions only if the minor version is < 2, or if minor is 2
and micro is < 26.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
---
src/nl_extras.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- a/src/nl_extras.h
+++ b/src/nl_extras.h
@@ -1,7 +1,7 @@
#ifndef __NL_EXTRAS_H
#define __NL_EXTRAS_H
-#if LIBNL_VER_MIC <= 26
+#if (LIBNL_VER_MIN < 2) || (LIBNL_VER_MIN == 2) && (LIBNL_VER_MIC <= 26)
#ifndef NLA_S8
@@ -45,6 +45,6 @@ static inline int32_t nla_get_s32(struct
#endif /* NLA_S64 */
-#endif /* LIBNL_VER_MIC */
+#endif /* LIBNL_VER_* */
#endif /* __NL_EXTRAS_H */

View File

@ -3488,9 +3488,9 @@ index f4d2fc20397c..bed192b085df 100644
+ "PWR_LED_OFF",
+ "GLOBAL_RESET",
+ "VDD_SD_IO_SEL",
+ "CAM_GPIO",
+ "GLOBAL_SHUTDOWN",
+ "SD_PWR_ON",
+ "SD_OC_N";
+ "SHUTDOWN_REQUEST";
+ status = "okay";
+ };
+
@ -4003,12 +4003,12 @@ index f4d2fc20397c..bed192b085df 100644
-&expgpio {
- gpio-line-names = "BT_ON",
- "WL_ON",
- "",
- "PWR_LED_OFF",
- "GLOBAL_RESET",
- "VDD_SD_IO_SEL",
- "CAM_GPIO",
- "GLOBAL_SHUTDOWN",
- "SD_PWR_ON",
- "SD_OC_N";
- "SHUTDOWN_REQUEST";
+&pwm1 {
+ status = "disabled";
+};

View File

@ -12,7 +12,7 @@ Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -3552,6 +3552,13 @@ N: bcm113*
@@ -3554,6 +3554,13 @@ N: bcm113*
N: bcm216*
N: kona

View File

@ -15,7 +15,7 @@ Signed-off-by: Jonathan Bell <jonathan@raspberrypi.org>
--- a/drivers/usb/host/xhci.c
+++ b/drivers/usb/host/xhci.c
@@ -1607,6 +1607,109 @@ command_cleanup:
@@ -1618,6 +1618,109 @@ command_cleanup:
}
/*
@ -125,7 +125,7 @@ Signed-off-by: Jonathan Bell <jonathan@raspberrypi.org>
* non-error returns are a promise to giveback() the urb later
* we drop ownership so next owner (or urb unlink) can get it
*/
@@ -5432,6 +5535,7 @@ static const struct hc_driver xhci_hc_dr
@@ -5443,6 +5546,7 @@ static const struct hc_driver xhci_hc_dr
.endpoint_reset = xhci_endpoint_reset,
.check_bandwidth = xhci_check_bandwidth,
.reset_bandwidth = xhci_reset_bandwidth,

View File

@ -90,7 +90,7 @@ Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
+...
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -3552,6 +3552,13 @@ N: bcm113*
@@ -3554,6 +3554,13 @@ N: bcm113*
N: bcm216*
N: kona

View File

@ -28,7 +28,7 @@ Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -3560,7 +3560,7 @@ F: Documentation/devicetree/bindings/med
@@ -3562,7 +3562,7 @@ F: Documentation/devicetree/bindings/med
F: drivers/staging/media/rpivid
BROADCOM BCM2835 CAMERA DRIVER

View File

@ -31,7 +31,7 @@ Reported-by: kbuild test robot <lkp@intel.com>
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -3564,7 +3564,7 @@ M: Raspberry Pi Kernel Maintenance <kern
@@ -3566,7 +3566,7 @@ M: Raspberry Pi Kernel Maintenance <kern
L: linux-media@vger.kernel.org
S: Maintained
F: drivers/media/platform/bcm2835/

View File

@ -25,7 +25,7 @@ Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -17516,6 +17516,14 @@ T: git git://linuxtv.org/media_tree.git
@@ -17525,6 +17525,14 @@ T: git git://linuxtv.org/media_tree.git
F: Documentation/devicetree/bindings/media/i2c/sony,imx412.yaml
F: drivers/media/i2c/imx412.c

View File

@ -35,7 +35,7 @@ Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -3566,6 +3566,15 @@ S: Maintained
@@ -3568,6 +3568,15 @@ S: Maintained
F: drivers/media/platform/bcm2835/
F: Documentation/devicetree/bindings/media/brcm,bcm2835-unicam.yaml

View File

@ -132,7 +132,7 @@ Signed-off-by: David Plowman <david.plowman@raspberrypi.com>
+...
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -17530,6 +17530,7 @@ M: Raspberry Pi Kernel Maintenance <kern
@@ -17539,6 +17539,7 @@ M: Raspberry Pi Kernel Maintenance <kern
L: linux-media@vger.kernel.org
S: Maintained
T: git git://linuxtv.org/media_tree.git

View File

@ -132,7 +132,7 @@ Signed-off-by: Lee Jackson <info@arducam.com>
+...
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -17534,6 +17534,14 @@ F: Documentation/devicetree/bindings/med
@@ -17543,6 +17543,14 @@ F: Documentation/devicetree/bindings/med
F: Documentation/devicetree/bindings/media/i2c/imx477.yaml
F: drivers/media/i2c/imx477.c

View File

@ -22,7 +22,7 @@ Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
--- a/drivers/usb/host/xhci-pci.c
+++ b/drivers/usb/host/xhci-pci.c
@@ -300,6 +300,7 @@ static void xhci_pci_quirks(struct devic
@@ -304,6 +304,7 @@ static void xhci_pci_quirks(struct devic
if (pdev->vendor == PCI_VENDOR_ID_VIA && pdev->device == 0x3483) {
xhci->quirks |= XHCI_LPM_SUPPORT;
xhci->quirks |= XHCI_EP_CTX_BROKEN_DCS;

View File

@ -226,7 +226,7 @@ Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
}
--- a/drivers/usb/host/xhci.c
+++ b/drivers/usb/host/xhci.c
@@ -866,8 +866,8 @@ static void xhci_clear_command_ring(stru
@@ -877,8 +877,8 @@ static void xhci_clear_command_ring(stru
seg = ring->deq_seg;
do {
memset(seg->trbs, 0,
@ -237,7 +237,7 @@ Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
cpu_to_le32(~TRB_CYCLE);
seg = seg->next;
} while (seg != ring->deq_seg);
@@ -878,7 +878,7 @@ static void xhci_clear_command_ring(stru
@@ -889,7 +889,7 @@ static void xhci_clear_command_ring(stru
ring->enq_seg = ring->deq_seg;
ring->enqueue = ring->dequeue;

View File

@ -53,7 +53,7 @@ Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
cycle_state, type, max_packet, flags);
--- a/drivers/usb/host/xhci-pci.c
+++ b/drivers/usb/host/xhci-pci.c
@@ -301,6 +301,7 @@ static void xhci_pci_quirks(struct devic
@@ -305,6 +305,7 @@ static void xhci_pci_quirks(struct devic
xhci->quirks |= XHCI_LPM_SUPPORT;
xhci->quirks |= XHCI_EP_CTX_BROKEN_DCS;
xhci->quirks |= XHCI_AVOID_DQ_ON_LINK;

View File

@ -26,7 +26,7 @@ Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
--- a/drivers/usb/host/xhci-pci.c
+++ b/drivers/usb/host/xhci-pci.c
@@ -302,6 +302,7 @@ static void xhci_pci_quirks(struct devic
@@ -306,6 +306,7 @@ static void xhci_pci_quirks(struct devic
xhci->quirks |= XHCI_EP_CTX_BROKEN_DCS;
xhci->quirks |= XHCI_AVOID_DQ_ON_LINK;
xhci->quirks |= XHCI_VLI_TRB_CACHE_BUG;

View File

@ -63,7 +63,7 @@ Link: https://patchwork.freedesktop.org/patch/msgid/20220227124713.39766-6-noral
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -5976,6 +5976,14 @@ T: git git://anongit.freedesktop.org/drm
@@ -5980,6 +5980,14 @@ T: git git://anongit.freedesktop.org/drm
F: Documentation/devicetree/bindings/display/multi-inno,mi0283qt.txt
F: drivers/gpu/drm/tiny/mi0283qt.c

View File

@ -131,7 +131,7 @@ Signed-off-by: Lee Jackson <info@arducam.com>
+...
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -1386,6 +1386,14 @@ S: Maintained
@@ -1388,6 +1388,14 @@ S: Maintained
F: drivers/net/arcnet/
F: include/uapi/linux/if_arcnet.h

View File

@ -14,7 +14,7 @@ Signed-off-by: Johan Almbladh <johan.almbladh@anyfinetworks.com>
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -3428,6 +3428,7 @@ S: Supported
@@ -3430,6 +3430,7 @@ S: Supported
F: arch/arm64/net/
BPF JIT for MIPS (32-BIT AND 64-BIT)

View File

@ -256,7 +256,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -761,6 +761,10 @@ int dev_fill_forward_path(const struct n
@@ -763,6 +763,10 @@ int dev_fill_forward_path(const struct n
if (WARN_ON_ONCE(last_dev == ctx.dev))
return -1;
}

View File

@ -5975,7 +5975,9 @@ CONFIG_SND_PROC_FS=y
# CONFIG_SND_SOC_IMG is not set
# CONFIG_SND_SOC_IMX_AUDMIX is not set
# CONFIG_SND_SOC_IMX_AUDMUX is not set
# CONFIG_SND_SOC_IMX_CARD is not set
# CONFIG_SND_SOC_IMX_ES8328 is not set
# CONFIG_SND_SOC_IMX_HDMI is not set
# CONFIG_SND_SOC_IMX_SPDIF is not set
# CONFIG_SND_SOC_IMX_WM8962 is not set
# CONFIG_SND_SOC_INNO_RK3036 is not set

View File

@ -20,7 +20,7 @@ Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
#define MDIO_PHYXS_VEND_IF_STATUS 0xe812
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_MASK GENMASK(7, 3)
@@ -359,6 +361,49 @@ static int aqr107_read_rate(struct phy_d
@@ -372,6 +374,49 @@ static int aqr107_read_rate(struct phy_d
return 0;
}
@ -70,7 +70,7 @@ Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
static int aqr107_read_status(struct phy_device *phydev)
{
int val, ret;
@@ -489,7 +534,7 @@ static void aqr107_chip_info(struct phy_
@@ -502,7 +547,7 @@ static void aqr107_chip_info(struct phy_
build_id = FIELD_GET(VEND1_GLOBAL_RSVD_STAT1_FW_BUILD_ID, val);
prov_id = FIELD_GET(VEND1_GLOBAL_RSVD_STAT1_PROV_ID, val);
@ -79,7 +79,7 @@ Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
fw_major, fw_minor, build_id, prov_id);
}
@@ -661,6 +706,24 @@ static struct phy_driver aqr_driver[] =
@@ -674,6 +719,24 @@ static struct phy_driver aqr_driver[] =
.link_change_notify = aqr107_link_change_notify,
},
{
@ -104,7 +104,7 @@ Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
PHY_ID_MATCH_MODEL(PHY_ID_AQCS109),
.name = "Aquantia AQCS109",
.probe = aqr107_probe,
@@ -686,6 +749,24 @@ static struct phy_driver aqr_driver[] =
@@ -699,6 +762,24 @@ static struct phy_driver aqr_driver[] =
.handle_interrupt = aqr_handle_interrupt,
.read_status = aqr_read_status,
},
@ -129,7 +129,7 @@ Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
};
module_phy_driver(aqr_driver);
@@ -696,8 +777,10 @@ static struct mdio_device_id __maybe_unu
@@ -709,8 +790,10 @@ static struct mdio_device_id __maybe_unu
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR105) },
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR106) },
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR107) },

View File

@ -20,7 +20,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -1655,6 +1655,10 @@ enum netdev_priv_flags {
IFF_TX_SKB_NO_LINEAR = 1<<31,
IFF_TX_SKB_NO_LINEAR = BIT_ULL(31),
};
+enum netdev_extra_priv_flags {
@ -116,7 +116,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
help
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -3586,6 +3586,11 @@ static int xmit_one(struct sk_buff *skb,
@@ -3588,6 +3588,11 @@ static int xmit_one(struct sk_buff *skb,
if (dev_nit_active(dev))
dev_queue_xmit_nit(skb, dev);

View File

@ -27,7 +27,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
#define PHY_ID_AQR813 0x31c31cb2
#define MDIO_PHYXS_VEND_IF_STATUS 0xe812
@@ -124,6 +126,29 @@
@@ -126,6 +128,29 @@
#define VEND1_GLOBAL_INT_VEND_MASK_GLOBAL2 BIT(1)
#define VEND1_GLOBAL_INT_VEND_MASK_GLOBAL3 BIT(0)
@ -57,7 +57,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
struct aqr107_hw_stat {
const char *name;
int reg;
@@ -244,6 +269,51 @@ static int aqr_config_aneg(struct phy_de
@@ -257,6 +282,51 @@ static int aqr_config_aneg(struct phy_de
return genphy_c45_check_and_restart_aneg(phydev, changed);
}
@ -109,7 +109,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
static int aqr_config_intr(struct phy_device *phydev)
{
bool en = phydev->interrupts == PHY_INTERRUPT_ENABLED;
@@ -767,6 +837,30 @@ static struct phy_driver aqr_driver[] =
@@ -780,6 +850,30 @@ static struct phy_driver aqr_driver[] =
.get_stats = aqr107_get_stats,
.link_change_notify = aqr107_link_change_notify,
},
@ -140,7 +140,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
};
module_phy_driver(aqr_driver);
@@ -777,9 +871,11 @@ static struct mdio_device_id __maybe_unu
@@ -790,9 +884,11 @@ static struct mdio_device_id __maybe_unu
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR105) },
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR106) },
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR107) },

View File

@ -14,7 +14,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
--- a/drivers/net/phy/aquantia_main.c
+++ b/drivers/net/phy/aquantia_main.c
@@ -302,10 +302,16 @@ static int aqr_config_aneg_set_prot(stru
@@ -315,10 +315,16 @@ static int aqr_config_aneg_set_prot(stru
phy_write_mmd(phydev, MDIO_MMD_VEND1, AQUANTIA_VND1_GSTART_RATE,
aquantia_syscfg[if_type].start_rate);

View File

@ -18,7 +18,7 @@ Add a new entry for AQR113 PHY_ID
#define PHY_ID_AQR113C 0x31c31c12
#define PHY_ID_AQCS109 0x03a1b5c2
#define PHY_ID_AQR405 0x03a1b4b0
@@ -856,6 +857,14 @@ static struct phy_driver aqr_driver[] =
@@ -869,6 +870,14 @@ static struct phy_driver aqr_driver[] =
.get_stats = aqr107_get_stats,
},
{
@ -33,7 +33,7 @@ Add a new entry for AQR113 PHY_ID
PHY_ID_MATCH_MODEL(PHY_ID_AQR412),
.name = "Aquantia AQR412",
.probe = aqr107_probe,
@@ -878,6 +887,7 @@ static struct mdio_device_id __maybe_unu
@@ -891,6 +900,7 @@ static struct mdio_device_id __maybe_unu
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR106) },
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR107) },
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR112) },

View File

@ -21,7 +21,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org>
#define PHY_ID_AQR113 0x31c31c40
#define PHY_ID_AQR113C 0x31c31c12
#define PHY_ID_AQCS109 0x03a1b5c2
@@ -857,6 +859,30 @@ static struct phy_driver aqr_driver[] =
@@ -870,6 +872,30 @@ static struct phy_driver aqr_driver[] =
.get_stats = aqr107_get_stats,
},
{
@ -52,7 +52,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org>
PHY_ID_MATCH_MODEL(PHY_ID_AQR113),
.name = "Aquantia AQR113",
.config_aneg = aqr_config_aneg,
@@ -887,6 +913,8 @@ static struct mdio_device_id __maybe_unu
@@ -900,6 +926,8 @@ static struct mdio_device_id __maybe_unu
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR106) },
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR107) },
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR112) },

View File

@ -19,7 +19,7 @@
#define QUECTEL_VENDOR_ID 0x2c7c
/* These Quectel products use Quectel's vendor ID */
@@ -1131,6 +1133,11 @@ static const struct usb_device_id option
@@ -1133,6 +1135,11 @@ static const struct usb_device_id option
{ USB_DEVICE_AND_INTERFACE_INFO(QUECTEL_VENDOR_ID, QUECTEL_PRODUCT_EG95, 0xff, 0, 0) },
{ USB_DEVICE(QUECTEL_VENDOR_ID, QUECTEL_PRODUCT_BG96),
.driver_info = RSVD(4) },

View File

@ -175,7 +175,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org>
/*
* Allocate a dst for local (unicast / anycast) address.
*/
@@ -5040,7 +5070,8 @@ static int rtm_to_fib6_config(struct sk_
@@ -5047,7 +5077,8 @@ static int rtm_to_fib6_config(struct sk_
if (rtm->rtm_type == RTN_UNREACHABLE ||
rtm->rtm_type == RTN_BLACKHOLE ||
rtm->rtm_type == RTN_PROHIBIT ||
@ -185,7 +185,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org>
cfg->fc_flags |= RTF_REJECT;
if (rtm->rtm_type == RTN_LOCAL)
@@ -6293,6 +6324,8 @@ static int ip6_route_dev_notify(struct n
@@ -6300,6 +6331,8 @@ static int ip6_route_dev_notify(struct n
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
net->ipv6.ip6_prohibit_entry->dst.dev = dev;
net->ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(dev);
@ -194,7 +194,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org>
net->ipv6.ip6_blk_hole_entry->dst.dev = dev;
net->ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(dev);
#endif
@@ -6304,6 +6337,7 @@ static int ip6_route_dev_notify(struct n
@@ -6311,6 +6344,7 @@ static int ip6_route_dev_notify(struct n
in6_dev_put_clear(&net->ipv6.ip6_null_entry->rt6i_idev);
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
in6_dev_put_clear(&net->ipv6.ip6_prohibit_entry->rt6i_idev);
@ -202,7 +202,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org>
in6_dev_put_clear(&net->ipv6.ip6_blk_hole_entry->rt6i_idev);
#endif
}
@@ -6495,6 +6529,8 @@ static int __net_init ip6_route_net_init
@@ -6502,6 +6536,8 @@ static int __net_init ip6_route_net_init
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
net->ipv6.fib6_has_custom_rules = false;
@ -211,7 +211,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org>
net->ipv6.ip6_prohibit_entry = kmemdup(&ip6_prohibit_entry_template,
sizeof(*net->ipv6.ip6_prohibit_entry),
GFP_KERNEL);
@@ -6505,11 +6541,21 @@ static int __net_init ip6_route_net_init
@@ -6512,11 +6548,21 @@ static int __net_init ip6_route_net_init
ip6_template_metrics, true);
INIT_LIST_HEAD(&net->ipv6.ip6_prohibit_entry->rt6i_uncached);
@ -234,7 +234,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org>
net->ipv6.ip6_blk_hole_entry->dst.ops = &net->ipv6.ip6_dst_ops;
dst_init_metrics(&net->ipv6.ip6_blk_hole_entry->dst,
ip6_template_metrics, true);
@@ -6536,6 +6582,8 @@ out:
@@ -6543,6 +6589,8 @@ out:
return ret;
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
@ -243,7 +243,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org>
out_ip6_prohibit_entry:
kfree(net->ipv6.ip6_prohibit_entry);
out_ip6_null_entry:
@@ -6555,6 +6603,7 @@ static void __net_exit ip6_route_net_exi
@@ -6562,6 +6610,7 @@ static void __net_exit ip6_route_net_exi
kfree(net->ipv6.ip6_null_entry);
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
kfree(net->ipv6.ip6_prohibit_entry);
@ -251,7 +251,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org>
kfree(net->ipv6.ip6_blk_hole_entry);
#endif
dst_entries_destroy(&net->ipv6.ip6_dst_ops);
@@ -6632,6 +6681,9 @@ void __init ip6_route_init_special_entri
@@ -6639,6 +6688,9 @@ void __init ip6_route_init_special_entri
init_net.ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev);
init_net.ipv6.ip6_blk_hole_entry->dst.dev = init_net.loopback_dev;
init_net.ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev);

View File

@ -32,7 +32,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
__u8 inner_protocol_type:1;
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -6059,6 +6059,9 @@ static enum gro_result dev_gro_receive(s
@@ -6061,6 +6061,9 @@ static enum gro_result dev_gro_receive(s
int same_flow;
int grow;
@ -42,7 +42,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
if (netif_elide_gro(skb->dev))
goto normal;
@@ -8073,6 +8076,48 @@ static void __netdev_adjacent_dev_unlink
@@ -8075,6 +8078,48 @@ static void __netdev_adjacent_dev_unlink
&upper_dev->adj_list.lower);
}
@ -91,7 +91,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
static int __netdev_upper_dev_link(struct net_device *dev,
struct net_device *upper_dev, bool master,
void *upper_priv, void *upper_info,
@@ -8124,6 +8169,7 @@ static int __netdev_upper_dev_link(struc
@@ -8126,6 +8171,7 @@ static int __netdev_upper_dev_link(struc
if (ret)
return ret;
@ -99,7 +99,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
ret = call_netdevice_notifiers_info(NETDEV_CHANGEUPPER,
&changeupper_info.info);
ret = notifier_to_errno(ret);
@@ -8220,6 +8266,7 @@ static void __netdev_upper_dev_unlink(st
@@ -8222,6 +8268,7 @@ static void __netdev_upper_dev_unlink(st
__netdev_adjacent_dev_unlink_neighbour(dev, upper_dev);
@ -107,7 +107,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
call_netdevice_notifiers_info(NETDEV_CHANGEUPPER,
&changeupper_info.info);
@@ -9039,6 +9086,7 @@ int dev_set_mac_address(struct net_devic
@@ -9041,6 +9088,7 @@ int dev_set_mac_address(struct net_devic
if (err)
return err;
dev->addr_assign_type = NET_ADDR_SET;

View File

@ -11,7 +11,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/phy/phy_device.c
+++ b/drivers/net/phy/phy_device.c
@@ -1715,6 +1715,9 @@ void phy_detach(struct phy_device *phyde
@@ -1738,6 +1738,9 @@ void phy_detach(struct phy_device *phyde
struct module *ndev_owner = NULL;
struct mii_bus *bus;
@ -23,7 +23,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
sysfs_remove_link(&dev->dev.kobj, "phydev");
--- a/include/linux/phy.h
+++ b/include/linux/phy.h
@@ -783,6 +783,12 @@ struct phy_driver {
@@ -789,6 +789,12 @@ struct phy_driver {
/** @handle_interrupt: Override default interrupt handling */
irqreturn_t (*handle_interrupt)(struct phy_device *phydev);

View File

@ -0,0 +1,66 @@
#
# Copyright (C) 2010-2013 OpenWrt.org
#
rootpartuuid() {
local cmdline=$(cat /proc/cmdline)
local bootpart=${cmdline##*root=}
bootpart=${bootpart%% *}
local uuid=${bootpart#PARTUUID=}
echo ${uuid%-02}
}
bootdev_from_uuid() {
blkid | grep "PTUUID=\"$(rootpartuuid)\"" | cut -d : -f1
}
bootpart_from_uuid() {
blkid | grep $(rootpartuuid)-01 | cut -d : -f1
}
rootpart_from_uuid() {
blkid | grep $(rootpartuuid)-02 | cut -d : -f1
}
imx_sdcard_mount_boot() {
mkdir -p /boot
[ -f /boot/uImage ] || {
mount -o rw,noatime $(bootpart_from_uuid) /boot > /dev/null
}
}
imx_sdcard_copy_config() {
imx_sdcard_mount_boot
cp -af "$UPGRADE_BACKUP" "/boot/$BACKUP_FILE"
sync
umount /boot
}
imx_sdcard_do_upgrade() {
local board_dir="$(tar tf "${1}" | grep -m 1 '^sysupgrade-.*/$')"
board_dir="${board_dir%/}"
imx_sdcard_mount_boot
get_image "$1" | tar Oxf - ${board_dir}/kernel > /boot/uImage-new && \
mv /boot/uImage-new /boot/uImage && \
sync && \
get_image "$1" | tar Oxf - ${board_dir}/root > $(rootpart_from_uuid) && \
sync
umount /boot
}
imx_sdcard_pre_upgrade() {
[ -z "$UPGRADE_BACKUP" ] && {
jffs2reset -y
umount /overlay
}
}
imx_sdcard_move_config() {
if [ -b $(bootpart_from_uuid) ]; then
imx_sdcard_mount_boot
[ -f "/boot/$BACKUP_FILE" ] && mv -f "/boot/$BACKUP_FILE" /
umount /boot
fi
}

View File

@ -15,6 +15,7 @@ CONFIG_ARCH_SELECT_MEMORY_MODEL=y
CONFIG_ARCH_SPARSEMEM_ENABLE=y
CONFIG_ARCH_SUSPEND_POSSIBLE=y
CONFIG_ARM=y
CONFIG_ARM_ARCH_TIMER=y
CONFIG_ARM_ARCH_TIMER_EVTSTREAM=y
CONFIG_ARM_CRYPTO=y
CONFIG_ARM_ERRATA_754322=y
@ -23,6 +24,7 @@ CONFIG_ARM_ERRATA_775420=y
CONFIG_ARM_ERRATA_814220=y
CONFIG_ARM_HAS_SG_CHAIN=y
CONFIG_ARM_HEAVY_MB=y
# CONFIG_ARM_IMX6Q_CPUFREQ is not set
# CONFIG_ARM_IMX_CPUFREQ_DT is not set
CONFIG_ARM_L1_CACHE_SHIFT=6
CONFIG_ARM_L1_CACHE_SHIFT_6=y
@ -83,6 +85,7 @@ CONFIG_CPU_V7=y
CONFIG_CRC16=y
CONFIG_CRYPTO_AES_ARM=y
CONFIG_CRYPTO_AES_ARM_BS=y
CONFIG_CRYPTO_ARCH_HAVE_LIB_BLAKE2S=y
CONFIG_CRYPTO_ARCH_HAVE_LIB_CHACHA=y
CONFIG_CRYPTO_AUTHENC=y
CONFIG_CRYPTO_BLAKE2S_ARM=y
@ -116,7 +119,6 @@ CONFIG_CRYPTO_HASH_INFO=y
CONFIG_CRYPTO_HMAC=y
CONFIG_CRYPTO_HW=y
CONFIG_CRYPTO_JITTERENTROPY=y
CONFIG_CRYPTO_LIB_BLAKE2S_GENERIC=y
CONFIG_CRYPTO_LIB_CHACHA_GENERIC=y
CONFIG_CRYPTO_LIB_DES=y
CONFIG_CRYPTO_LIB_SHA256=y
@ -157,15 +159,12 @@ CONFIG_EXT4_FS=y
CONFIG_EXT4_FS_POSIX_ACL=y
CONFIG_EXT4_FS_SECURITY=y
CONFIG_EXTCON=y
CONFIG_EXTRA_FIRMWARE="imx/sdma/sdma-imx6q.bin"
CONFIG_EXTRA_FIRMWARE_DIR="firmware"
CONFIG_F2FS_FS=y
# CONFIG_FEC is not set
CONFIG_FEC=y
CONFIG_FIXED_PHY=y
CONFIG_FIX_EARLYCON_MEM=y
# CONFIG_FSL_DPAA2_SWITCH is not set
# CONFIG_FSL_ENETC_IERB is not set
# CONFIG_FSL_IMX8_DDR_PMU is not set
CONFIG_FSL_GUTS=y
CONFIG_FS_ENCRYPTION=y
CONFIG_FS_ENCRYPTION_ALGS=y
CONFIG_FS_IOMAP=y
@ -261,7 +260,9 @@ CONFIG_MMC_BLOCK=y
CONFIG_MMC_CQHCI=y
# CONFIG_MMC_MXC is not set
CONFIG_MMC_SDHCI=y
# CONFIG_MMC_SDHCI_ESDHC_IMX is not set
CONFIG_MMC_SDHCI_ESDHC_IMX=y
CONFIG_MMC_SDHCI_IO_ACCESSORS=y
CONFIG_MMC_SDHCI_OF_ESDHC=y
CONFIG_MMC_SDHCI_PLTFM=y
CONFIG_MODULES_USE_ELF_REL=y
CONFIG_MPILIB=y
@ -342,6 +343,7 @@ CONFIG_RD_XZ=y
CONFIG_REGMAP=y
CONFIG_REGMAP_MMIO=y
CONFIG_REGULATOR=y
CONFIG_REGULATOR_ANATOP=y
CONFIG_REGULATOR_FIXED_VOLTAGE=y
CONFIG_RESET_CONTROLLER=y
CONFIG_RFS_ACCEL=y
@ -364,8 +366,6 @@ CONFIG_SGL_ALLOC=y
CONFIG_SG_POOL=y
CONFIG_SMP=y
CONFIG_SMP_ON_UP=y
# CONFIG_SND_SOC_IMX_CARD is not set
# CONFIG_SND_SOC_IMX_HDMI is not set
CONFIG_SOCK_RX_QUEUE_MAPPING=y
CONFIG_SOC_BUS=y
# CONFIG_SOC_IMX50 is not set
@ -430,6 +430,7 @@ CONFIG_VFPv3=y
CONFIG_VMSPLIT_2G=y
# CONFIG_VMSPLIT_3G is not set
CONFIG_WATCHDOG_CORE=y
CONFIG_XOR_BLOCKS=y
CONFIG_XPS=y
CONFIG_XXHASH=y
CONFIG_XZ_DEC_ARM=y

View File

@ -5,6 +5,9 @@ board=$(board_name)
board_config_update
case "$board" in
technexion,imx7d-pico-pi)
ucidef_set_interface_lan "eth0"
;;
*)
ucidef_set_interfaces_lan_wan "eth0" "eth1"
;;

View File

@ -0,0 +1,15 @@
. /lib/imx.sh
. /lib/functions.sh
. /lib/upgrade/common.sh
move_config() {
local board=$(board_name)
case "$board" in
technexion,imx7d-pico-pi)
imx_sdcard_move_config
;;
esac
}
boot_hook_add preinit_mount_root move_config

View File

@ -1,16 +1,55 @@
PART_NAME=firmware
REQUIRE_IMAGE_METADATA=1
. /lib/imx.sh
RAMFS_COPY_BIN='blkid jffs2reset'
enable_image_metadata_check() {
case "$(board_name)" in
technexion,imx7d-pico-pi)
REQUIRE_IMAGE_METADATA=1
;;
esac
}
enable_image_metadata_check
platform_check_image() {
return 0
local board=$(board_name)
case "$board" in
technexion,imx7d-pico-pi)
return 0
;;
esac
echo "Sysupgrade is not yet supported on $board."
return 1
}
platform_do_upgrade() {
local board=$(board_name)
case "$board" in
*)
default_do_upgrade "$1"
technexion,imx7d-pico-pi)
imx_sdcard_do_upgrade "$1"
;;
esac
}
platform_copy_config() {
local board=$(board_name)
case "$board" in
technexion,imx7d-pico-pi)
imx_sdcard_copy_config
;;
esac
}
platform_pre_upgrade() {
local board=$(board_name)
case "$board" in
technexion,imx7d-pico-pi)
imx_sdcard_pre_upgrade
;;
esac
}

View File

@ -1,28 +1,87 @@
CONFIG_ARM_CPU_SUSPEND=y
CONFIG_ARM_GIC=y
CONFIG_ARM_IMX_CPUFREQ_DT=y
CONFIG_ARM_PSCI=y
CONFIG_ARM_PSCI_FW=y
CONFIG_AT803X_PHY=y
CONFIG_BACKLIGHT_CLASS_DEVICE=y
CONFIG_BACKLIGHT_PWM=y
CONFIG_CLK_IMX6UL=y
CONFIG_CLK_IMX7D=y
CONFIG_CMA=y
CONFIG_CMA_AREAS=7
# CONFIG_CMA_DEBUG is not set
# CONFIG_CMA_DEBUGFS is not set
# CONFIG_CMA_SYSFS is not set
CONFIG_CONSOLE_TRANSLATIONS=y
CONFIG_CONTIG_ALLOC=y
# CONFIG_DMA_CMA is not set
CONFIG_DMA_SHARED_BUFFER=y
CONFIG_DRM=y
CONFIG_DRM_BRIDGE=y
CONFIG_DRM_DISPLAY_CONNECTOR=y
CONFIG_DRM_DP_AUX_BUS=y
CONFIG_DRM_FBDEV_EMULATION=y
CONFIG_DRM_FBDEV_OVERALLOC=100
CONFIG_DRM_GEM_CMA_HELPER=y
CONFIG_DRM_KMS_CMA_HELPER=y
CONFIG_DRM_KMS_HELPER=y
CONFIG_DRM_MXS=y
CONFIG_DRM_MXSFB=y
CONFIG_DRM_PANEL=y
CONFIG_DRM_PANEL_BRIDGE=y
CONFIG_DRM_PANEL_ORIENTATION_QUIRKS=y
CONFIG_DRM_PANEL_SIMPLE=y
CONFIG_DRM_SIMPLE_BRIDGE=y
CONFIG_DUMMY_CONSOLE=y
CONFIG_EXTRA_FIRMWARE="imx/sdma/sdma-imx7d.bin"
CONFIG_EXTRA_FIRMWARE_DIR="firmware"
CONFIG_FB=y
CONFIG_FB_CFB_COPYAREA=y
CONFIG_FB_CFB_FILLRECT=y
CONFIG_FB_CFB_IMAGEBLIT=y
CONFIG_FB_CMDLINE=y
CONFIG_FB_DEFERRED_IO=y
CONFIG_FB_SYS_COPYAREA=y
CONFIG_FB_SYS_FILLRECT=y
CONFIG_FB_SYS_FOPS=y
CONFIG_FB_SYS_IMAGEBLIT=y
CONFIG_FONT_8x16=y
CONFIG_FONT_8x8=y
CONFIG_FONT_SUPPORT=y
CONFIG_FRAMEBUFFER_CONSOLE=y
CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY=y
CONFIG_FRAMEBUFFER_CONSOLE_ROTATION=y
CONFIG_GENERIC_IRQ_EFFECTIVE_AFF_MASK=y
CONFIG_HDMI=y
CONFIG_HW_CONSOLE=y
CONFIG_HW_RANDOM_IMX_RNGC=y
CONFIG_I2C_ALGOBIT=y
CONFIG_IMX_GPCV2=y
CONFIG_IMX_GPCV2_PM_DOMAINS=y
CONFIG_INPUT=y
CONFIG_JFFS2_FS=y
CONFIG_KCMP=y
CONFIG_LEDS_GPIO=y
CONFIG_MEMORY_ISOLATION=y
CONFIG_MTD_SPI_NOR=y
CONFIG_MTD_SPLIT_FIRMWARE=y
CONFIG_MTD_SPLIT_FIT_FW=y
CONFIG_NOP_USB_XCEIV=y
CONFIG_PINCTRL_IMX=y
CONFIG_PINCTRL_IMX6UL=y
CONFIG_PINCTRL_IMX7D=y
CONFIG_PM_GENERIC_DOMAINS=y
CONFIG_PM_GENERIC_DOMAINS_OF=y
CONFIG_RESET_IMX7=y
CONFIG_SOC_IMX6=y
CONFIG_SOC_IMX6UL=y
CONFIG_SOC_IMX7D=y
CONFIG_SOC_IMX7D_CA7=y
CONFIG_SPI_FSL_QUADSPI=y
CONFIG_SPI_MEM=y
CONFIG_USB_CHIPIDEA_IMX=y
CONFIG_USB_EHCI_MXC=y
CONFIG_SYNC_FILE=y
CONFIG_VIDEOMODE_HELPERS=y
CONFIG_VT=y
CONFIG_VT_CONSOLE=y
CONFIG_VT_HW_CONSOLE_BINDING=y

View File

@ -1,30 +0,0 @@
#
# Copyright (C) 2010-2013 OpenWrt.org
#
rootpartuuid() {
local cmdline=$(cat /proc/cmdline)
local bootpart=${cmdline##*root=}
bootpart=${bootpart%% *}
local uuid=${bootpart#PARTUUID=}
echo ${uuid%-02}
}
bootdev_from_uuid() {
blkid | grep "PTUUID=\"$(rootpartuuid)\"" | cut -d : -f1
}
bootpart_from_uuid() {
blkid | grep $(rootpartuuid)-01 | cut -d : -f1
}
rootpart_from_uuid() {
blkid | grep $(rootpartuuid)-02 | cut -d : -f1
}
apalis_mount_boot() {
mkdir -p /boot
[ -f /boot/uImage ] || {
mount -o rw,noatime $(bootpart_from_uuid) /boot > /dev/null
}
}

View File

@ -9,11 +9,7 @@ move_config() {
toradex,apalis_imx6q-eval|\
toradex,apalis_imx6q-ixora|\
toradex,apalis_imx6q-ixora-v1.1)
if [ -b $(bootpart_from_uuid) ]; then
apalis_mount_boot
[ -f "/boot/$BACKUP_FILE" ] && mv -f "/boot/$BACKUP_FILE" /
umount /boot
fi
imx_sdcard_move_config
;;
esac
}

View File

@ -17,21 +17,6 @@ enable_image_metadata_check() {
}
enable_image_metadata_check
apalis_copy_config() {
apalis_mount_boot
cp -af "$UPGRADE_BACKUP" "/boot/$BACKUP_FILE"
sync
umount /boot
}
apalis_do_upgrade() {
apalis_mount_boot
get_image "$1" | tar Oxf - sysupgrade-apalis/kernel > /boot/uImage
get_image "$1" | tar Oxf - sysupgrade-apalis/root > $(rootpart_from_uuid)
sync
umount /boot
}
platform_check_image() {
local board=$(board_name)
@ -109,7 +94,7 @@ platform_do_upgrade() {
toradex,apalis_imx6q-eval|\
toradex,apalis_imx6q-ixora|\
toradex,apalis_imx6q-ixora-v1.1)
apalis_do_upgrade "$1"
imx_sdcard_do_upgrade "$1"
;;
esac
}
@ -121,7 +106,7 @@ platform_copy_config() {
toradex,apalis_imx6q-eval|\
toradex,apalis_imx6q-ixora|\
toradex,apalis_imx6q-ixora-v1.1)
apalis_copy_config
imx_sdcard_copy_config
;;
esac
}
@ -133,10 +118,7 @@ platform_pre_upgrade() {
toradex,apalis_imx6q-eval|\
toradex,apalis_imx6q-ixora|\
toradex,apalis_imx6q-ixora-v1.1)
[ -z "$UPGRADE_BACKUP" ] && {
jffs2reset -y
umount /overlay
}
imx_sdcard_pre_upgrade
;;
esac
}

View File

@ -10,8 +10,8 @@ CONFIG_CLK_IMX6SX=y
CONFIG_CMDLINE="pci=nomsi"
CONFIG_CMDLINE_EXTEND=y
CONFIG_E1000E=y
CONFIG_FEC=y
CONFIG_FSL_GUTS=y
CONFIG_EXTRA_FIRMWARE="imx/sdma/sdma-imx6q.bin"
CONFIG_EXTRA_FIRMWARE_DIR="firmware"
CONFIG_GENERIC_IRQ_EFFECTIVE_AFF_MASK=y
CONFIG_GENERIC_MSI_IRQ=y
CONFIG_GENERIC_MSI_IRQ_DOMAIN=y
@ -22,9 +22,6 @@ CONFIG_HW_RANDOM_IMX_RNGC=y
# CONFIG_INITRAMFS_FORCE is not set
CONFIG_MARVELL_PHY=y
CONFIG_MICREL_PHY=y
CONFIG_MMC_SDHCI_ESDHC_IMX=y
CONFIG_MMC_SDHCI_IO_ACCESSORS=y
CONFIG_MMC_SDHCI_OF_ESDHC=y
# CONFIG_MMC_SDHCI_PCI is not set
CONFIG_NET_DSA_MV88E6XXX=y
CONFIG_PCI=y
@ -45,7 +42,6 @@ CONFIG_PINCTRL_IMX6SX=y
CONFIG_PM_GENERIC_DOMAINS=y
CONFIG_PM_GENERIC_DOMAINS_OF=y
CONFIG_REGMAP_I2C=y
CONFIG_REGULATOR_ANATOP=y
CONFIG_REGULATOR_LTC3676=y
CONFIG_REGULATOR_PFUZE100=y
CONFIG_RTC_DRV_DS1307=y

View File

@ -0,0 +1,18 @@
echo "PICO-PI-IMX7 OpenWrt boot script"
# Initial setup, avoid overwriting environment every boot
if test ${bootm_boot_mode} != nonsec; then setenv bootm_boot_mode nonsec; setenv bootcmd run bootcmd_mmc0; saveenv; fi
# Set console variable for both UART and HDMI
setenv console "console=ttymxc4,115200 console=tty0 video=DPI-1:800x480-32"
setenv fdt_name imx7d-pico-pi.dtb
setenv mmcdev 0
setenv mmcrootpart 2
part uuid mmc ${mmcdev}:${mmcrootpart} uuid
# Boot from eMMC is the only supported option
setenv bootargs "${console} root=PARTUUID=${uuid} rw rootwait"
mmc dev ${mmcdev}
load ${devtype} ${mmcdev}:${devplist} ${kernel_addr_r} /uImage
load ${devtype} ${mmcdev}:${devplist} ${fdt_addr_r} /${fdt_name}
bootm ${kernel_addr_r} - ${fdt_addr_r}

View File

@ -0,0 +1,61 @@
define Build/imx-combined-image-prepare
rm -rf $@.boot
mkdir -p $@.boot
endef
define Build/imx-combined-image-clean
rm -rf $@.boot $@.fs
endef
define Build/imx-combined-image
$(CP) $(IMAGE_KERNEL) $@.boot/uImage
$(foreach dts,$(DEVICE_DTS), \
$(CP) \
$(DTS_DIR)/$(dts).dtb \
$@.boot/;
)
mkimage -A arm -O linux -T script -C none -a 0 -e 0 \
-n '$(DEVICE_ID) OpenWrt bootscript' \
-d bootscript-$(DEVICE_NAME) \
$@.boot/boot.scr
cp $@ $@.fs
$(SCRIPT_DIR)/gen_image_generic.sh $@ \
$(CONFIG_TARGET_KERNEL_PARTSIZE) \
$@.boot \
$(CONFIG_TARGET_ROOTFS_PARTSIZE) \
$@.fs \
1024
endef
define Build/imx-sdcard
$(Build/imx-combined-image-prepare)
if [ -f $(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot.img ]; then \
$(CP) $(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot.img \
$@.boot/u-boot.img; \
fi
if [ -f $(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot-dtb.img ]; then \
$(CP) $(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot-dtb.img \
$@.boot/u-boot-dtb.img; \
fi
$(Build/imx-combined-image)
dd if=$(STAGING_DIR_IMAGE)/$(UBOOT)-SPL of=$@ bs=1024 seek=1 conv=notrunc
$(Build/imx-combined-image-clean)
endef
define Build/imx-sdcard-raw-uboot
$(Build/imx-combined-image-prepare)
$(Build/imx-combined-image)
dd if=$(STAGING_DIR_IMAGE)/$(UBOOT)-SPL of=$@ bs=1024 seek=1 conv=notrunc
dd if=$(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot-dtb.img of=$@ bs=1024 seek=69 conv=notrunc
$(Build/imx-combined-image-clean)
endef

View File

@ -1,3 +1,7 @@
DEVICE_VARS += UBOOT
include common.mk
define Device/Default
PROFILES := Default
FILESYSTEMS := squashfs ext4
@ -8,3 +12,19 @@ define Device/Default
KERNEL_LOADADDR := 0x80008000
IMAGES :=
endef
define Device/technexion_imx7d-pico-pi
DEVICE_VENDOR := TechNexion
DEVICE_MODEL := PICO-PI-IMX7D
UBOOT := pico-pi-imx7d
DEVICE_DTS := imx7d-pico-pi
DEVICE_PACKAGES := kmod-sound-core kmod-sound-soc-imx kmod-sound-soc-imx-sgtl5000 \
kmod-can kmod-can-flexcan kmod-can-raw kmod-leds-gpio \
kmod-input-touchscreen-edt-ft5x06 kmod-usb-hid kmod-btsdio \
kmod-brcmfmac cypress-firmware-4339-sdio cypress-nvram-4339-pico-pi-imx7d
FILESYSTEMS := squashfs
IMAGES := combined.bin sysupgrade.bin
IMAGE/combined.bin := append-rootfs | pad-extra 128k | imx-sdcard-raw-uboot
IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata
endef
TARGET_DEVICES += technexion_imx7d-pico-pi

View File

@ -1,5 +1,7 @@
DEVICE_VARS += MKUBIFS_OPTS UBOOT
include common.mk
define Build/boot-overlay
rm -rf $@.boot
mkdir -p $@.boot
@ -44,62 +46,10 @@ define Build/recovery-scr
-d ./recovery-$(DEVICE_NAME) $@
endef
define Build/imx6-combined-image-prepare
rm -rf $@.boot
mkdir -p $@.boot
endef
define Build/imx6-combined-image-clean
rm -rf $@.boot $@.fs
endef
define Build/imx6-combined-image
$(CP) $(IMAGE_KERNEL) $@.boot/uImage
$(foreach dts,$(DEVICE_DTS), \
$(CP) \
$(DTS_DIR)/$(dts).dtb \
$@.boot/;
)
mkimage -A arm -O linux -T script -C none -a 0 -e 0 \
-n '$(DEVICE_ID) OpenWrt bootscript' \
-d bootscript-$(DEVICE_NAME) \
$@.boot/boot.scr
cp $@ $@.fs
$(SCRIPT_DIR)/gen_image_generic.sh $@ \
$(CONFIG_TARGET_KERNEL_PARTSIZE) \
$@.boot \
$(CONFIG_TARGET_ROOTFS_PARTSIZE) \
$@.fs \
1024
endef
define Build/imx6-sdcard
$(Build/imx6-combined-image-prepare)
if [ -f $(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot.img ]; then \
$(CP) $(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot.img \
$@.boot/u-boot.img; \
fi
if [ -f $(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot-dtb.img ]; then \
$(CP) $(STAGING_DIR_IMAGE)/$(UBOOT)-u-boot-dtb.img \
$@.boot/u-boot-dtb.img; \
fi
$(Build/imx6-combined-image)
dd if=$(STAGING_DIR_IMAGE)/$(UBOOT)-SPL of=$@ bs=1024 seek=1 conv=notrunc
$(Build/imx6-combined-image-clean)
endef
define Build/apalis-emmc
$(Build/imx6-combined-image-prepare)
$(Build/imx6-combined-image)
$(Build/imx6-combined-image-clean)
$(Build/imx-combined-image-prepare)
$(Build/imx-combined-image)
$(Build/imx-combined-image-clean)
endef
@ -184,7 +134,7 @@ define Device/solidrun_cubox-i
KERNEL_SUFFIX := -zImage
FILESYSTEMS := squashfs
IMAGES := combined.bin dtb
IMAGE/combined.bin := append-rootfs | pad-extra 128k | imx6-sdcard
IMAGE/combined.bin := append-rootfs | pad-extra 128k | imx-sdcard
IMAGE/dtb := install-dtb
endef
TARGET_DEVICES += solidrun_cubox-i

View File

@ -0,0 +1,24 @@
--- a/arch/arm/boot/dts/imx7d-pico-pi.dts
+++ b/arch/arm/boot/dts/imx7d-pico-pi.dts
@@ -8,12 +8,20 @@
model = "TechNexion PICO-IMX7D Board and PI baseboard";
compatible = "technexion,imx7d-pico-pi", "fsl,imx7d";
+ aliases {
+ led-boot = &led_system;
+ led-failsafe = &led_system;
+ led-running = &led_system;
+ led-upgrade = &led_system;
+ label-mac-device = &fec1;
+ };
+
leds {
compatible = "gpio-leds";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_gpio_leds>;
- led {
+ led_system: led {
label = "gpio-led";
gpios = <&gpio2 6 GPIO_ACTIVE_HIGH>;
};

View File

@ -0,0 +1,23 @@
From 6e8e5ccfbee7a531b035ffce3f95f3901946fa9d Mon Sep 17 00:00:00 2001
From: Robert Nelson <robertcnelson@gmail.com>
Date: Wed, 9 Jan 2019 14:33:24 -0600
Subject: [PATCH] ARM: imx7d-pico-pi.dts: add default stdout-path
Signed-off-by: Robert Nelson <robertcnelson@gmail.com>
---
arch/arm/boot/dts/imx7d-pico-pi.dts | 4 ++++
1 file changed, 4 insertions(+)
--- a/arch/arm/boot/dts/imx7d-pico-pi.dts
+++ b/arch/arm/boot/dts/imx7d-pico-pi.dts
@@ -16,6 +16,10 @@
label-mac-device = &fec1;
};
+ chosen {
+ stdout-path = "serial4:115200n8";
+ };
+
leds {
compatible = "gpio-leds";
pinctrl-names = "default";

View File

@ -16,7 +16,7 @@ still required by target/linux/ramips/files/drivers/net/ethernet/ralink/mdio.c
--- a/drivers/net/phy/phy.c
+++ b/drivers/net/phy/phy.c
@@ -58,13 +58,13 @@ static const char *phy_state_to_str(enum
@@ -59,13 +59,13 @@ static const char *phy_state_to_str(enum
static void phy_link_up(struct phy_device *phydev)
{
@ -33,7 +33,7 @@ still required by target/linux/ramips/files/drivers/net/ethernet/ralink/mdio.c
phy_led_trigger_change_speed(phydev);
}
@@ -550,7 +550,7 @@ int phy_start_cable_test(struct phy_devi
@@ -551,7 +551,7 @@ int phy_start_cable_test(struct phy_devi
goto out;
/* Mark the carrier down until the test is complete */
@ -42,7 +42,7 @@ still required by target/linux/ramips/files/drivers/net/ethernet/ralink/mdio.c
netif_testing_on(dev);
err = phydev->drv->cable_test_start(phydev);
@@ -621,7 +621,7 @@ int phy_start_cable_test_tdr(struct phy_
@@ -622,7 +622,7 @@ int phy_start_cable_test_tdr(struct phy_
goto out;
/* Mark the carrier down until the test is complete */
@ -51,7 +51,7 @@ still required by target/linux/ramips/files/drivers/net/ethernet/ralink/mdio.c
netif_testing_on(dev);
err = phydev->drv->cable_test_tdr_start(phydev, config);
@@ -693,7 +693,7 @@ static int phy_check_link_status(struct
@@ -694,7 +694,7 @@ static int phy_check_link_status(struct
phy_link_up(phydev);
} else if (!phydev->link && phydev->state != PHY_NOLINK) {
phydev->state = PHY_NOLINK;
@ -60,7 +60,7 @@ still required by target/linux/ramips/files/drivers/net/ethernet/ralink/mdio.c
}
return 0;
@@ -1154,7 +1154,7 @@ void phy_state_machine(struct work_struc
@@ -1177,7 +1177,7 @@ void phy_state_machine(struct work_struc
case PHY_HALTED:
if (phydev->link) {
phydev->link = 0;
@ -71,7 +71,7 @@ still required by target/linux/ramips/files/drivers/net/ethernet/ralink/mdio.c
break;
--- a/drivers/net/phy/phy_device.c
+++ b/drivers/net/phy/phy_device.c
@@ -1000,14 +1000,16 @@ struct phy_device *phy_find_first(struct
@@ -1023,14 +1023,16 @@ struct phy_device *phy_find_first(struct
}
EXPORT_SYMBOL(phy_find_first);
@ -107,7 +107,7 @@ still required by target/linux/ramips/files/drivers/net/ethernet/ralink/mdio.c
bool tx_pause, rx_pause;
--- a/include/linux/phy.h
+++ b/include/linux/phy.h
@@ -663,7 +663,7 @@ struct phy_device {
@@ -669,7 +669,7 @@ struct phy_device {
u8 mdix;
u8 mdix_ctrl;

View File

@ -11,7 +11,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org>
--- a/drivers/net/phy/phy.c
+++ b/drivers/net/phy/phy.c
@@ -693,7 +693,10 @@ static int phy_check_link_status(struct
@@ -694,7 +694,10 @@ static int phy_check_link_status(struct
phy_link_up(phydev);
} else if (!phydev->link && phydev->state != PHY_NOLINK) {
phydev->state = PHY_NOLINK;
@ -23,7 +23,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org>
}
return 0;
@@ -1154,7 +1157,10 @@ void phy_state_machine(struct work_struc
@@ -1177,7 +1180,10 @@ void phy_state_machine(struct work_struc
case PHY_HALTED:
if (phydev->link) {
phydev->link = 0;
@ -37,7 +37,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org>
break;
--- a/include/linux/phy.h
+++ b/include/linux/phy.h
@@ -582,6 +582,7 @@ struct phy_device {
@@ -586,6 +586,7 @@ struct phy_device {
unsigned downshifted_rate:1;
unsigned is_on_sfp_module:1;
unsigned mac_managed_pm:1;

View File

@ -14,6 +14,9 @@
};
keys {
pinctrl-names = "default";
pinctrl-0 = <&pinmux_disable_sys_led>;
compatible = "gpio-keys";
mode {

View File

@ -19,6 +19,9 @@
};
leds {
pinctrl-names = "default";
pinctrl-0 = <&pinmux_disable_sys_led>;
compatible = "gpio-leds";
led_power: power {

View File

@ -15,6 +15,9 @@
};
keys {
pinctrl-names = "default";
pinctrl-0 = <&pinmux_disable_sys_led>;
compatible = "gpio-keys";
reset {

View File

@ -5,11 +5,19 @@
#include <dt-bindings/input/input.h>
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/leds/common.h>
/ {
compatible = "zyxel,xgs1250-12", "realtek,rtl838x-soc";
model = "Zyxel XGS1250-12 Switch";
aliases {
led-boot = &led_pwr_sys;
led-failsafe = &led_pwr_sys;
led-running = &led_pwr_sys;
led-upgrade = &led_pwr_sys;
};
keys {
compatible = "gpio-keys";
@ -31,6 +39,19 @@
clock-frequency = <100000>;
};
leds {
compatible = "gpio-leds";
pinctrl-names = "default";
pinctrl-0 = <&pinmux_disable_sys_led>;
led_pwr_sys: led-0 {
label = "green:power";
color = <LED_COLOR_ID_GREEN>;
function = LED_FUNCTION_POWER;
gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
};
};
sfp0: sfp-p12 {
compatible = "sff,sfp";

View File

@ -135,6 +135,21 @@
};
pinmux_led: pinmux@1b00cc00 {
compatible = "pinctrl-single";
reg = <0x1b00cc00 0x4>;
pinctrl-single,bit-per-mux;
pinctrl-single,register-width = <32>;
pinctrl-single,function-mask = <0x1>;
#pinctrl-cells = <2>;
/* enable GPIO 0 */
pinmux_disable_sys_led: disable_sys_led {
pinctrl-single,bits = <0x0 0x0 0x1000>;
};
};
ethernet0: ethernet@1b00a300 {
compatible = "realtek,rtl838x-eth";
reg = <0x1b00a300 0x100>;

View File

@ -155,6 +155,25 @@
};
};
pinmux: pinmux@1b001358 {
compatible = "pinctrl-single";
reg = <0x1b001358 0x4>;
pinctrl-single,bit-per-mux;
pinctrl-single,register-width = <32>;
pinctrl-single,function-mask = <0x1>;
#pinctrl-cells = <2>;
/* Enable GPIO6 and GPIO7, possibly unknown others */
pinmux_disable_jtag: disable_jtag {
pinctrl-single,bits = <0x0 0x0 0x8000>;
};
/* Controls GPIO0 */
pinmux_disable_sys_led: disable_sys_led {
pinctrl-single,bits = <0x0 0x0 0x100>;
};
};
ethernet0: ethernet@1b00a300 {
status = "okay";

View File

@ -28,31 +28,6 @@
extern struct rtl83xx_soc_info soc_info;
static void __init rtl838x_setup(void)
{
/* Setup System LED. Bit 15 then allows to toggle it */
sw_w32_mask(0, 3 << 16, RTL838X_LED_GLB_CTRL);
}
static void __init rtl839x_setup(void)
{
/* Setup System LED. Bit 14 of RTL839X_LED_GLB_CTRL then allows to toggle it */
sw_w32_mask(0, 3 << 15, RTL839X_LED_GLB_CTRL);
}
static void __init rtl930x_setup(void)
{
if (soc_info.id == 0x9302)
sw_w32_mask(0, 3 << 13, RTL9302_LED_GLB_CTRL);
else
sw_w32_mask(0, 3 << 13, RTL930X_LED_GLB_CTRL);
}
static void __init rtl931x_setup(void)
{
sw_w32_mask(0, 3 << 12, RTL931X_LED_GLB_CTRL);
}
void __init plat_mem_setup(void)
{
void *dtb;
@ -71,21 +46,6 @@ void __init plat_mem_setup(void)
* parsed resulting in our memory appearing
*/
__dt_setup_arch(dtb);
switch (soc_info.family) {
case RTL8380_FAMILY_ID:
rtl838x_setup();
break;
case RTL8390_FAMILY_ID:
rtl839x_setup();
break;
case RTL9300_FAMILY_ID:
rtl930x_setup();
break;
case RTL9310_FAMILY_ID:
rtl931x_setup();
break;
}
}
void __init plat_time_init(void)