Commit c090d975 authored by Alessandro Rubini's avatar Alessandro Rubini

pfilter: vlan: replicate the novlan rules for PTP over UDP

Signed-off-by: Alessandro Rubini's avatarAlessandro Rubini <rubini@gnudd.com>
parent b995f24b
......@@ -464,6 +464,16 @@ void pfilter_init_vlan(char *fname)
pfilter_cmp(1, 0xffff, 0xffff, AND, FRAME_BROADCAST);
pfilter_cmp(2, 0xffff, 0xffff, AND, FRAME_BROADCAST);
/* PTP UDP (end to end: 01:00:5e:00:01:81 224.0.1.129) */
pfilter_cmp(0, 0x0100, 0xffff, MOV, FRAME_MAC_PTP);
pfilter_cmp(1, 0x5e00, 0xffff, AND, FRAME_MAC_PTP);
pfilter_cmp(2, 0x0181, 0xffff, MOV, R_TMP);
/* PTP UDP (peer-to-p: 01:00:5e:00:00:6b 224.0.0.197) */
pfilter_cmp(2, 0x006b, 0xffff, OR, R_TMP);
pfilter_logic3(FRAME_MAC_OK, FRAME_MAC_PTP, AND, R_TMP, OR, FRAME_MAC_OK);
/* Untagged is dropped. */
pfilter_cmp(6, 0x8100, 0xffff, MOV, R_TMP);
pfilter_logic2(R_DROP, R_TMP, NOT, R_ZERO);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment