소스 검색

net: hsrprp: allow HSR to forward PRP frames

Per IEC62439, there is no limitation on PRP frames being sent on HSR port.
This change adds a check when detecting frame type to only mark frames
as PRP frames if they carry a PRP RCT and PRP is the protocol for the
active port. So now PRP frames being forwarded through an HSR port
should be detected as standard type frames and be forwarded
successfully. e.g. Sending a PRP tagged frame out an HSR port should
result in successful transmit, where resulting frame carries both HSR
and PRP tags.

Signed-off-by: Aaron Kramer <a-kramer@ti.com>
Aaron Kramer 6 년 전
부모
커밋
ac18dd612b
1개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 2 1
      net/hsr-prp/hsr_prp_forward.c

+ 2 - 1
net/hsr-prp/hsr_prp_forward.c

@@ -738,7 +738,8 @@ static int fill_frame_info(struct hsr_prp_frame_info *frame,
 		struct prp_rct *rct = skb_get_PRP_rct(skb);
 
 		if (rct &&
-		    prp_check_lsdu_size(skb, rct, frame->is_supervision)) {
+		    prp_check_lsdu_size(skb, rct, frame->is_supervision) &&
+					port->priv->prot_version == PRP_V1) {
 			frame->skb_hsr = NULL;
 			frame->skb_std = NULL;
 			frame->skb_prp = skb;