Re: [PATCH net v9 3/4] net: hsr: segment GSO before per-frame forwarding

From: Sebastian Andrzej Siewior

Date: Sun Nov 15 2026 - 16:41:29 EST


On 2026-11-12 16:33:32 [+0100], Xin Xie wrote:
> @@ -794,3 +797,158 @@ void hsr_forward_skb(struct sk_buff *skb, struct hsr_port *port)
…
> +void hsr_forward_input(struct sk_buff *skb, struct hsr_port *port)
> +{
…
> + consume_skb(skb);
> + while (segs) {
> + next = segs->next;
> + segs->next = NULL;
> + hsr_forward_frame(segs, port);
> + segs = next;
> + }

Should you repost:

diff --git a/net/hsr/hsr_forward.c b/net/hsr/hsr_forward.c
index 9aefc5f0249f6..5e49f2bb9e39b 100644
--- a/net/hsr/hsr_forward.c
+++ b/net/hsr/hsr_forward.c
@@ -940,11 +940,9 @@ void hsr_forward_input(struct sk_buff *skb, struct hsr_port *port)
goto drop;

consume_skb(skb);
- while (segs) {
- next = segs->next;
- segs->next = NULL;
+ skb_list_walk_safe(segs, segs, next) {
+ skb_mark_not_on_list(segs);
hsr_forward_frame(segs, port);
- segs = next;
}
return;


Sebastian