[OpenWrt-Devel] [PATCH v2] ramips: create R6220 dtsi and improve WNDR3700v5 support

2019-05-26 Thread Jan Hoffmann
missing pinctrl groups * use switch port instead of VLAN as trigger for WAN LED Fixes for WNDR3700v5: * all LEDS work * correct ethernet MAC addresses Signed-off-by: Jan Hoffmann --- v2: - use correct license header for DTS - more detailed description

[PATCH] mac80211: allow ACS restriction with fixed channel

2020-07-03 Thread Jan Hoffmann
This can be useful when a DFS channel is configured, as the ACS channel list is taken into account when switching channels after a radar event. For example, this allows to prevent the SRD channels from being used in that case. Signed-off-by: Jan Hoffmann --- package/kernel/mac80211/files/lib

[RFT PATCH] ramips: use partition table on Netgear NAND devices

2020-06-28 Thread Jan Hoffmann
in commit 527832e54bf3bc4d699a145ae66f34230246f0a9. Signed-off-by: Jan Hoffmann --- So far this patch has only been tested on my own WAC124, which doesn't have any bad blocks (i.e. the partition table that is read from flash matches the existing fixed offsets). It needs further testing to verify

[PATCH v2] ramips: add support for NETGEAR WAC124

2020-06-26 Thread Jan Hoffmann
, WPS LED: Power, Internet, WiFi, USB (all green) Installation: The factory image can be flashed from the stock firmware web interface or using nmrpflash. With nmrpflash it is also possible to revert to stock firmware. Signed-off-by: Jan Hoffmann --- v2: - more detailed commit message

[PATCH v2 0/2] ramips: use partition table on Netgear NAND devices

2021-02-25 Thread Jan Hoffmann
any bad blocks. This series adds a partition table parser and uses it instead of the fixed partitions. v2: - split into separate parts for parser and DTS changes Jan Hoffmann (2): ramips: add Sercomm partition map parser ramips: use partition parser on Netgear CHJ/BZV .../dts

[PATCH v2 1/2] ramips: add Sercomm partition map parser

2021-02-25 Thread Jan Hoffmann
as it did not seem to work correctly. However, this was only due the NAND driver transparently shifting pages to hide bad blocks, which was fixed in commit 527832e54bf3bc4d699a145ae66f34230246f0a9. Signed-off-by: Jan Hoffmann --- .../ramips/files/drivers/mtd/parsers/scpart.c | 257

[PATCH v2 2/2] ramips: use partition parser on Netgear CHJ/BZV

2021-02-25 Thread Jan Hoffmann
that existed during manufacturing. Thus the partition table needs to be parsed for the device to work correctly. A typical issue that occurs otherwise is degraded wireless performance, when the calibration data cannot be found at the expected offset. Signed-off-by: Jan Hoffmann --- .../dts

Re: [PATCH v2 2/2] ramips: use partition parser on Netgear CHJ/BZV

2021-02-26 Thread Jan Hoffmann
> What about R6220 ? R6220 and WAC104 do not have a partition table stored on flash. They use fixed partitions also on stock firmware. Jan ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org

[PATCH] ltq-vdsl: add missing backslash

2021-08-21 Thread Jan Hoffmann
This error was introduced with the recent cleanup. Signed-off-by: Jan Hoffmann --- package/kernel/lantiq/ltq-vdsl/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package/kernel/lantiq/ltq-vdsl/Makefile b/package/kernel/lantiq/ltq-vdsl/Makefile index f45895ba33

[PATCH] ltq-vdsl/ltq-vdsl-app: clean up configure args

2021-08-19 Thread Jan Hoffmann
included in the source. ReTx counters are already included with model type full. This increases the size of the userspace application by approximately 15 kB (uncompressed). The kernel module does not change at all. Signed-off-by: Jan Hoffmann --- If size is a concern, the option --enable-dsl-pm

[PATCH 1/4] ltq-vectoring: add driver

2022-03-13 Thread Jan Hoffmann
to support recent kernel versions and a change of the used interface from ptm0 to dsl0. Signed-off-by: Jan Hoffmann --- package/kernel/lantiq/ltq-vectoring/Makefile | 61 + .../patches/001-fix-compile.patch | 95 ++ .../ltq-vectoring/patches/100-cleanup.patch | 73

[PATCH 3/4] ltq-vdsl-app: set MAC address for vectoring error reports

2022-03-13 Thread Jan Hoffmann
, but connection has not started yet). Signed-off-by: Jan Hoffmann --- .../config/ltq-vdsl-app/files/dsl_control | 20 +-- 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/package/network/config/ltq-vdsl-app/files/dsl_control b/package/network/config/ltq-vdsl-app/files

[PATCH 0/4] lantiq: fix VDSL2 vectoring

2022-03-13 Thread Jan Hoffmann
users who previously experienced instability on vectoring-enabled VDSL2 lines have reported that these patches actually allow a stable connection. [0] https://forum.openwrt.org/t/vectoring-on-lantiq-vrx200-vr9-missing-callback-for-sending-error-samples/104046 Jan Hoffmann (4): ltq-vectoring: add

[PATCH 4/4] ltq-vdsl-mei: add locking to interrupt handler

2022-03-13 Thread Jan Hoffmann
, or is still before the interrupt mask check, and is thus going to detect the change. Signed-off-by: Jan Hoffmann --- package/kernel/lantiq/ltq-vdsl-mei/Makefile | 2 +- .../patches/200-interrupt-lock.patch | 45 +++ 2 files changed, 46 insertions(+), 1 deletion

[PATCH 2/4] ltq-vdsl-mei: enable vectoring error sample callback

2022-03-13 Thread Jan Hoffmann
This re-enables the vectoring error sample callback and adds a dependency to the corresponding driver. Signed-off-by: Jan Hoffmann --- package/kernel/lantiq/ltq-vdsl-mei/Makefile | 4 ++-- .../lantiq/ltq-vdsl-mei/patches/100-compat.patch | 11 --- 2 files changed, 2

[PATCH] lantiq: fritz7362sl: add partition subnode for SPI flash

2022-03-16 Thread Jan Hoffmann
that partition by a script. Fixes: #8983 Signed-off-by: Jan Hoffmann --- .../boot/dts/lantiq/vr9_avm_fritz7362sl.dts | 34 +++ 1 file changed, 20 insertions(+), 14 deletions(-) diff --git a/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_avm_fritz7362sl.dts b/target

[PATCH] ltq-vdsl/ltq-adsl: fix elapsed time calculation

2022-04-25 Thread Jan Hoffmann
variant is only compile-tested, but it should also work as the relevant code is identical. Signed-off-by: Jan Hoffmann --- package/kernel/lantiq/ltq-adsl/Makefile | 2 +- .../patches/200-fix-elapsed-time.patch| 122 ++ package/kernel/lantiq/ltq-vdsl/Makefile

[PATCH] ltq-atm/ltq-ptm: avoid unnecessary build dependencies

2022-04-25 Thread Jan Hoffmann
on the specific package variants, so they are only built when actually needed. Signed-off-by: Jan Hoffmann --- package/kernel/lantiq/ltq-atm/Makefile | 13 + package/kernel/lantiq/ltq-ptm/Makefile | 4 ++-- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/package/kernel

Re: [PATCH 0/7] realtek: add HPE 1920 support

2022-07-28 Thread Jan Hoffmann
This adds support for three switches from the HPE 1920 series. It has been tested on HPE 1920-8G and HPE 1920-16G. Support for HPE 1920-24G is also included, as it uses the same board as the 16-port model. The patch series depends on the firmware-utils patch adding the mkh3cimg and mkh3cvfs

[PATCH 4/7] realtek: clean up rtl838x MDIO busy wait loop

2022-07-23 Thread Jan Hoffmann
is not serviced during PHY patching which can take multiple seconds. Signed-off-by: Jan Hoffmann --- .../drivers/net/dsa/rtl83xx/rtl838x.c | 37 +++ 1 file changed, 22 insertions(+), 15 deletions(-) diff --git a/target/linux/realtek/files-5.10/drivers/net/dsa/rtl83xx

[PATCH 1/7] realtek: rtl83xx-phy: fix RTL8214FC media change

2022-07-23 Thread Jan Hoffmann
Toggle power on the individual PHY instead of the package. Otherwise a media change always toggles power on the first port, and not the one that is being configured. Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/phy/rtl83xx-phy.c | 32 +-- 1 file changed, 16

[PATCH 6/7] tools: add 7z host package

2022-07-23 Thread Jan Hoffmann
of the public-domain LZMA SDK. That would require repackaging the source package, as it is only provided in 7z format.) Signed-off-by: Jan Hoffmann --- tools/7z/Makefile | 36 tools/Makefile| 1 + 2 files changed, 37 insertions(+) create mode 100644 tools

[PATCH firmware-utils] mkh3cimg/mkh3cvfs: add image/filesystem tools for H3C devices

2022-07-23 Thread Jan Hoffmann
the size of the filesystem is hardcoded in the bootloader, an image that is only slightly larger than its content is sufficient, as long as no write operations are to be performed on it. This allows to append further data (i.e. rootfs) after the end of the generated image. Signed-off-by: Jan

[PATCH 3/7] realtek: add SFP support for RTL8214FC PHY

2022-07-23 Thread Jan Hoffmann
Probe the SFP module during PHY initialization and implement insertion/removal handlers to automatically configure the media type of the respective port. Suggested-by: Birger Koblitz Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/phy/rtl83xx-phy.c | 26 ++- 1 file

[PATCH 0/7] realtek: add HPE 1920 support

2022-07-23 Thread Jan Hoffmann
tools. Jan Hoffmann (7): realtek: rtl83xx-phy: fix RTL8214FC media change realtek: rtl83xx-phy: decouple RTL8214FC media change and power config realtek: add SFP support for RTL8214FC PHY realtek: clean up rtl838x MDIO busy wait loop kernel: mtdsplit: add support for H3C VFS filesystem

[PATCH 7/7] realtek: add support for HPE 1920 series

2022-07-23 Thread Jan Hoffmann
know about this, you must not do any file operations in the bootloader, as this may corrupt the OpenWrt installation (selecting the boot image is an exception, as it only stores a flag in the bootloader data, but doesn't write to the filesystem). Signed-off-by: Jan Hoffmann --- .../realtek/base-file

[PATCH 5/7] kernel: mtdsplit: add support for H3C VFS filesystem

2022-07-23 Thread Jan Hoffmann
the layout of one generated by mkh3cvfs, with a filename of "openwrt-kernel.bin" for the kernel image. Signed-off-by: Jan Hoffmann --- target/linux/generic/config-5.10 | 1 + target/linux/generic/config-5.15 | 1 + .../files/drivers/mtd/mtdsplit/Kconfig

[PATCH 2/7] realtek: rtl83xx-phy: decouple RTL8214FC media change and power config

2022-07-23 Thread Jan Hoffmann
, as this is actually not SoC-specific. Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/phy/rtl83xx-phy.c | 122 ++ 1 file changed, 70 insertions(+), 52 deletions(-) diff --git a/target/linux/realtek/files-5.10/drivers/net/phy/rtl83xx-phy.c b/target/linux/realtek/files-5.10

[PATCH firmware-utils v2 2/2] mkh3cvfs: add filesystem tool for H3C devices

2022-07-27 Thread Jan Hoffmann
. However, an image that is only slightly larger than its content is sufficient, as long as no write operations are performed in the bootloader menu. This allows to append further data (i.e. rootfs) after the end of the filesystem image. Signed-off-by: Jan Hoffmann --- CMakeLists.txt | 1 + src

[PATCH firmware-utils v2 0/2] add tools for H3C devices

2022-07-27 Thread Jan Hoffmann
- clean up numbering of reserved struct fields in mkh3cvfs Jan Hoffmann (2): mkh3cimg: add image tool for H3C devices mkh3cvfs: add filesystem tool for H3C devices CMakeLists.txt | 2 + src/mkh3cimg.c | 366 ++ src/mkh3cv

[PATCH firmware-utils v2 1/2] mkh3cimg: add image tool for H3C devices

2022-07-27 Thread Jan Hoffmann
, in this case the supplied input file needs to be a 7z archive with LZMA compression. Signed-off-by: Jan Hoffmann --- CMakeLists.txt | 1 + src/mkh3cimg.c | 366 + 2 files changed, 367 insertions(+) create mode 100644 src/mkh3cimg.c diff --git

Re: [PATCH firmware-utils] mkh3cimg/mkh3cvfs: add image/filesystem tools for H3C devices

2022-07-24 Thread Jan Hoffmann
+struct file_entry { [...] + uint8_t res0[5]; [...] + uint8_t res3[3]; [...] + uint8_t res4[2]; I just noticed there is a gap in the numbering of the reserved fields. There is no meaning in that, I just overlooked it here (I actually noticed this before and cleaned it up in

[PATCH] ltq-vdsl-app: disconnect when service is stopped

2022-04-27 Thread Jan Hoffmann
script. However, doing it in the daemon itself has the advantage of also working if it is terminated in another way (for example during sysupgrade). Signed-off-by: Jan Hoffmann --- .../ltq-vdsl-app/patches/200-autoboot.patch | 75 +++ .../ltq-vdsl-app/patches/201-sigterm.patch

[PATCH] realtek: don't set L2LEARNING flag in rtl83xx TX header

2022-10-20 Thread Jan Hoffmann
report. The severity of flooding is also somewhat limited, as the eth0 address does not need an entry in the forwarding table (it is written to a special MAC address register in the switch). Fixes: 9eab76c84e31 ("realtek: Improve TX CPU-Tag usage") Signed-off-by: Jan Hoffmann --- R

Re: [PATCH v2 0/2] realtek: fix L2 entry setup and learning on CPU port

2022-10-26 Thread Jan Hoffmann
On 26.10.22 at 10:20, Sander Vanheule wrote: Hi Jan, On Wed, 2022-10-26 at 00:20 +0200, Jan Hoffmann wrote: This is a follow-up to the patch "realtek: don't set L2LEARNING flag in rtl83xx TX header". An undesired effect of that patch is flooding of some packets destined for the

Re: [PATCH v2 2/2] realtek: use assisted learning on CPU port

2022-10-26 Thread Jan Hoffmann
On 26.10.22 at 00:20, Jan Hoffmann wrote: L2 learning on the CPU port is currently not consistently configured and relies on the default configuration of the device. On RTL83xx, it is disabled for packets transmitted with a TX header, as hardware learning corrupts the forwarding table otherwise

[PATCH v2 2/2] realtek: use assisted learning on CPU port

2022-10-25 Thread Jan Hoffmann
to let DSA write FDB entries to the switch. For now, this does not sync local/bridge entries to the switch. However, support for that was added in Linux 5.14, so the next switch to a newer kernel version is going to fix this. Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx

[PATCH v2 1/2] realtek: set up L2 table entries properly

2022-10-25 Thread Jan Hoffmann
at end of statement). Also remove the unneeded priv parameter and debug print for the multicast entry setup function. Fixes: cde31976e37 ("realtek: Add support for Layer 2 Multicast") Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 29 -

[PATCH v2 0/2] realtek: fix L2 entry setup and learning on CPU port

2022-10-25 Thread Jan Hoffmann
ALRN shift offset clearer - define SALRN values, mask and shift offset in header Jan Hoffmann (2): realtek: set up L2 table entries properly realtek: use assisted learning on CPU port .../files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 45 ++- .../drivers/net/dsa/rtl83xx

Re: [PATCH v2 2/2] realtek: use assisted learning on CPU port

2022-10-28 Thread Jan Hoffmann
On 26.10.22 at 23:39, Jan Hoffmann wrote: On 26.10.22 at 00:20, Jan Hoffmann wrote: L2 learning on the CPU port is currently not consistently configured and relies on the default configuration of the device. On RTL83xx, it is disabled for packets transmitted with a TX header, as hardware

[PATCH 0/2] realtek: fix L2 entry setup and learning on CPU port

2022-10-21 Thread Jan Hoffmann
PE 1920-8G) and RTL839x (HPE 1920-48G). Jan Hoffmann (2): realtek: set up L2 table entries properly realtek: use assisted learning on CPU port .../files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 45 ++- 1 file changed, 35 insertions(+), 10 deletions(-)

[PATCH 2/2] realtek: use assisted learning on CPU port

2022-10-21 Thread Jan Hoffmann
to let DSA write FDB entries to the switch. For now, this does not sync local/bridge entries to the switch. However, support for that was added in Linux 5.14, so the next switch to a newer kernel version is going to fix this. Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx

[PATCH 1/2] realtek: set up L2 table entries properly

2022-10-21 Thread Jan Hoffmann
at end of statement). Also remove the unneeded priv parameter and debug print for the multicast entry setup function. Fixes: cde31976e37 ("realtek: Add support for Layer 2 Multicast") Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 29 -

[PATCH] realtek: fix RTL839x egress tag for ports >= 32

2022-09-25 Thread Jan Hoffmann
Don't overwrite AS_DPM and L2LEARNING flags when dest_port is >= 32. Fixes: 1773264a0c6d ("realtek: correct egress frame port verification") Signed-off-by: Jan Hoffmann --- .../linux/realtek/files-5.10/drivers/net/ethernet/rtl838x_eth.c | 2 +- 1 file changed, 1 insertion(+

[PATCH 5/5] realtek: restructure rtl_table_read/write

2022-10-14 Thread Jan Hoffmann
by logging an error, but a return value is added to allow proper handling in the future. Signed-off-by: Jan Hoffmann --- I'm not really sure if putting cond_resched in this place is really the best solution. An alternative would be to place it directly in the loops (i.e. rtl83xx_port_fdb_dump

[PATCH 0/5] realtek: avoid blocking for too long

2022-10-14 Thread Jan Hoffmann
by moving to threaded printk. Jan Hoffmann (5): realtek: avoid busy waiting for RTL839x PHY read/write realtek: simplify log messages in rtl83xx_mdio_probe realtek: add debugfs node for L2 table realtek: reduce excessive logging for FDB operations realtek: restructure rtl_table_read/write

[PATCH 1/5] realtek: avoid busy waiting for RTL839x PHY read/write

2022-10-14 Thread Jan Hoffmann
Switch to a polling implementation similar to the one for RTL838x, to allow other kernel tasks to run while waiting. Signed-off-by: Jan Hoffmann --- .../drivers/net/dsa/rtl83xx/rtl839x.c | 45 ++- 1 file changed, 33 insertions(+), 12 deletions(-) diff --git a/target

[PATCH 3/5] realtek: add debugfs node for L2 table

2022-10-14 Thread Jan Hoffmann
This allows to view all unicast and multicast entries that are currently in the L2 hash table and the CAM. Signed-off-by: Jan Hoffmann --- .../drivers/net/dsa/rtl83xx/debugfs.c | 107 ++ 1 file changed, 107 insertions(+) diff --git a/target/linux/realtek/files-5.10

[PATCH 4/5] realtek: reduce excessive logging for FDB operations

2022-10-14 Thread Jan Hoffmann
eplacement. Change the remaining messages to KERN_DEBUG level. Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 55 +-- .../drivers/net/dsa/rtl83xx/rtl930x.c | 16 -- 2 files changed, 3 insertions(+), 68 deletions(-) diff --git a/ta

[PATCH 2/5] realtek: simplify log messages in rtl83xx_mdio_probe

2022-10-14 Thread Jan Hoffmann
This function currently prints three messages for every switch port at KERN_INFO level. This takes a considerable amount of time during bootup and can even trigger an external watchdog. Replace these log messages by a single one at KERN_DEBUG level. Signed-off-by: Jan Hoffmann --- .../linux

Re: Ethernet switch with linux/openwrt and DSA

2022-12-22 Thread Jan Hoffmann
Hi Janusz, BTW, this switch have some issues with IPv6? Simple remove lan2 from switch/bridge and configure manually - connect my device directly to eth2 port. Seems IPv4 works correctly - while IPv6 not (ping6 ff02::1%lan2 - no answer). Same config (with removed lan2 from bridge) works

[PATCH] realtek: don't relocate kernel on HPE 1920 series

2023-01-05 Thread Jan Hoffmann
This is no longer needed now that the kernel is built with a load address that matches the one hard-coded in the bootloader. Signed-off-by: Jan Hoffmann --- target/linux/realtek/image/Makefile | 14 -- target/linux/realtek/image/common.mk | 2 -- 2 files changed, 16 deletions

[PATCH v2 1/3] realtek: simplify log messages in rtl83xx_mdio_probe

2022-12-17 Thread Jan Hoffmann
This function currently prints three messages for every switch port at KERN_INFO level. This takes a considerable amount of time during bootup and can even trigger an external watchdog. Replace these log messages by a single one at KERN_DEBUG level. Signed-off-by: Jan Hoffmann --- .../realtek

[PATCH v2 3/3] realtek: add cond_resched to loops accessing the FDB table

2022-12-17 Thread Jan Hoffmann
A full loop accessing all FDB entries can take several milliseconds (on RTL839x about 20 ms), so give other kernel tasks a chance to run. This is especially important for rtl83xx_port_fdb_dump which is itself called in a loop for all ports by the kernel. Signed-off-by: Jan Hoffmann

[PATCH v2 0/3] realtek: avoid blocking for too long

2022-12-17 Thread Jan Hoffmann
in rtl83xx_mdio_probe - move cond_resched to loops - support kernel 5.15 Jan Hoffmann (3): realtek: simplify log messages in rtl83xx_mdio_probe realtek: restructure rtl_table_read/write realtek: add cond_resched to loops accessing the FDB table .../drivers/net/dsa/rtl83xx/common.c | 49

[PATCH v2 2/3] realtek: restructure rtl_table_read/write

2022-12-17 Thread Jan Hoffmann
poll, any callers doing many table accesses still need to make sure not to block other kernel tasks themselves. So far, polling timeout errors are only handled by logging an error, but a return value is added to allow proper handling in the future. Signed-off-by: Jan Hoffmann --- .../drivers/net

[PATCH v2] realtek: don't set L2LEARNING flag in rtl83xx TX header

2022-12-17 Thread Jan Hoffmann
ther ports. In that case, the switch would incorrectly learn the CPU port as source. An example that triggered this issue are Multicast Listener Reports and IGMP membership reports. Signed-off-by: Jan Hoffmann --- Changes in v2: - update commit message - support kernel 5.15 .../realtek/files-5.10/d

Re: Ethernet switch with linux/openwrt and DSA

2022-12-14 Thread Jan Hoffmann
Hi Janusz, > Could I just buy (any experience): > > HP switch 1920-24G JG924A > Do I need to check any HW ver? Or any JG924A should work? The devices from HPE 1920 series with model numbers JG92xA are all Realtek-based, and should be compatible with OpenWrt (make sure not to get a device

Re: Ethernet switch with linux/openwrt and DSA

2022-12-14 Thread Jan Hoffmann
Hi Janusz, > Could I just buy (any experience): > > HP switch 1920-24G JG924A > Do I need to check any HW ver? Or any JG924A should work? The devices from HPE 1920 series with model numbers JG92xA are all Realtek-based, and should be compatible with OpenWrt (make sure not to get a device from

[PATCH] ipq40xx: add PCIe magic hack to improve VRX518 compatibility

2023-01-30 Thread Jan Hoffmann
his shouldn't affect any devices other than FRITZ!Box 7530/7520. Signed-off-by: Jan Hoffmann --- .../boot/dts/qcom-ipq4019-fritzbox-7530.dts | 2 + .../997-pcie-qcom-host-magic.patch| 215 ++ 2 files changed, 217 insertions(+) create mode 100644 target/linux/ipq4

[PATCH] ramips: use on-flash partition table for Sercomm BZV/CHJ

2023-01-27 Thread Jan Hoffmann
these issues. Replace the two reserved partitions by the full partition list, as the driver does not allow merging them. Signed-off-by: Jan Hoffmann --- I only tested on a WAC124 without any bad blocks, but the kernel log shows that the partition map parser is used. This issue seems to be quite common

[PATCH] ltq-vdsl-vr9: fix upstream MINEFTR

2023-01-28 Thread Jan Hoffmann
The upstream value read from the device seems to already be in bits per second, so there is no need to multiply by 1000 again (which for typical values causes an overflow of the 32-bit unsigned integer). Signed-off-by: Jan Hoffmann --- This patch is already applied for ltq-vdsl-vr11

[PATCH] ltq-*-app: extend ubus metrics/statistics

2023-01-28 Thread Jan Hoffmann
Expose a few additional useful values via ubus: - Channel error counters (CRC, FEC) - Retransmission counters (MINEFTR, LEFTRS) - Impulse noise protection level - Rate adaptation mode - OLR statistics (Bitswap, SRA, SOS) - Pilot tones - Upstream/downstream band information Signed-off-by: Jan

Re: [PATCH] realtek: mark clock source as continuous

2022-10-31 Thread Jan Hoffmann
On 31.10.22 at 10:11, Sander Vanheule wrote: After replacing the R4K event timer and clock source with the new Realtek Otto timer, performance for RTL839x devices was severely impacted, as reported by Hiroshi. Research by Markus showed that after commit 4657a5301eb5 (realtek: avoid busy waiting

[PATCH] realtek: hpe_1920-8g: add phy-handle for SFP ports

2023-03-11 Thread Jan Hoffmann
The switch driver actually expects every port to have a PHY handle, and several branches in the code determine if a port is valid by checking for a non-zero phy field. Signed-off-by: Jan Hoffmann --- target/linux/realtek/dts-5.10/rtl8380_hpe_1920-8g.dts | 2 ++ target/linux/realtek/dts-5.15

[PATCH 4/4] realtek: handle changed flags in VLAN configuration

2023-03-12 Thread Jan Hoffmann
function. Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 41 ++- .../files-5.15/drivers/net/dsa/rtl83xx/dsa.c | 37 + 2 files changed, 43 insertions(+), 35 deletions(-) diff --git a/target/linux/realtek/files-5.10/drivers/net/dsa

[PATCH 0/4] realtek: fix multiple issues with L2 forwarding

2023-03-12 Thread Jan Hoffmann
This series fixes several bugs that can result in packets being forwarded incorrectly. The port isolation and VLAN issues probably remained unnoticed so far, because they only manifest when after a port leaves a bridge, or an existing VLAN membership is changed. Jan Hoffmann (4): realtek

[PATCH 2/4] realtek: initialize port masks to match the default state

2023-03-12 Thread Jan Hoffmann
the traffic_set method in rtl83xx_setup. Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 22 ++- .../files-5.15/drivers/net/dsa/rtl83xx/dsa.c | 22 ++- 2 files changed, 24 insertions(+), 20 deletions(-) diff --git a/target/linux

[PATCH 3/4] realtek: fix standalone ports in presence of static fdb entries

2023-03-12 Thread Jan Hoffmann
learning feature. For now, this is only implemented for RTL838x/RTL839x, as the available set of registers differs for the other devices. Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 16 .../files-5.10/drivers/net/dsa/rtl83xx/rtl838x.c | 10

[PATCH 1/4] realtek: properly update port masks when port leaves bridge

2023-03-12 Thread Jan Hoffmann
, so that any other ports that are currently disabled will be configured correctly when they are enabled. Signed-off-by: Jan Hoffmann --- I originally wanted to put a proper Fixes tag here, but I'm not sure which commit to choose. This bug seems to have existed since this target was introduced

Re: [PATCH 0/6] realtek: fix management of mdb entries

2023-03-10 Thread Jan Hoffmann
Hi Vladimir, Thank you for having a look at this! On 06.03.2023 14:46, Vladimir Oltean wrote: On Sat, Mar 04, 2023 at 01:52:32PM +0300, Arınç ÜNAL wrote: On 4.03.2023 00:48, Jan Hoffmann wrote: This series fixes multiple issues related to the L2 table and multicast table. That includes

[PATCH 6/6] realtek: remove store_mcgroups/load_mcgroups

2023-03-03 Thread Jan Hoffmann
entirely, as the original commit message doesn't offer a convincing reason why this would be necessary in the first place. Fixes: 724e4af530cd ("realtek: Store and Restore MC memberships for port enable/disable") Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx/d

[PATCH 2/6] realtek: don't return 0 from rtl83xx_mc_group_alloc on failure

2023-03-03 Thread Jan Hoffmann
This function returns the index of the allocated multicast group entry, so the return value should be negative when no entry was allocated. Fixes: cde31976e375 ("realtek: Add support for Layer 2 Multicast") Signed-off-by: Jan Hoffmann --- I'm not entirely sure about this p

[PATCH 5/6] realtek: don't add CPU port to multicast portmasks

2023-03-03 Thread Jan Hoffmann
the CPU port, even if it was explicitly created. Fixes: 724e4af530cd ("realtek: Store and Restore MC memberships for port enable/disable") Signed-off-by: Jan Hoffmann --- .../linux/realtek/files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 7 ++- .../linux/realtek/files-5.15/drivers/net/dsa/rtl

[PATCH 3/6] realtek: don't treat first multicast portmask entry as reserved

2023-03-03 Thread Jan Hoffmann
, a corresponding decrement was missing, causing the wrong entry to be marked as free. Fixes: cde31976e375 ("realtek: Add support for Layer 2 Multicast") Signed-off-by: Jan Hoffmann --- target/linux/realtek/files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 1 - target/linux/realtek/files-5.15/d

[PATCH 0/6] realtek: fix management of mdb entries

2023-03-03 Thread Jan Hoffmann
working. However, one important missing piece is forwarding of all multicast traffic to multicast router ports (as specified in section 2.1.2-1 of RFC4541). As far as I can see, this is a general issue that affects all DSA switches, and cannot be fixed without changes to the DSA subsystem. Jan

[PATCH 1/6] realtek: fix writing/deletion of CAM entries

2023-03-03 Thread Jan Hoffmann
Actually use the index returned by rtl83xx_find_l2_cam_entry. Fixes: cde31976e375 ("realtek: Add support for Layer 2 Multicast") Signed-off-by: Jan Hoffmann --- .../realtek/files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 8 .../realtek/files-5.15/drivers/net/dsa/rtl83xx/dsa.

[PATCH 4/6] realtek: actually remove port from multicast portmask

2023-03-03 Thread Jan Hoffmann
Fixes: 724e4af530cd ("realtek: Store and Restore MC memberships for port enable/disable") Signed-off-by: Jan Hoffmann --- target/linux/realtek/files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 1 + target/linux/realtek/files-5.15/drivers/net/dsa/rtl83xx/dsa.c | 1 + 2 files changed, 2

Re: [PATCH 2/6] realtek: don't return 0 from rtl83xx_mc_group_alloc on failure

2023-03-03 Thread Jan Hoffmann
On 2023-03-03 at 22:48, Jan Hoffmann wrote: This function returns the index of the allocated multicast group entry, so the return value should be negative when no entry was allocated. Fixes: cde31976e375 ("realtek: Add support for Layer 2 Multicast") Signed-off-by: Jan Hoffmann

Re: [PATCH] ipq40xx: add PCIe magic hack to improve VRX518 compatibility

2023-04-25 Thread Jan Hoffmann
On 2023-01-30 at 23:40, Jan Hoffmann wrote: Some VRX518 modems fail to initialize properly with the error message "dc_ep_clk_on failed". As a result, the DSL data path doesn't work. This hack, which is based on code from the FRITZ!Box 7530 GPL archive, fixes the issue. It change

[PATCH] realtek: fix memory leak in netevent handler

2023-02-08 Thread Jan Hoffmann
The net_event_work struct is allocated, but only freed in a single case. Move the allocation to the branch where it is actually needed, and free it after the work has been done. Fixes: 03e1d93e0779 ("realtek: add driver support for routing offload") Signed-off-by: Jan Hoffmann ---

Re: [PATCH] ipq40xx: add PCIe magic hack to improve VRX518 compatibility

2023-01-31 Thread Jan Hoffmann
Hi Robert, On 2023-01-30 at 00:08, Robert Marko wrote: Shouldn't it be possible for the modem driver itself to be fixed instead of faking the PCI details? This hack is definitely far from ideal, but I'm not sure if there is a better way to fix this. Here are a few more details about the

Re: [PATCH] ipq40xx: add PCIe magic hack to improve VRX518 compatibility

2023-02-04 Thread Jan Hoffmann
Am 02.02.23 um 11:54 schrieb Robert Marko: On Tue, 31 Jan 2023 at 23:52, Jan Hoffmann wrote: Hi Robert, On 2023-01-30 at 00:08, Robert Marko wrote: Shouldn't it be possible for the modem driver itself to be fixed instead of faking the PCI details? This hack is definitely far from ideal

[PATCH v2 2/4] realtek: initialize port masks to match the default state

2023-05-06 Thread Jan Hoffmann
the traffic_set method in rtl83xx_setup, instead of writing to the RTL838x_PORT_ISO_CTRL(i) registers directly. Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 23 +-- .../files-5.15/drivers/net/dsa/rtl83xx/dsa.c | 23 +-- 2 files

[PATCH v2 1/4] realtek: properly update port masks when port leaves bridge

2023-05-06 Thread Jan Hoffmann
quot;) [reintroduced incorrect pm field update] Fixes: 27029277f98d ("realtek: add switch driver support for the RTL93XX based switches") Signed-off-by: Jan Hoffmann --- .../realtek/files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 10 +- .../realtek/files-5.15/drivers/net/dsa/rtl83xx/ds

[PATCH v2 4/4] realtek: handle changed flags in VLAN configuration

2023-05-06 Thread Jan Hoffmann
function. Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 42 ++- .../files-5.15/drivers/net/dsa/rtl83xx/dsa.c | 38 + 2 files changed, 43 insertions(+), 37 deletions(-) diff --git a/target/linux/realtek/files-5.10/drivers/net/dsa

[PATCH v2 0/4] realtek: fix multiple issues with L2 forwarding

2023-05-06 Thread Jan Hoffmann
warnings - Removed comment about RTL838X_PORT_ISO_CTRL, as the traffic_set method is now used instead of accessing the register directly - Added Fixes tags for first commit Jan Hoffmann (4): realtek: properly update port masks when port leaves bridge realtek: initialize port masks to match

Re: [PATCH 0/4] realtek: fix multiple issues with L2 forwarding

2023-05-06 Thread Jan Hoffmann
Hi Sander, Thank you for reviewing the patches! On 2023-0430 at 22:39, Sander Vanheule wrote: Hi Jan, On Sun, 2023-03-12 at 23:57 +0100, Jan Hoffmann wrote:   realtek: fix standalone ports in presence of static fdb entries   realtek: handle changed flags in VLAN configuration

[PATCH v2 3/4] realtek: fix standalone ports in presence of static fdb entries

2023-05-06 Thread Jan Hoffmann
learning feature. For now, this is only implemented for RTL838x/RTL839x, as the available set of registers differs for the other devices. Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 15 +++ .../files-5.10/drivers/net/dsa/rtl83xx/rtl838x.c | 10

[PATCH v2 2/6] realtek: don't treat first multicast portmask entry as reserved

2023-05-06 Thread Jan Hoffmann
, a corresponding decrement was missing, causing the wrong entry to be marked as free. Fixes: cde31976e375 ("realtek: Add support for Layer 2 Multicast") Signed-off-by: Jan Hoffmann --- target/linux/realtek/files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 1 - target/linux/realtek/files-5.15/d

[PATCH v2 4/6] realtek: don't add CPU port to multicast portmasks

2023-05-06 Thread Jan Hoffmann
the CPU port, even if it was explicitly created. Fixes: 724e4af530cd ("realtek: Store and Restore MC memberships for port enable/disable") Signed-off-by: Jan Hoffmann --- .../linux/realtek/files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 7 ++- .../linux/realtek/files-5.15/drivers/net/dsa/rtl

[PATCH v2 5/6] realtek: remove store_mcgroups/load_mcgroups

2023-05-06 Thread Jan Hoffmann
entirely, as the original commit message doesn't offer a convincing reason why this would be necessary in the first place. Fixes: 724e4af530cd ("realtek: Store and Restore MC memberships for port enable/disable") Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx/d

[PATCH v2 6/6] realtek: remove redundant is_lagmember checks

2023-05-06 Thread Jan Hoffmann
is a valid multicast group entry index. Fixes: cde31976e375 ("realtek: Add support for Layer 2 Multicast") Signed-off-by: Jan Hoffmann --- .../files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 15 ++- .../files-5.15/drivers/net/dsa/rtl83xx/dsa.c | 15 ++- 2 files

[PATCH v2 0/6] realtek: fix management of mdb entries

2023-05-06 Thread Jan Hoffmann
/openwrt-devel/2023-March/040621.html [2] https://lore.kernel.org/netdev/20230306134636.p2ufzoqk6kf3hu3y@skbuf/ Jan Hoffmann (6): realtek: fix writing/deletion of CAM entries realtek: don't treat first multicast portmask entry as reserved realtek: actually remove port from multicast portmask

[PATCH v2 3/6] realtek: actually remove port from multicast portmask

2023-05-06 Thread Jan Hoffmann
Fixes: 724e4af530cd ("realtek: Store and Restore MC memberships for port enable/disable") Signed-off-by: Jan Hoffmann --- target/linux/realtek/files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 1 + target/linux/realtek/files-5.15/drivers/net/dsa/rtl83xx/dsa.c | 1 + 2 files changed, 2

[PATCH v2 1/6] realtek: fix writing/deletion of CAM entries

2023-05-06 Thread Jan Hoffmann
Actually use the index returned by rtl83xx_find_l2_cam_entry. Fixes: cde31976e375 ("realtek: Add support for Layer 2 Multicast") Signed-off-by: Jan Hoffmann --- .../realtek/files-5.10/drivers/net/dsa/rtl83xx/dsa.c | 8 .../realtek/files-5.15/drivers/net/dsa/rtl83xx/dsa.

[OpenWrt-Devel] [PATCH] ramips: add factory image for WNDR3700v5

2019-05-15 Thread Jan Hoffmann via openwrt-devel
ting rules for Sercomm factory images and moves them to the ramips image Makefile, so they can be used in all subtargets. The new factory image for WNDR3700v5 can be flashed using nmrpflash. Signed-off-by: Jan Hoffmann --- target/linux/ramips/image/Makefile | 14 ++ target/linux/ra

[no subject]

2020-06-26 Thread Jan Hoffmann via openwrt-devel
--- Begin Message --- The hardware appears to be identical to R6260/R6350/R6850. The factory image has been confirmed to work with nmrpflash. Signed-off-by: Jan Hoffmann --- .../ramips/dts/mt7621_netgear_wac124.dts | 25 +++ target/linux/ramips/image/mt7621.mk