Re: [PATCH net-next 2/2] net: hsr: Remove interlink_sequence_nr.

From
Lukasz Majewski <lukma@denx.de>
Date
2024-09-09 09:43:52
Reply to
Sebastian Andrzej Siewior, 2024-09-06
Hi Sebastian Andrzej,
quoted hunk ↗ jump to hunk
From: Eric Dumazet <redacted>

Remove interlink_sequence_nr which is unused.

[ bigeasy: split out from Eric's patch ].

Signed-off-by: Eric Dumazet <redacted>
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
---
 net/hsr/hsr_device.c | 1 -
 net/hsr/hsr_main.h   | 1 -
 2 files changed, 2 deletions(-)
diff --git a/net/hsr/hsr_device.c b/net/hsr/hsr_device.c
index a06e790042e2e..10393836992df 100644
--- a/net/hsr/hsr_device.c
+++ b/net/hsr/hsr_device.c
@@ -625,7 +625,6 @@ int hsr_dev_finalize(struct net_device *hsr_dev,
struct net_device *slave[2], /* Overflow soon to find bugs easier: */
 	hsr->sequence_nr = HSR_SEQNR_START;
 	hsr->sup_sequence_nr = HSR_SUP_SEQNR_START;
-	hsr->interlink_sequence_nr = HSR_SEQNR_START;
 
 	timer_setup(&hsr->announce_timer, hsr_announce, 0);
 	timer_setup(&hsr->prune_timer, hsr_prune_nodes, 0);
diff --git a/net/hsr/hsr_main.h b/net/hsr/hsr_main.h
index ab1f8d35d9dcf..fcfeb79bb0401 100644
--- a/net/hsr/hsr_main.h
+++ b/net/hsr/hsr_main.h
@@ -203,7 +203,6 @@ struct hsr_priv {
 	struct timer_list	prune_proxy_timer;
 	int announce_count;
 	u16 sequence_nr;
-	u16 interlink_sequence_nr; /* Interlink port seq_nr */
I think that this was an attempt to exactly follow standard (point
5.2.2.2 HSR-SAN RedBox for attachment to a single-thread LAN) which
states that proxy node table shall keep for each interlink the sequence
number [*]. Instead in code the sequence number for a new frame which
comes from interlink port is assigned int:

hsr_get_node() -> file line 271 

and then this starting sequence numer is used for this proxy node table
node.

Hence it shall be safe to remove it.
 	u16 sup_sequence_nr;	/* For HSRv1 separate seq_nr for
supervision */ enum hsr_version prot_version;	/* Indicate if
HSRv0, HSRv1 or PRPv1 */ spinlock_t seqnr_lock;	/* locking for
sequence_nr */



Best regards,

Lukasz Majewski

--

DENX Software Engineering GmbH,      Managing Director: Erika Unter
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-59 Fax: (+49)-8142-66989-80 Email: lukma@denx.de

Attachments

Thread (13 messages) 13 messages, 4 authors, last reply 2024-09-13
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help