Lines Matching refs:trap
317 static void ocelot_populate_l2_ptp_trap_key(struct ocelot_vcap_filter *trap)
319 trap->key_type = OCELOT_VCAP_KEY_ETYPE;
320 *(__be16 *)trap->key.etype.etype.value = htons(ETH_P_1588);
321 *(__be16 *)trap->key.etype.etype.mask = htons(0xffff);
325 ocelot_populate_ipv4_ptp_event_trap_key(struct ocelot_vcap_filter *trap)
327 trap->key_type = OCELOT_VCAP_KEY_IPV4;
328 trap->key.ipv4.proto.value[0] = IPPROTO_UDP;
329 trap->key.ipv4.proto.mask[0] = 0xff;
330 trap->key.ipv4.dport.value = PTP_EV_PORT;
331 trap->key.ipv4.dport.mask = 0xffff;
335 ocelot_populate_ipv6_ptp_event_trap_key(struct ocelot_vcap_filter *trap)
337 trap->key_type = OCELOT_VCAP_KEY_IPV6;
338 trap->key.ipv6.proto.value[0] = IPPROTO_UDP;
339 trap->key.ipv6.proto.mask[0] = 0xff;
340 trap->key.ipv6.dport.value = PTP_EV_PORT;
341 trap->key.ipv6.dport.mask = 0xffff;
345 ocelot_populate_ipv4_ptp_general_trap_key(struct ocelot_vcap_filter *trap)
347 trap->key_type = OCELOT_VCAP_KEY_IPV4;
348 trap->key.ipv4.proto.value[0] = IPPROTO_UDP;
349 trap->key.ipv4.proto.mask[0] = 0xff;
350 trap->key.ipv4.dport.value = PTP_GEN_PORT;
351 trap->key.ipv4.dport.mask = 0xffff;
355 ocelot_populate_ipv6_ptp_general_trap_key(struct ocelot_vcap_filter *trap)
357 trap->key_type = OCELOT_VCAP_KEY_IPV6;
358 trap->key.ipv6.proto.value[0] = IPPROTO_UDP;
359 trap->key.ipv6.proto.mask[0] = 0xff;
360 trap->key.ipv6.dport.value = PTP_GEN_PORT;
361 trap->key.ipv6.dport.mask = 0xffff;