Re: CPU_TYPE "xxx" doesn't correspond to a known type

2021-12-16 Thread Florian Eckert

Hello Philip


Yeah, it's intentional.  It was meant to be a sentinel for bitrot.


I was already aware that this warning was intentional.
I have expressed that incorrectly sorry.


You don't want to have an empty expansion of CPU_CLFAGS_* as these are
usually important platform-specific values that cause the correct
instruction set to be emitted for the particulars of the CPU type.

See the preceding lines for -march and -mcpu values per platform.


But that would mean we would have to do something, wouldn't it?
I have seen that it mainly affects arm cpu's.

Best regards

Florian



Output:
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a15" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a5" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "arm926ej-s" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "arm1176jzf-s" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a72" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "fa526" doesn't 
correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a15" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "xscale" doesn't 
correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a72" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "arm926ej-s" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a8" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "arm926ej-s" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "mpcore" doesn't 
correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a8" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" 
doesn't correspond to a known type


apm821xx/nand powerpc_464fp
apm821xx/sata powerpc_464fp
arc770/generic arc_arc700
archs38/generic arc_archs
armvirt/32 arm_cortex-a15_neon-vfpv4
armvirt/64 aarch64_cortex-a53
at91/sam9x arm_arm926ej-s
at91/sama5 arm_cortex-a5_vfpv4
ath25/generic mips_mips32
ath79/generic mips_24kc
ath79/mikrotik mips_24kc
ath79/nand mips_24kc
ath79/tiny mips_24kc
bcm27xx/bcm2708 arm_arm1176jzf-s_vfp
bcm27xx/bcm2709 arm_cortex-a7_neon-vfpv4
bcm27xx/bcm2710 aarch64_cortex-a53
bcm27xx/bcm2711 aarch64_cortex-a72
bcm47xx/generic mipsel_mips32
bcm47xx/legacy mipsel_mips32
bcm47xx/mips74k mipsel_74kc
bcm4908/generic aarch64_cortex-a53
bcm53xx/generic arm_cortex-a9
bcm63xx/generic mips_mips32
bcm63xx/smp mips_mips32
gemini/generic arm_fa526
imx/cortexa7 arm_cortex-a7_neon-vfpv4
imx/cortexa9 arm_cortex-a9_neon
ipq40xx/generic arm_cortex-a7_neon-vfpv4
ipq40xx/mikrotik arm_cortex-a7_neon-vfpv4
ipq806x/generic arm_cortex-a15_neon-vfpv4
kirkwood/generic arm_xscale
lantiq/ase mips_mips32
lantiq/xrx200 mips_24kc
lantiq/xway mips_24kc
lantiq/xway_legacy mips_24kc
layerscape/armv7 arm_cortex-a7_neon-vfpv4
layerscape/armv8_64b aarch64_generic
malta/be mips_24kc
mediatek/mt7622 aarch64_cortex-a53
mediatek/mt7623 arm_cortex-a7_neon-vfpv4
mediatek/mt7629 arm_cortex-a7
mpc85xx/p1010 powerpc_8540
mpc85xx/p1020 powerpc_8540
mpc85xx/p2020 powerpc_8540
mvebu/cortexa53 aarch64_cortex-a53
mvebu/cortexa72 aarch64_cortex-a72
mvebu/cortexa9 arm_cortex-a9_vfpv3-d16
mxs/generic arm_arm926ej-s
octeon/generic mips64_octeonplus
octeontx/generic aarch64_generic
omap/generic arm_cortex-a8_vfpv3
oxnas/ox820 arm_mpcore
pistachio/generic mipsel_24kc_24kf
ramips/mt7620 

[PATCH 2/3] ath25: refresh kernel 5.4 config

2021-12-16 Thread Sergey Ryazanov
The target config require some refresh due to the just introduced
filtering of the "run-time" options, MIPS eBPF JIT backporting, and so
on.

The configuration is easily updated using make kernel_oldconfig. So
let's update it now in preparation for v5.10 support to reduce the new
kernel configuration diff.

Signed-off-by: Sergey Ryazanov 
---
 target/linux/ath25/config-5.4 | 56 ++-
 1 file changed, 2 insertions(+), 54 deletions(-)

diff --git a/target/linux/ath25/config-5.4 b/target/linux/ath25/config-5.4
index 4b47470699..10b81f0e03 100644
--- a/target/linux/ath25/config-5.4
+++ b/target/linux/ath25/config-5.4
@@ -3,25 +3,10 @@ CONFIG_AR2315_WDT=y
 CONFIG_AR8216_PHY=y
 CONFIG_ARCH_32BIT_OFF_T=y
 CONFIG_ARCH_CLOCKSOURCE_DATA=y
-CONFIG_ARCH_HAS_DMA_COHERENT_TO_PFN=y
-CONFIG_ARCH_HAS_DMA_PREP_COHERENT=y
-CONFIG_ARCH_HAS_DMA_WRITE_COMBINE=y
-CONFIG_ARCH_HAS_ELF_RANDOMIZE=y
-CONFIG_ARCH_HAS_PHYS_TO_DMA=y
-CONFIG_ARCH_HAS_PTE_SPECIAL=y
-CONFIG_ARCH_HAS_SYNC_DMA_FOR_DEVICE=y
-CONFIG_ARCH_HAS_UNCACHED_SEGMENT=y
 CONFIG_ARCH_HIBERNATION_POSSIBLE=y
 CONFIG_ARCH_MMAP_RND_BITS_MAX=15
 CONFIG_ARCH_MMAP_RND_COMPAT_BITS_MAX=15
-CONFIG_ARCH_SUPPORTS_UPROBES=y
 CONFIG_ARCH_SUSPEND_POSSIBLE=y
-CONFIG_ARCH_USE_BUILTIN_BSWAP=y
-CONFIG_ARCH_USE_MEMREMAP_PROT=y
-CONFIG_ARCH_USE_QUEUED_RWLOCKS=y
-CONFIG_ARCH_USE_QUEUED_SPINLOCKS=y
-CONFIG_ARCH_WANT_DEFAULT_TOPDOWN_MMAP_LAYOUT=y
-CONFIG_ARCH_WANT_IPC_PARSE_VERSION=y
 CONFIG_ATH25=y
 CONFIG_BLK_MQ_PCI=y
 CONFIG_CEVT_R4K=y
@@ -42,16 +27,13 @@ CONFIG_CPU_NEEDS_NO_SMARTMIPS_OR_MICROMIPS=y
 CONFIG_CPU_R4K_CACHE_TLB=y
 CONFIG_CPU_SUPPORTS_32BIT_KERNEL=y
 CONFIG_CPU_SUPPORTS_HIGHMEM=y
+CONFIG_CRYPTO_LIB_POLY1305_RSIZE=2
 CONFIG_CRYPTO_RNG2=y
 CONFIG_CSRC_R4K=y
 CONFIG_DMA_NONCOHERENT=y
 CONFIG_DMA_NONCOHERENT_CACHE_SYNC=y
 CONFIG_EARLY_PRINTK=y
-CONFIG_EFI_EARLYCON=y
 CONFIG_ETHERNET_PACKET_MANGLE=y
-CONFIG_FONT_8x16=y
-CONFIG_FONT_AUTOSELECT=y
-CONFIG_FONT_SUPPORT=y
 CONFIG_FORCE_PCI=y
 CONFIG_FW_LOADER_PAGED_BUF=y
 CONFIG_GENERIC_ATOMIC64=y
@@ -80,40 +62,6 @@ CONFIG_HARDWARE_WATCHPOINTS=y
 CONFIG_HAS_DMA=y
 CONFIG_HAS_IOMEM=y
 CONFIG_HAS_IOPORT_MAP=y
-CONFIG_HAVE_ARCH_COMPILER_H=y
-CONFIG_HAVE_ARCH_JUMP_LABEL=y
-CONFIG_HAVE_ARCH_KGDB=y
-CONFIG_HAVE_ARCH_SECCOMP_FILTER=y
-CONFIG_HAVE_ARCH_TRACEHOOK=y
-CONFIG_HAVE_ASM_MODVERSIONS=y
-CONFIG_HAVE_CBPF_JIT=y
-CONFIG_HAVE_CONTEXT_TRACKING=y
-CONFIG_HAVE_COPY_THREAD_TLS=y
-CONFIG_HAVE_C_RECORDMCOUNT=y
-CONFIG_HAVE_DEBUG_KMEMLEAK=y
-CONFIG_HAVE_DEBUG_STACKOVERFLOW=y
-CONFIG_HAVE_DMA_CONTIGUOUS=y
-CONFIG_HAVE_DYNAMIC_FTRACE=y
-CONFIG_HAVE_FAST_GUP=y
-CONFIG_HAVE_FTRACE_MCOUNT_RECORD=y
-CONFIG_HAVE_FUNCTION_GRAPH_TRACER=y
-CONFIG_HAVE_FUNCTION_TRACER=y
-CONFIG_HAVE_GENERIC_VDSO=y
-CONFIG_HAVE_IDE=y
-CONFIG_HAVE_IOREMAP_PROT=y
-CONFIG_HAVE_IRQ_EXIT_ON_IRQ_STACK=y
-CONFIG_HAVE_IRQ_TIME_ACCOUNTING=y
-CONFIG_HAVE_LD_DEAD_CODE_DATA_ELIMINATION=y
-CONFIG_HAVE_MEMBLOCK_NODE_MAP=y
-CONFIG_HAVE_MOD_ARCH_SPECIFIC=y
-CONFIG_HAVE_NET_DSA=y
-CONFIG_HAVE_OPROFILE=y
-CONFIG_HAVE_PCI=y
-CONFIG_HAVE_PERF_EVENTS=y
-CONFIG_HAVE_REGS_AND_STACK_ACCESS_API=y
-CONFIG_HAVE_RSEQ=y
-CONFIG_HAVE_SYSCALL_TRACEPOINTS=y
-CONFIG_HAVE_VIRT_CPU_ACCOUNTING_GEN=y
 CONFIG_HW_RANDOM=y
 CONFIG_HZ_PERIODIC=y
 CONFIG_INITRAMFS_SOURCE=""
@@ -131,10 +79,10 @@ CONFIG_MIGRATION=y
 CONFIG_MIPS=y
 CONFIG_MIPS_ASID_BITS=8
 CONFIG_MIPS_ASID_SHIFT=0
-CONFIG_MIPS_CBPF_JIT=y
 CONFIG_MIPS_CLOCK_VSYSCALL=y
 # CONFIG_MIPS_CMDLINE_BUILTIN_EXTEND is not set
 CONFIG_MIPS_CMDLINE_FROM_BOOTLOADER=y
+CONFIG_MIPS_EBPF_JIT=y
 CONFIG_MIPS_L1_CACHE_SHIFT=5
 CONFIG_MODULES_USE_ELF_REL=y
 CONFIG_MTD_AR2315=y
-- 
2.32.0


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[PATCH 3/3] ath25: add kernel 5.10 support

2021-12-16 Thread Sergey Ryazanov
Copy and refresh patches and config from 5.4 to 5.10. Most patches
require no more then automatic refresh. The only exception is the
Ethernet driver patch, which requires some more work:
* drop eth_change_mtu() usage since it was removed from the kernel,
  it anyway useless for drivers that utilizes alloc_etherdev();
* add the txqueue number argument to the .ndo_tx_timeout callback
  function;
* replace ioremap_nocache() which was finally removed from the kernel by
  the ioremap() with the same behaviour.

Switch target to the new kernel version.

Signed-off-by: Sergey Ryazanov 
---
 target/linux/ath25/Makefile   |2 +-
 target/linux/ath25/config-5.10|  127 ++
 .../ath25/patches-5.10/107-ar5312_gpio.patch  |  212 ++
 .../ath25/patches-5.10/108-ar2315_gpio.patch  |  363 
 .../patches-5.10/110-ar2313_ethernet.patch| 1735 +
 .../ath25/patches-5.10/120-spiflash.patch |  631 ++
 .../ath25/patches-5.10/130-watchdog.patch |  277 +++
 .../140-redboot_boardconfig.patch |   60 +
 .../141-redboot_partition_scan.patch  |   44 +
 .../142-redboot_various_erase_size_fix.patch  |   72 +
 .../ath25/patches-5.10/210-reset_button.patch |   71 +
 .../220-enet_micrel_workaround.patch  |  111 ++
 .../ath25/patches-5.10/330-board_leds.patch   |  116 ++
 13 files changed, 3820 insertions(+), 1 deletion(-)
 create mode 100644 target/linux/ath25/config-5.10
 create mode 100644 target/linux/ath25/patches-5.10/107-ar5312_gpio.patch
 create mode 100644 target/linux/ath25/patches-5.10/108-ar2315_gpio.patch
 create mode 100644 target/linux/ath25/patches-5.10/110-ar2313_ethernet.patch
 create mode 100644 target/linux/ath25/patches-5.10/120-spiflash.patch
 create mode 100644 target/linux/ath25/patches-5.10/130-watchdog.patch
 create mode 100644 
target/linux/ath25/patches-5.10/140-redboot_boardconfig.patch
 create mode 100644 
target/linux/ath25/patches-5.10/141-redboot_partition_scan.patch
 create mode 100644 
target/linux/ath25/patches-5.10/142-redboot_various_erase_size_fix.patch
 create mode 100644 target/linux/ath25/patches-5.10/210-reset_button.patch
 create mode 100644 
target/linux/ath25/patches-5.10/220-enet_micrel_workaround.patch
 create mode 100644 target/linux/ath25/patches-5.10/330-board_leds.patch

diff --git a/target/linux/ath25/Makefile b/target/linux/ath25/Makefile
index 1d8bee507b..df03d9e9fc 100644
--- a/target/linux/ath25/Makefile
+++ b/target/linux/ath25/Makefile
@@ -9,7 +9,7 @@ BOARD:=ath25
 BOARDNAME:=Atheros AR231x/AR5312
 FEATURES:=squashfs low_mem small_flash
 
-KERNEL_PATCHVER:=5.4
+KERNEL_PATCHVER:=5.10
 
 define Target/Description
Build firmware images for Atheros SoC boards
diff --git a/target/linux/ath25/config-5.10 b/target/linux/ath25/config-5.10
new file mode 100644
index 00..5c983ad82b
--- /dev/null
+++ b/target/linux/ath25/config-5.10
@@ -0,0 +1,127 @@
+CONFIG_ADM6996_PHY=y
+CONFIG_AR2315_WDT=y
+CONFIG_AR8216_PHY=y
+CONFIG_ARCH_32BIT_OFF_T=y
+CONFIG_ARCH_HIBERNATION_POSSIBLE=y
+CONFIG_ARCH_MMAP_RND_BITS_MAX=15
+CONFIG_ARCH_MMAP_RND_COMPAT_BITS_MAX=15
+CONFIG_ARCH_SUSPEND_POSSIBLE=y
+CONFIG_ATH25=y
+CONFIG_BLK_MQ_PCI=y
+CONFIG_CEVT_R4K=y
+CONFIG_CLONE_BACKWARDS=y
+CONFIG_CMDLINE="console=ttyS0,9600 rootfstype=squashfs,jffs2"
+CONFIG_CMDLINE_BOOL=y
+# CONFIG_CMDLINE_OVERRIDE is not set
+# CONFIG_COMMON_CLK is not set
+CONFIG_COMPAT_32BIT_TIME=y
+CONFIG_CPU_BIG_ENDIAN=y
+CONFIG_CPU_GENERIC_DUMP_TLB=y
+CONFIG_CPU_HAS_PREFETCH=y
+CONFIG_CPU_HAS_SYNC=y
+CONFIG_CPU_MIPS32=y
+CONFIG_CPU_MIPS32_R1=y
+CONFIG_CPU_MIPSR1=y
+CONFIG_CPU_NEEDS_NO_SMARTMIPS_OR_MICROMIPS=y
+CONFIG_CPU_R4K_CACHE_TLB=y
+CONFIG_CPU_SUPPORTS_32BIT_KERNEL=y
+CONFIG_CPU_SUPPORTS_HIGHMEM=y
+CONFIG_CRYPTO_LIB_POLY1305_RSIZE=2
+CONFIG_CRYPTO_RNG2=y
+CONFIG_CSRC_R4K=y
+CONFIG_DMA_NONCOHERENT=y
+CONFIG_EARLY_PRINTK=y
+CONFIG_ETHERNET_PACKET_MANGLE=y
+CONFIG_FORCE_PCI=y
+CONFIG_FW_LOADER_PAGED_BUF=y
+CONFIG_GENERIC_ATOMIC64=y
+CONFIG_GENERIC_CLOCKEVENTS=y
+CONFIG_GENERIC_CMOS_UPDATE=y
+CONFIG_GENERIC_CPU_AUTOPROBE=y
+CONFIG_GENERIC_GETTIMEOFDAY=y
+CONFIG_GENERIC_IOMAP=y
+CONFIG_GENERIC_IRQ_CHIP=y
+CONFIG_GENERIC_IRQ_EFFECTIVE_AFF_MASK=y
+CONFIG_GENERIC_IRQ_SHOW=y
+CONFIG_GENERIC_LIB_ASHLDI3=y
+CONFIG_GENERIC_LIB_ASHRDI3=y
+CONFIG_GENERIC_LIB_CMPDI2=y
+CONFIG_GENERIC_LIB_LSHRDI3=y
+CONFIG_GENERIC_LIB_UCMPDI2=y
+CONFIG_GENERIC_PCI_IOMAP=y
+CONFIG_GENERIC_SCHED_CLOCK=y
+CONFIG_GENERIC_SMP_IDLE_THREAD=y
+CONFIG_GENERIC_TIME_VSYSCALL=y
+CONFIG_GPIOLIB=y
+CONFIG_GPIO_AR2315=y
+CONFIG_GPIO_AR5312=y
+CONFIG_HANDLE_DOMAIN_IRQ=y
+CONFIG_HARDWARE_WATCHPOINTS=y
+CONFIG_HAS_DMA=y
+CONFIG_HAS_IOMEM=y
+CONFIG_HAS_IOPORT_MAP=y
+CONFIG_HW_RANDOM=y
+CONFIG_HZ_PERIODIC=y
+CONFIG_INITRAMFS_SOURCE=""
+CONFIG_IP17XX_PHY=y
+CONFIG_IRQ_DOMAIN=y
+CONFIG_IRQ_FORCED_THREADING=y
+CONFIG_IRQ_MIPS_CPU=y
+CONFIG_IRQ_WORK=y
+CONFIG_LEDS_GPIO=y
+CONFIG_LOCK_DEBUGGING_SUPPORT=y
+CONFIG_MDIO_BUS=y
+CONFIG_MDIO_DEVICE=y
+CONFIG_MDIO_DEVRES=y
+CONFIG_MEMFD_CREATE=y

[PATCH 0/3] ath25: update kernel from 5.4 to 5.10

2021-12-16 Thread Sergey Ryazanov
Hello,

I finally managed to update ath25 to the 5.10 kernel. Sorry for that it
took so long time, I was a quite busy this fall. The update itself is
relatively simple: mostly copy'n'refresh plus a few Ethernet fixes.

Run-time tested with:
* Abicom FreedomCPE (AR5312 based)
* D-Link DWL-2100AP (AR2312 based)
* D-Link DIR-300 (AR2317 based) - WiFi was not tested

I bricked my FON2202 in last year update. Now I have bricked my DIR-300.
Looks like I overwrote the "FIS directory" partition with a too fat
image during sysupgrade. I wonder should the kernel check the partition
boundary before attempting to write outside of it?

Anyway, the new code has not been tested against the AR2315 and AR2317
SoCs and the Marvell 88E6060 switch. Are there any brave testers here
who would like to help test the series with the Fonera 2.0g board? It
should run smoothly, but it is better to be shure.

The series is depend on earlier submitted kernel configuration cleanup
patches [1, 2]. The dependency is not strict and the code should build
even without it.

1. http://lists.openwrt.org/pipermail/openwrt-devel/2021-December/037387.html
2. http://patchwork.ozlabs.org/project/openwrt/list/?series=277243

CC: Hauke Mehrtens 
CC: Rui Salvaterra 
CC: Russell Senior 

Sergey Ryazanov (3):
  kernel: 5.10: recover 88E6060 switches support
  ath25: refresh kernel 5.4 config
  ath25: add kernel 5.10 support

 target/linux/ath25/Makefile   |2 +-
 target/linux/ath25/config-5.10|  127 ++
 target/linux/ath25/config-5.4 |   56 +-
 .../ath25/patches-5.10/107-ar5312_gpio.patch  |  212 ++
 .../ath25/patches-5.10/108-ar2315_gpio.patch  |  363 
 .../patches-5.10/110-ar2313_ethernet.patch| 1735 +
 .../ath25/patches-5.10/120-spiflash.patch |  631 ++
 .../ath25/patches-5.10/130-watchdog.patch |  277 +++
 .../140-redboot_boardconfig.patch |   60 +
 .../141-redboot_partition_scan.patch  |   44 +
 .../142-redboot_various_erase_size_fix.patch  |   72 +
 .../ath25/patches-5.10/210-reset_button.patch |   71 +
 .../220-enet_micrel_workaround.patch  |  111 ++
 .../ath25/patches-5.10/330-board_leds.patch   |  116 ++
 .../700-swconfig_switch_drivers.patch |9 +-
 15 files changed, 3829 insertions(+), 57 deletions(-)
 create mode 100644 target/linux/ath25/config-5.10
 create mode 100644 target/linux/ath25/patches-5.10/107-ar5312_gpio.patch
 create mode 100644 target/linux/ath25/patches-5.10/108-ar2315_gpio.patch
 create mode 100644 target/linux/ath25/patches-5.10/110-ar2313_ethernet.patch
 create mode 100644 target/linux/ath25/patches-5.10/120-spiflash.patch
 create mode 100644 target/linux/ath25/patches-5.10/130-watchdog.patch
 create mode 100644 
target/linux/ath25/patches-5.10/140-redboot_boardconfig.patch
 create mode 100644 
target/linux/ath25/patches-5.10/141-redboot_partition_scan.patch
 create mode 100644 
target/linux/ath25/patches-5.10/142-redboot_various_erase_size_fix.patch
 create mode 100644 target/linux/ath25/patches-5.10/210-reset_button.patch
 create mode 100644 
target/linux/ath25/patches-5.10/220-enet_micrel_workaround.patch
 create mode 100644 target/linux/ath25/patches-5.10/330-board_leds.patch

-- 
2.32.0


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[PATCH 1/3] kernel: 5.10: recover 88E6060 switches support

2021-12-16 Thread Sergey Ryazanov
Support for mvswich driver (Marvell 88E6060 switches) build has been
missed during the initial v5.10 kernel introduction. But it is required
for AR21xx boards, e.g. Fonera 2.0. Return the missed driver building
instructions to fix boards support with the new kernel.

Compile tested only with the ath25 target.

Fixes: b10d604459 ("kernel: add linux 5.10 support")
CC: Felix Fietkau 
Signed-off-by: Sergey Ryazanov 
---
 .../generic/hack-5.10/700-swconfig_switch_drivers.patch  | 9 +++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/target/linux/generic/hack-5.10/700-swconfig_switch_drivers.patch 
b/target/linux/generic/hack-5.10/700-swconfig_switch_drivers.patch
index b90e1fc441..df36e66782 100644
--- a/target/linux/generic/hack-5.10/700-swconfig_switch_drivers.patch
+++ b/target/linux/generic/hack-5.10/700-swconfig_switch_drivers.patch
@@ -12,7 +12,7 @@ Signed-off-by: Felix Fietkau 
 
 --- a/drivers/net/phy/Kconfig
 +++ b/drivers/net/phy/Kconfig
-@@ -61,6 +61,80 @@ config SFP
+@@ -61,6 +61,84 @@ config SFP
depends on HWMON || HWMON=n
select MDIO_I2C
  
@@ -50,6 +50,10 @@ Signed-off-by: Felix Fietkau 
 +  tristate "Driver for IC+ IP17xx switches"
 +  select SWCONFIG
 +
++config MVSWITCH_PHY
++  tristate "Driver for Marvell 88E6060 switches"
++  select ETHERNET_PACKET_MANGLE
++
 +config PSB6970_PHY
 +  tristate "Lantiq XWAY Tantos (PSB6970) Ethernet switch"
 +  select SWCONFIG
@@ -95,7 +99,7 @@ Signed-off-by: Felix Fietkau 
  config AMD_PHY
 --- a/drivers/net/phy/Makefile
 +++ b/drivers/net/phy/Makefile
-@@ -24,6 +24,19 @@ libphy-$(CONFIG_LED_TRIGGER_PHY)+= phy_
+@@ -24,6 +24,20 @@ libphy-$(CONFIG_LED_TRIGGER_PHY)+= phy_
  obj-$(CONFIG_PHYLINK) += phylink.o
  obj-$(CONFIG_PHYLIB)  += libphy.o
  
@@ -104,6 +108,7 @@ Signed-off-by: Felix Fietkau 
 +obj-$(CONFIG_AR8216_PHY)  += ar8216.o ar8327.o
 +obj-$(CONFIG_SWCONFIG_B53)+= b53/
 +obj-$(CONFIG_IP17XX_PHY)  += ip17xx.o
++obj-$(CONFIG_MVSWITCH_PHY)+= mvswitch.o
 +obj-$(CONFIG_PSB6970_PHY) += psb6970.o
 +obj-$(CONFIG_RTL8306_PHY) += rtl8306.o
 +obj-$(CONFIG_RTL8366_SMI) += rtl8366_smi.o
-- 
2.32.0


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[PATCH 2/2] kernel: 5.10: consolidate mac80211 crypto options

2021-12-16 Thread Sergey Ryazanov
Each of
- CRYPTO_AEAD2
- CRYPTO_AEAD
- CRYPTO_GF128MUL
- CRYPTO_GHASH
- CRYPTO_HASH2
- CRYPTO_HASH
- CRYPTO_MANAGER2
- CRYPTO_MANAGER
- CRYPTO_NULL2

either directly required for mac80211 crypto support, or directly
selected by such options. Support for the mac80211 crypto was enabled in
the generic config since c7182123b9 ("kernel: make cryptoapi support
needed by mac80211 built-in"). So move the above options from the target
configs to the generic config to make it clear why do we need them.

CC: Felix Fietkau 
Signed-off-by: Sergey Ryazanov 
---
 target/linux/apm821xx/config-5.10 | 2 --
 target/linux/archs38/config-5.10  | 7 ---
 target/linux/armvirt/64/config-5.10   | 1 -
 target/linux/armvirt/config-5.10  | 7 ---
 target/linux/bcm27xx/bcm2708/config-5.10  | 2 --
 target/linux/bcm27xx/bcm2709/config-5.10  | 2 --
 target/linux/bcm27xx/bcm2710/config-5.10  | 2 --
 target/linux/bcm27xx/bcm2711/config-5.10  | 2 --
 target/linux/bcm4908/config-5.10  | 2 --
 target/linux/bcm53xx/config-5.10  | 2 --
 target/linux/bmips/config-5.10| 6 --
 target/linux/gemini/config-5.10   | 9 -
 target/linux/generic/config-5.10  | 3 ++-
 target/linux/imx/config-5.10  | 2 --
 target/linux/ipq40xx/config-5.10  | 2 --
 target/linux/ipq806x/config-5.10  | 7 ---
 target/linux/kirkwood/config-5.10 | 2 --
 target/linux/lantiq/config-5.10   | 2 --
 target/linux/lantiq/xrx200/config-5.10| 5 -
 target/linux/layerscape/armv7/config-5.10 | 2 --
 target/linux/layerscape/armv8_64b/config-5.10 | 2 --
 target/linux/malta/config-5.10| 7 ---
 target/linux/mediatek/mt7622/config-5.10  | 7 ---
 target/linux/mediatek/mt7623/config-5.10  | 2 --
 target/linux/mediatek/mt7629/config-5.10  | 2 --
 target/linux/mpc85xx/config-5.10  | 7 ---
 target/linux/mvebu/config-5.10| 7 ---
 target/linux/mvebu/cortexa72/config-5.10  | 1 -
 target/linux/mxs/config-5.10  | 4 
 target/linux/octeon/config-5.10   | 7 ---
 target/linux/octeontx/config-5.10 | 2 --
 target/linux/omap/config-5.10 | 2 --
 target/linux/pistachio/config-5.10| 2 --
 target/linux/ramips/mt7621/config-5.10| 6 --
 target/linux/realtek/config-5.10  | 2 --
 target/linux/rockchip/armv8/config-5.10   | 7 ---
 target/linux/sunxi/config-5.10| 2 --
 target/linux/tegra/config-5.10| 7 ---
 target/linux/uml/config-5.10  | 2 --
 target/linux/x86/64/config-5.10   | 6 --
 target/linux/x86/config-5.10  | 2 --
 target/linux/x86/generic/config-5.10  | 5 -
 target/linux/zynq/config-5.10 | 2 --
 43 files changed, 2 insertions(+), 160 deletions(-)

diff --git a/target/linux/apm821xx/config-5.10 
b/target/linux/apm821xx/config-5.10
index 22d34c3fce..a65185a0c0 100644
--- a/target/linux/apm821xx/config-5.10
+++ b/target/linux/apm821xx/config-5.10
@@ -41,14 +41,12 @@ CONFIG_CRC16=y
 CONFIG_CRC32_SLICEBY8=y
 CONFIG_CRYPTO_DEFLATE=y
 CONFIG_CRYPTO_DEV_PPC4XX=y
-CONFIG_CRYPTO_GF128MUL=y
 CONFIG_CRYPTO_HW=y
 CONFIG_CRYPTO_JITTERENTROPY=y
 CONFIG_CRYPTO_LIB_POLY1305_RSIZE=1
 CONFIG_CRYPTO_LIB_SHA256=y
 CONFIG_CRYPTO_LZO=y
 # CONFIG_CRYPTO_MD5_PPC is not set
-CONFIG_CRYPTO_NULL2=y
 CONFIG_CRYPTO_RNG=y
 CONFIG_CRYPTO_RNG2=y
 # CONFIG_CRYPTO_SHA1_PPC is not set
diff --git a/target/linux/archs38/config-5.10 b/target/linux/archs38/config-5.10
index af787f887e..5ba3877a64 100644
--- a/target/linux/archs38/config-5.10
+++ b/target/linux/archs38/config-5.10
@@ -71,22 +71,15 @@ CONFIG_COMMON_CLK=y
 CONFIG_COMPAT_32BIT_TIME=y
 CONFIG_CPU_RMAP=y
 CONFIG_CRC16=y
-CONFIG_CRYPTO_AEAD=y
-CONFIG_CRYPTO_AEAD2=y
 CONFIG_CRYPTO_CRC32C=y
 CONFIG_CRYPTO_DRBG=y
 CONFIG_CRYPTO_DRBG_HMAC=y
 CONFIG_CRYPTO_DRBG_MENU=y
 CONFIG_CRYPTO_ECHAINIV=y
-CONFIG_CRYPTO_HASH=y
-CONFIG_CRYPTO_HASH2=y
 CONFIG_CRYPTO_HMAC=y
 CONFIG_CRYPTO_JITTERENTROPY=y
 CONFIG_CRYPTO_LIB_SHA256=y
-CONFIG_CRYPTO_MANAGER=y
-CONFIG_CRYPTO_MANAGER2=y
 CONFIG_CRYPTO_NULL=y
-CONFIG_CRYPTO_NULL2=y
 CONFIG_CRYPTO_RNG=y
 CONFIG_CRYPTO_RNG2=y
 CONFIG_CRYPTO_RNG_DEFAULT=y
diff --git a/target/linux/armvirt/64/config-5.10 
b/target/linux/armvirt/64/config-5.10
index 51f3c3c952..27d86cf8a7 100644
--- a/target/linux/armvirt/64/config-5.10
+++ b/target/linux/armvirt/64/config-5.10
@@ -57,7 +57,6 @@ CONFIG_CRYPTO_ARCH_HAVE_LIB_CHACHA=y
 CONFIG_CRYPTO_CHACHA20=y
 CONFIG_CRYPTO_CHACHA20_NEON=y
 CONFIG_CRYPTO_CRYPTD=y
-CONFIG_CRYPTO_GF128MUL=y
 CONFIG_CRYPTO_GHASH_ARM64_CE=y
 CONFIG_CRYPTO_LIB_CHACHA_GENERIC=y
 CONFIG_CRYPTO_SHA1=y
diff --git a/target/linux/armvirt/config-5.10 b/target/linux/armvirt/config-5.10
index 6c2255eeb3..c63b169607 100644
--- 

[PATCH 1/2] kernel: filter out both Clang and LLD versions

2021-12-16 Thread Sergey Ryazanov
Both CLANG_VERSION and LLD_VERISON are autogenerated runtime
configuration options, so add them to the kernel configuration filter
and remove from generic and per-target configs to keep configs clean.

Signed-off-by: Sergey Ryazanov 
---
 target/linux/armvirt/config-5.10  | 1 -
 target/linux/at91/sam9x/config-default| 1 -
 target/linux/at91/sama5/config-default| 1 -
 target/linux/ath79/config-5.10| 1 -
 target/linux/bcm27xx/bcm2708/config-5.10  | 1 -
 target/linux/bcm27xx/bcm2709/config-5.10  | 1 -
 target/linux/bcm27xx/bcm2710/config-5.10  | 1 -
 target/linux/bcm27xx/bcm2711/config-5.10  | 1 -
 target/linux/bcm4908/config-5.10  | 1 -
 target/linux/bcm53xx/config-5.10  | 1 -
 target/linux/bcm63xx/config-5.10  | 1 -
 target/linux/bmips/config-5.10| 1 -
 target/linux/gemini/config-5.10   | 1 -
 target/linux/generic/config-5.10  | 1 -
 target/linux/generic/config-5.4   | 1 -
 target/linux/generic/config-filter| 2 ++
 target/linux/imx/config-5.10  | 1 -
 target/linux/ipq40xx/config-5.10  | 1 -
 target/linux/ipq806x/config-5.10  | 1 -
 target/linux/kirkwood/config-5.10 | 1 -
 target/linux/lantiq/config-5.10   | 1 -
 target/linux/layerscape/armv7/config-5.10 | 1 -
 target/linux/layerscape/armv8_64b/config-5.10 | 1 -
 target/linux/malta/config-5.10| 1 -
 target/linux/mediatek/mt7622/config-5.10  | 1 -
 target/linux/mediatek/mt7623/config-5.10  | 1 -
 target/linux/mediatek/mt7629/config-5.10  | 1 -
 target/linux/mpc85xx/config-5.10  | 1 -
 target/linux/mvebu/config-5.10| 1 -
 target/linux/mxs/config-5.10  | 1 -
 target/linux/octeon/config-5.10   | 1 -
 target/linux/octeontx/config-5.10 | 1 -
 target/linux/omap/config-5.10 | 1 -
 target/linux/pistachio/config-5.10| 1 -
 target/linux/ramips/mt7620/config-5.10| 1 -
 target/linux/ramips/mt7621/config-5.10| 1 -
 target/linux/ramips/mt76x8/config-5.10| 1 -
 target/linux/ramips/rt288x/config-5.10| 1 -
 target/linux/ramips/rt305x/config-5.10| 1 -
 target/linux/ramips/rt3883/config-5.10| 1 -
 target/linux/realtek/config-5.10  | 1 -
 target/linux/rockchip/armv8/config-5.10   | 1 -
 target/linux/sunxi/config-5.10| 1 -
 target/linux/tegra/config-5.10| 1 -
 target/linux/uml/config-5.10  | 1 -
 target/linux/x86/config-5.10  | 1 -
 target/linux/zynq/config-5.10 | 1 -
 47 files changed, 2 insertions(+), 46 deletions(-)

diff --git a/target/linux/armvirt/config-5.10 b/target/linux/armvirt/config-5.10
index 74b6957d94..6c2255eeb3 100644
--- a/target/linux/armvirt/config-5.10
+++ b/target/linux/armvirt/config-5.10
@@ -91,7 +91,6 @@ CONFIG_IRQ_FORCED_THREADING=y
 CONFIG_IRQ_WORK=y
 CONFIG_JBD2=y
 CONFIG_LIBFDT=y
-CONFIG_LLD_VERSION=0
 CONFIG_LOCK_DEBUGGING_SUPPORT=y
 CONFIG_LOCK_SPIN_ON_OWNER=y
 CONFIG_MEMFD_CREATE=y
diff --git a/target/linux/at91/sam9x/config-default 
b/target/linux/at91/sam9x/config-default
index bd9d106f5b..e3d4c29e99 100644
--- a/target/linux/at91/sam9x/config-default
+++ b/target/linux/at91/sam9x/config-default
@@ -158,7 +158,6 @@ CONFIG_LEDS_PWM=y
 CONFIG_LEDS_TRIGGER_CPU=y
 CONFIG_LEDS_TRIGGER_GPIO=y
 CONFIG_LIBFDT=y
-CONFIG_LLD_VERSION=0
 CONFIG_LOCK_DEBUGGING_SUPPORT=y
 CONFIG_LZO_COMPRESS=y
 CONFIG_LZO_DECOMPRESS=y
diff --git a/target/linux/at91/sama5/config-default 
b/target/linux/at91/sama5/config-default
index 852e5c95b7..e294fd9e3b 100644
--- a/target/linux/at91/sama5/config-default
+++ b/target/linux/at91/sama5/config-default
@@ -240,7 +240,6 @@ CONFIG_LEDS_PWM=y
 CONFIG_LEDS_TRIGGER_CPU=y
 CONFIG_LEDS_TRIGGER_GPIO=y
 CONFIG_LIBFDT=y
-CONFIG_LLD_VERSION=0
 CONFIG_LOCALVERSION_AUTO=y
 CONFIG_LOCK_DEBUGGING_SUPPORT=y
 CONFIG_LOG_BUF_SHIFT=16
diff --git a/target/linux/ath79/config-5.10 b/target/linux/ath79/config-5.10
index 786d70decf..12f51b08ce 100644
--- a/target/linux/ath79/config-5.10
+++ b/target/linux/ath79/config-5.10
@@ -91,7 +91,6 @@ CONFIG_IRQ_WORK=y
 CONFIG_LEDS_GPIO=y
 # CONFIG_LEDS_RESET is not set
 CONFIG_LIBFDT=y
-CONFIG_LLD_VERSION=0
 CONFIG_LOCK_DEBUGGING_SUPPORT=y
 CONFIG_MDIO_BITBANG=y
 CONFIG_MDIO_BUS=y
diff --git a/target/linux/bcm27xx/bcm2708/config-5.10 
b/target/linux/bcm27xx/bcm2708/config-5.10
index 8e8ae51443..aa0b76ad4c 100644
--- a/target/linux/bcm27xx/bcm2708/config-5.10
+++ b/target/linux/bcm27xx/bcm2708/config-5.10
@@ -216,7 +216,6 @@ CONFIG_LEDS_GPIO=y
 CONFIG_LEDS_TRIGGER_ACTPWR=y
 CONFIG_LEDS_TRIGGER_INPUT=y
 CONFIG_LIBFDT=y
-CONFIG_LLD_VERSION=0
 CONFIG_LOCK_DEBUGGING_SUPPORT=y
 CONFIG_LOGO=y
 CONFIG_LOGO_LINUX_CLUT224=y
diff --git a/target/linux/bcm27xx/bcm2709/config-5.10 
b/target/linux/bcm27xx/bcm2709/config-5.10
index 

[PATCH 0/2] kernel: 5.10: configuration cleanup

2021-12-16 Thread Sergey Ryazanov
Hello,

this series intended to cleaup per-target kernel configurations. It
should reduce amount of odd options in the per-target configurations by
removing "run-time" options and moving mac80211 crypto related options
to the generic configuration.

All this odd options were discovered during the ath25 target migration
to the 5.10 kernel (see the next series).

Sergey Ryazanov (2):
  kernel: filter out both Clang and LLD versions
  kernel: 5.10: consolidate mac80211 crypto options

 target/linux/apm821xx/config-5.10 |  2 --
 target/linux/archs38/config-5.10  |  7 ---
 target/linux/armvirt/64/config-5.10   |  1 -
 target/linux/armvirt/config-5.10  |  8 
 target/linux/at91/sam9x/config-default|  1 -
 target/linux/at91/sama5/config-default|  1 -
 target/linux/ath79/config-5.10|  1 -
 target/linux/bcm27xx/bcm2708/config-5.10  |  3 ---
 target/linux/bcm27xx/bcm2709/config-5.10  |  3 ---
 target/linux/bcm27xx/bcm2710/config-5.10  |  3 ---
 target/linux/bcm27xx/bcm2711/config-5.10  |  3 ---
 target/linux/bcm4908/config-5.10  |  3 ---
 target/linux/bcm53xx/config-5.10  |  3 ---
 target/linux/bcm63xx/config-5.10  |  1 -
 target/linux/bmips/config-5.10|  7 ---
 target/linux/gemini/config-5.10   | 10 --
 target/linux/generic/config-5.10  |  4 ++--
 target/linux/generic/config-5.4   |  1 -
 target/linux/generic/config-filter|  2 ++
 target/linux/imx/config-5.10  |  3 ---
 target/linux/ipq40xx/config-5.10  |  3 ---
 target/linux/ipq806x/config-5.10  |  8 
 target/linux/kirkwood/config-5.10 |  3 ---
 target/linux/lantiq/config-5.10   |  3 ---
 target/linux/lantiq/xrx200/config-5.10|  5 -
 target/linux/layerscape/armv7/config-5.10 |  3 ---
 target/linux/layerscape/armv8_64b/config-5.10 |  3 ---
 target/linux/malta/config-5.10|  8 
 target/linux/mediatek/mt7622/config-5.10  |  8 
 target/linux/mediatek/mt7623/config-5.10  |  3 ---
 target/linux/mediatek/mt7629/config-5.10  |  3 ---
 target/linux/mpc85xx/config-5.10  |  8 
 target/linux/mvebu/config-5.10|  8 
 target/linux/mvebu/cortexa72/config-5.10  |  1 -
 target/linux/mxs/config-5.10  |  5 -
 target/linux/octeon/config-5.10   |  8 
 target/linux/octeontx/config-5.10 |  3 ---
 target/linux/omap/config-5.10 |  3 ---
 target/linux/pistachio/config-5.10|  3 ---
 target/linux/ramips/mt7620/config-5.10|  1 -
 target/linux/ramips/mt7621/config-5.10|  7 ---
 target/linux/ramips/mt76x8/config-5.10|  1 -
 target/linux/ramips/rt288x/config-5.10|  1 -
 target/linux/ramips/rt305x/config-5.10|  1 -
 target/linux/ramips/rt3883/config-5.10|  1 -
 target/linux/realtek/config-5.10  |  3 ---
 target/linux/rockchip/armv8/config-5.10   |  8 
 target/linux/sunxi/config-5.10|  3 ---
 target/linux/tegra/config-5.10|  8 
 target/linux/uml/config-5.10  |  3 ---
 target/linux/x86/64/config-5.10   |  6 --
 target/linux/x86/config-5.10  |  3 ---
 target/linux/x86/generic/config-5.10  |  5 -
 target/linux/zynq/config-5.10 |  3 ---
 54 files changed, 4 insertions(+), 206 deletions(-)

-- 
2.32.0


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: CPU_TYPE "xxx" doesn't correspond to a known type

2021-12-16 Thread Philip Prindeville
Yeah, it's intentional.  It was meant to be a sentinel for bitrot.

If you look at the line following the changes:

  DEFAULT_CFLAGS=$(strip $(CPU_CFLAGS) $(CPU_CFLAGS_$(CPU_TYPE)) 
$(CPU_CFLAGS_$(CPU_SUBTYPE)))

You don't want to have an empty expansion of CPU_CLFAGS_* as these are usually 
important platform-specific values that cause the correct instruction set to be 
emitted for the particulars of the CPU type.

See the preceding lines for -march and -mcpu values per platform.

-Philip


> On Dec 16, 2021, at 4:57 AM, Florian Eckert  wrote:
> 
> Hello,
> 
> If I execute the following command in the openwrt project:
> ./scripts/dump-target-info.pl targets
> 
> I get the this output! I don't know if this is a mistake or if it is 
> intentional.
> The warning was added by this commit
> https://gitlab.dev.tdt.de/dev/sys6/upstream/openwrt/-/commit/d3bc11857af788e185e8a3ece26ce40757cf3965
> 
> 
> Output:
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a15" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a5" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "arm926ej-s" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "arm1176jzf-s" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a72" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "fa526" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a15" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "xscale" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a72" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "arm926ej-s" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a8" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "arm926ej-s" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "mpcore" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a8" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" doesn't 
> correspond to a known type
> /home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" doesn't 
> correspond to a known type
> 
> apm821xx/nand powerpc_464fp
> apm821xx/sata powerpc_464fp
> arc770/generic arc_arc700
> archs38/generic arc_archs
> armvirt/32 arm_cortex-a15_neon-vfpv4
> armvirt/64 aarch64_cortex-a53
> at91/sam9x arm_arm926ej-s
> at91/sama5 arm_cortex-a5_vfpv4
> ath25/generic mips_mips32
> ath79/generic mips_24kc
> ath79/mikrotik mips_24kc
> ath79/nand mips_24kc
> ath79/tiny mips_24kc
> bcm27xx/bcm2708 arm_arm1176jzf-s_vfp
> bcm27xx/bcm2709 arm_cortex-a7_neon-vfpv4
> bcm27xx/bcm2710 aarch64_cortex-a53
> bcm27xx/bcm2711 aarch64_cortex-a72
> bcm47xx/generic mipsel_mips32
> bcm47xx/legacy mipsel_mips32
> bcm47xx/mips74k mipsel_74kc
> bcm4908/generic aarch64_cortex-a53
> bcm53xx/generic arm_cortex-a9
> bcm63xx/generic mips_mips32
> bcm63xx/smp mips_mips32
> gemini/generic arm_fa526
> imx/cortexa7 arm_cortex-a7_neon-vfpv4
> imx/cortexa9 arm_cortex-a9_neon
> ipq40xx/generic arm_cortex-a7_neon-vfpv4
> ipq40xx/mikrotik arm_cortex-a7_neon-vfpv4
> ipq806x/generic arm_cortex-a15_neon-vfpv4
> kirkwood/generic arm_xscale
> lantiq/ase mips_mips32
> lantiq/xrx200 mips_24kc
> lantiq/xway mips_24kc
> lantiq/xway_legacy mips_24kc
> layerscape/armv7 arm_cortex-a7_neon-vfpv4
> layerscape/armv8_64b aarch64_generic
> malta/be 

Re: MT: should the ZBT-WE1206 watchdog be disabled by default?

2021-12-16 Thread Sergey Ryazanov
Hello Arvid,

On Wed, Dec 15, 2021 at 2:13 PM Arvid Picciani  wrote:
> ZBT-WE1206 has an external watchdog that with stock openwrt resets the board.

What board do you mean? I am unable to locate ZBT-WE1206 neither in
the repository, nor in google.

> should this get disabled in bringup or is this considered a downstream 
> problem?

An external watchdog either self-initialized during on power-up or
initialized by a bootloader. So there is no such option as disabling
it. It is usually sufficient to add a small node to the board DTS file
to fully support the external watchdog and avoid unexpected reboots.

If a board is supported in the main OpenWrt, then the code should be
fixed in it.

-- 
Sergey

___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [uqmi] dms: add --get-operating-mode

2021-12-16 Thread Henrik Ginstmark
Hi

I have gathered my thoughts in my own version of uqmi.
I think I have dual-stack working.
It's available at https://github.com/mrhaav/openwrt-packages. Feel
free to take a lock and try. :)

/Henrik

Den mån 6 dec. 2021 kl 08:29 skrev Bjørn Mork :
>
> Sergey Ryazanov  writes:
>
> > Can you reveal what modem model has such nasty behaviour? I personally
> > test IPv6 with Huawei E3372 (NCM, not QMI) and Sierra MC7304, both of
> > them work stable. But I can not recall whether they established the
> > IPv6 connection as soon as a PDP context was reconfigured or I needed
> > to reattach (power circle) them. Need to recheck someday.
>
> I believe this is a common issue, not limited to a specific vendor.  The
> last modem where I noticed it was a Quectel RG502Q-EA.  But I'm pretty
> sure the problem was there in older modems too.  You should be able to
> see it in the MC7304.  Don't you?  Not sure about the non-Qualcomm
> modems.
>
> > And do you remember whether the airplane mode was the only option to
> > configure a new APN or some other operation also help to recover IPv6
> > connectivity? E.g. disconnect/connect QMI command or a modem power
> > circle.
>
> I haven't tried ariplane mode to resolve this.  But that should work
> since it will cause the modem to reattach to the network..
>
> Since this is mostly a one-time thing I've just changed the modem config
> and rebooted the modem.  Usually after debugging for a while before I
> remember to check the default APN config.
> >>> BTW, when you are talking about QMAP, did you mean utilizing the QMAP
> >>> demux module from the kernel as it is or implementing the WWAN
> >>> subsystem ops for the qmi_wwan module. In other words, did you mean
> >>> protocol or implementation?
> >>
> >> I was talking about the (lack of) muxing setup support in uqmi.  There
> >> is no way to tell the modem firmware how the different channels are
> >> supposed to be connected.
> >
> > Ouch, now I got this too. Whether the --profile  option serves
> > this purpose, or do we need to implement some other message?
> >
> > I know this goes beyond the APN change discussion, but since such a
> > case presented itself, I want to ask you a question. What do you think
> > about turning the current linux QMAP implementation into a library and
> > use it within the qmi_wwan driver to implement the data channels
> > demuxing that is controlled via the WWAN ops?
> >
> > I would like to try this, but I have been pointed out a couple of
> > times about the complexity of the Qualcomm protocols, so I am just
> > afraid to propose such a change :)
>
> I'm not sure I understand what you want to do.  Muxing is sort-of
> supported in qmi_wwan. But the proper solution is to use the rmnet
> driver on top of it. The legacy implementation in qmi_wwan doesn't
> support QMAPv5, and probably won't since I don't think we can add that
> without more userspace knobs.  And I promised the last change to the
> userspace ABI was ... well,... the LAST one.
>
> As for the PCIe stuff and all that, I assume Qualcomm will support that
> using the rmnet driver on top of the PCIe transport drivers.  If they
> continue to support QMAP/QMI/RMNET it at all?  The last I heard, they
> wanted to go all-in for MBIM.  Which makes muxing so much easier.
>
> Wrt useerspace, there is QMAP support in libqmi. Having similar i uqmi
> might be nice, but it's probably not the feature most people are
> missing.
>
>
> Bjørn

___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: Upstreaming hostapd patches 300-noscan.patch and 360-ctrl_iface_reload.patch

2021-12-16 Thread Felix Fietkau

Hi Arnout,

On 2021-12-16 18:00, Arnout Vandecappelle wrote:

   Since I want to use these features outside of OpenWrt, I'd like to upstream
the patches 300-noscan.patch and 360-ctrl_iface_reload.patch to hostap.

   First of all, I'd like confirmation from you that it's OK to redistribute
those patches under hostap's BSD-3-Clause license rather than OpenWrt's GPL-2.0.

   But also, it would help if you remember if there have been any previous
upstreaming attempts. I can of course search for such discussions, but I don't
want to waste time on a wild goose chase.
I'm fine with upstreaming and redistributing those changes under 
BSD-3-Clause. I'm not aware of any previous upstreaming attempts.


Thanks for working on this!

- Felix

___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Upstreaming hostapd patches 300-noscan.patch and 360-ctrl_iface_reload.patch

2021-12-16 Thread Arnout Vandecappelle

 Hi Felix,

 Since I want to use these features outside of OpenWrt, I'd like to upstream 
the patches 300-noscan.patch and 360-ctrl_iface_reload.patch to hostap.


 First of all, I'd like confirmation from you that it's OK to redistribute 
those patches under hostap's BSD-3-Clause license rather than OpenWrt's GPL-2.0.


 But also, it would help if you remember if there have been any previous 
upstreaming attempts. I can of course search for such discussions, but I don't 
want to waste time on a wild goose chase.



 Thanks!


 Regards,
 Arnout


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[PATCH 21.02] busybox: backport dd support for iflag=count_bytes

2021-12-16 Thread Rafał Miłecki
From: Rafał Miłecki 

It's very useful flag for handling various formats in sysupgrade. This
commits comes from 1.34.0 release.

Signed-off-by: Rafał Miłecki 
---
 .../001-dd-support-iflag-count_bytes.patch| 140 ++
 1 file changed, 140 insertions(+)
 create mode 100644 
package/utils/busybox/patches/001-dd-support-iflag-count_bytes.patch

diff --git 
a/package/utils/busybox/patches/001-dd-support-iflag-count_bytes.patch 
b/package/utils/busybox/patches/001-dd-support-iflag-count_bytes.patch
new file mode 100644
index 00..c195c10cf1
--- /dev/null
+++ b/package/utils/busybox/patches/001-dd-support-iflag-count_bytes.patch
@@ -0,0 +1,140 @@
+From 4eb46e1be6d88eaf077252ce93127ebf00aa8ef2 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= 
+Date: Wed, 24 Mar 2021 16:01:42 +0100
+Subject: [PATCH] dd: support iflag=count_bytes
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+It allows passing amount of bytes in the count=
+
+function old new   delta
+packed_usage   33599   33617 +18
+static.iflag_words29  41 +12
+dd_main 16011607  +6
+--
+(add/remove: 0/0 grow/shrink: 3/0 up/down: 36/0)   Total: 36 bytes
+
+Signed-off-by: Rafał Miłecki 
+Signed-off-by: Denys Vlasenko 
+---
+ coreutils/dd.c  | 50 -
+ testsuite/dd/dd-count-bytes |  1 +
+ 2 files changed, 33 insertions(+), 18 deletions(-)
+ create mode 100644 testsuite/dd/dd-count-bytes
+
+--- a/coreutils/dd.c
 b/coreutils/dd.c
+@@ -59,7 +59,7 @@
+ //usage:   "[if=FILE] [of=FILE] [" IF_FEATURE_DD_IBS_OBS("ibs=N obs=N/") 
"bs=N] [count=N] [skip=N] [seek=N]\n"
+ //usage:  IF_FEATURE_DD_IBS_OBS(
+ //usage:   "  [conv=notrunc|noerror|sync|fsync]\n"
+-//usage:   "  [iflag=skip_bytes|fullblock|direct] 
[oflag=seek_bytes|append|direct]"
++//usage:   "  [iflag=skip_bytes|count_bytes|fullblock|direct] 
[oflag=seek_bytes|append|direct]"
+ //usage:  )
+ //usage:#define dd_full_usage "\n\n"
+ //usage:   "Copy a file with converting and formatting\n"
+@@ -82,6 +82,7 @@
+ //usage: "\n  conv=fsync  Physically write data out before 
finishing"
+ //usage: "\n  conv=swab   Swap every pair of bytes"
+ //usage: "\n  iflag=skip_bytesskip=N is in bytes"
++//usage: "\n  iflag=count_bytes   count=N is in bytes"
+ //usage: "\n  oflag=seek_bytesseek=N is in bytes"
+ //usage: "\n  iflag=directO_DIRECT input"
+ //usage: "\n  oflag=directO_DIRECT output"
+@@ -136,21 +137,22 @@ enum {
+   FLAG_SWAB= (1 << 4) * ENABLE_FEATURE_DD_IBS_OBS,
+   /* end of conv flags */
+   /* start of input flags */
+-  FLAG_IFLAG_SHIFT = 5,
+-  FLAG_SKIP_BYTES = (1 << 5) * ENABLE_FEATURE_DD_IBS_OBS,
+-  FLAG_FULLBLOCK = (1 << 6) * ENABLE_FEATURE_DD_IBS_OBS,
+-  FLAG_IDIRECT = (1 << 7) * ENABLE_FEATURE_DD_IBS_OBS,
++  FLAG_IFLAG_SHIFT   = 5,
++  FLAG_SKIP_BYTES= (1 << 5) * ENABLE_FEATURE_DD_IBS_OBS,
++  FLAG_COUNT_BYTES   = (1 << 6) * ENABLE_FEATURE_DD_IBS_OBS,
++  FLAG_FULLBLOCK = (1 << 7) * ENABLE_FEATURE_DD_IBS_OBS,
++  FLAG_IDIRECT   = (1 << 8) * ENABLE_FEATURE_DD_IBS_OBS,
+   /* end of input flags */
+   /* start of output flags */
+-  FLAG_OFLAG_SHIFT = 8,
+-  FLAG_SEEK_BYTES = (1 << 8) * ENABLE_FEATURE_DD_IBS_OBS,
+-  FLAG_APPEND = (1 << 9) * ENABLE_FEATURE_DD_IBS_OBS,
+-  FLAG_ODIRECT = (1 << 10) * ENABLE_FEATURE_DD_IBS_OBS,
++  FLAG_OFLAG_SHIFT   = 9,
++  FLAG_SEEK_BYTES= (1 << 9) * ENABLE_FEATURE_DD_IBS_OBS,
++  FLAG_APPEND= (1 << 10) * ENABLE_FEATURE_DD_IBS_OBS,
++  FLAG_ODIRECT   = (1 << 11) * ENABLE_FEATURE_DD_IBS_OBS,
+   /* end of output flags */
+-  FLAG_TWOBUFS = (1 << 11) * ENABLE_FEATURE_DD_IBS_OBS,
+-  FLAG_COUNT   = 1 << 12,
+-  FLAG_STATUS_NONE = 1 << 13,
+-  FLAG_STATUS_NOXFER = 1 << 14,
++  FLAG_TWOBUFS   = (1 << 12) * ENABLE_FEATURE_DD_IBS_OBS,
++  FLAG_COUNT = 1 << 13,
++  FLAG_STATUS_NONE   = 1 << 14,
++  FLAG_STATUS_NOXFER = 1 << 15,
+ };
+ 
+ static void dd_output_status(int UNUSED_PARAM cur_signal)
+@@ -175,8 +177,9 @@ static void dd_output_status(int UNUSED_
+   //So far we react to it (we print the stats),
+   //status=none only suppresses final, non-USR1 generated status message.
+ # endif
+-  fprintf(stderr, "%llu bytes (%sB) copied, ",
+-  G.total_bytes,
++  fprintf(stderr, /*G.total_bytes < 1024
++  ? "%llu bytes copied, " : */ "%llu bytes (%sB) 
copied, "
++  , G.total_bytes,
+  

CPU_TYPE "xxx" doesn't correspond to a known type

2021-12-16 Thread Florian Eckert

Hello,

If I execute the following command in the openwrt project:
./scripts/dump-target-info.pl targets

I get the this output! I don't know if this is a mistake or if it is 
intentional.

The warning was added by this commit
https://gitlab.dev.tdt.de/dev/sys6/upstream/openwrt/-/commit/d3bc11857af788e185e8a3ece26ce40757cf3965


Output:
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a15" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a5" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "arm926ej-s" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "arm1176jzf-s" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a72" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "fa526" doesn't 
correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a15" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "xscale" doesn't 
correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a72" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "arm926ej-s" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a8" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "arm926ej-s" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "mpcore" doesn't 
correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a8" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a7" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" 
doesn't correspond to a known type
/home/feckert/openwrt/include/target.mk:256: CPU_TYPE "cortex-a9" 
doesn't correspond to a known type


apm821xx/nand powerpc_464fp
apm821xx/sata powerpc_464fp
arc770/generic arc_arc700
archs38/generic arc_archs
armvirt/32 arm_cortex-a15_neon-vfpv4
armvirt/64 aarch64_cortex-a53
at91/sam9x arm_arm926ej-s
at91/sama5 arm_cortex-a5_vfpv4
ath25/generic mips_mips32
ath79/generic mips_24kc
ath79/mikrotik mips_24kc
ath79/nand mips_24kc
ath79/tiny mips_24kc
bcm27xx/bcm2708 arm_arm1176jzf-s_vfp
bcm27xx/bcm2709 arm_cortex-a7_neon-vfpv4
bcm27xx/bcm2710 aarch64_cortex-a53
bcm27xx/bcm2711 aarch64_cortex-a72
bcm47xx/generic mipsel_mips32
bcm47xx/legacy mipsel_mips32
bcm47xx/mips74k mipsel_74kc
bcm4908/generic aarch64_cortex-a53
bcm53xx/generic arm_cortex-a9
bcm63xx/generic mips_mips32
bcm63xx/smp mips_mips32
gemini/generic arm_fa526
imx/cortexa7 arm_cortex-a7_neon-vfpv4
imx/cortexa9 arm_cortex-a9_neon
ipq40xx/generic arm_cortex-a7_neon-vfpv4
ipq40xx/mikrotik arm_cortex-a7_neon-vfpv4
ipq806x/generic arm_cortex-a15_neon-vfpv4
kirkwood/generic arm_xscale
lantiq/ase mips_mips32
lantiq/xrx200 mips_24kc
lantiq/xway mips_24kc
lantiq/xway_legacy mips_24kc
layerscape/armv7 arm_cortex-a7_neon-vfpv4
layerscape/armv8_64b aarch64_generic
malta/be mips_24kc
mediatek/mt7622 aarch64_cortex-a53
mediatek/mt7623 arm_cortex-a7_neon-vfpv4
mediatek/mt7629 arm_cortex-a7
mpc85xx/p1010 powerpc_8540
mpc85xx/p1020 powerpc_8540
mpc85xx/p2020 powerpc_8540
mvebu/cortexa53 aarch64_cortex-a53
mvebu/cortexa72 aarch64_cortex-a72
mvebu/cortexa9 arm_cortex-a9_vfpv3-d16
mxs/generic arm_arm926ej-s
octeon/generic mips64_octeonplus
octeontx/generic aarch64_generic
omap/generic arm_cortex-a8_vfpv3
oxnas/ox820 arm_mpcore
pistachio/generic mipsel_24kc_24kf
ramips/mt7620 mipsel_24kc
ramips/mt7621 mipsel_24kc
ramips/mt76x8 mipsel_24kc
ramips/rt288x mipsel_24kc
ramips/rt305x mipsel_24kc
ramips/rt3883 mipsel_74kc
realtek/generic mips_4kec
rockchip/armv8 aarch64_generic
sunxi/cortexa53 aarch64_cortex-a53
sunxi/cortexa7