summaryrefslogtreecommitdiffstats
path: root/net/hsr/hsr_main.h
diff options
context:
space:
mode:
authorAndreas Oetken <ennoerlangen@gmail.com>2021-10-25 20:56:18 +0200
committerDavid S. Miller <davem@davemloft.net>2021-10-26 15:52:17 +0200
commiteafaa88b3eb7f28aecb222281655473431d3ef2e (patch)
tree9bfaf6a2a2d0aa0442a26ed911e466358ecb789b /net/hsr/hsr_main.h
parentMerge branch 'tcp_stream_alloc_skb' (diff)
downloadlinux-eafaa88b3eb7f28aecb222281655473431d3ef2e.tar.xz
linux-eafaa88b3eb7f28aecb222281655473431d3ef2e.zip
net: hsr: Add support for redbox supervision frames
added support for the redbox supervision frames as defined in the IEC-62439-3:2018. Signed-off-by: Andreas Oetken <andreas.oetken@siemens-energy.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/hsr/hsr_main.h')
-rw-r--r--net/hsr/hsr_main.h16
1 files changed, 11 insertions, 5 deletions
diff --git a/net/hsr/hsr_main.h b/net/hsr/hsr_main.h
index 53d1f7a82463..043e4e9a1694 100644
--- a/net/hsr/hsr_main.h
+++ b/net/hsr/hsr_main.h
@@ -35,13 +35,15 @@
* HSR_NODE_FORGET_TIME?
*/
#define PRUNE_PERIOD 3000 /* ms */
-
+#define HSR_TLV_EOT 0 /* End of TLVs */
#define HSR_TLV_ANNOUNCE 22
#define HSR_TLV_LIFE_CHECK 23
/* PRP V1 life check for Duplicate discard */
#define PRP_TLV_LIFE_CHECK_DD 20
/* PRP V1 life check for Duplicate Accept */
#define PRP_TLV_LIFE_CHECK_DA 21
+/* PRP V1 life redundancy box MAC address */
+#define PRP_TLV_REDBOX_MAC 30
/* HSR Tag.
* As defined in IEC-62439-3:2010, the HSR tag is really { ethertype = 0x88FB,
@@ -94,14 +96,18 @@ struct hsr_vlan_ethhdr {
struct hsr_tag hsr_tag;
} __packed;
+struct hsr_sup_tlv {
+ u8 HSR_TLV_type;
+ u8 HSR_TLV_length;
+};
+
/* HSR/PRP Supervision Frame data types.
* Field names as defined in the IEC:2010 standard for HSR.
*/
struct hsr_sup_tag {
- __be16 path_and_HSR_ver;
- __be16 sequence_nr;
- __u8 HSR_TLV_type;
- __u8 HSR_TLV_length;
+ __be16 path_and_HSR_ver;
+ __be16 sequence_nr;
+ struct hsr_sup_tlv tlv;
} __packed;
struct hsr_sup_payload {