Lines Matching refs:rulei
60 struct mlxsw_sp_acl_rule_info *rulei, in mlxsw_sp_flower_parse_actions() argument
80 err = mlxsw_sp_acl_rulei_act_count(mlxsw_sp, rulei, extack); in mlxsw_sp_flower_parse_actions()
91 err = mlxsw_sp_acl_rulei_act_terminate(rulei); in mlxsw_sp_flower_parse_actions()
105 err = mlxsw_sp_acl_rulei_act_drop(rulei, ingress, in mlxsw_sp_flower_parse_actions()
117 rulei->egress_bind_blocker = 1; in mlxsw_sp_flower_parse_actions()
119 rulei->ingress_bind_blocker = 1; in mlxsw_sp_flower_parse_actions()
123 err = mlxsw_sp_acl_rulei_act_trap(rulei); in mlxsw_sp_flower_parse_actions()
141 err = mlxsw_sp_acl_rulei_act_jump(rulei, group_id); in mlxsw_sp_flower_parse_actions()
161 rulei->egress_bind_blocker = 1; in mlxsw_sp_flower_parse_actions()
166 err = mlxsw_sp_acl_rulei_act_ignore(mlxsw_sp, rulei, in mlxsw_sp_flower_parse_actions()
175 err = mlxsw_sp_acl_rulei_act_fid_set(mlxsw_sp, rulei, in mlxsw_sp_flower_parse_actions()
181 err = mlxsw_sp_acl_rulei_act_fwd(mlxsw_sp, rulei, in mlxsw_sp_flower_parse_actions()
195 err = mlxsw_sp_acl_rulei_act_mirror(mlxsw_sp, rulei, in mlxsw_sp_flower_parse_actions()
207 err = mlxsw_sp_acl_rulei_act_vlan(mlxsw_sp, rulei, in mlxsw_sp_flower_parse_actions()
215 err = mlxsw_sp_acl_rulei_act_priority(mlxsw_sp, rulei, in mlxsw_sp_flower_parse_actions()
229 err = mlxsw_sp_acl_rulei_act_mangle(mlxsw_sp, rulei, in mlxsw_sp_flower_parse_actions()
254 err = mlxsw_sp_acl_rulei_act_police(mlxsw_sp, rulei, in mlxsw_sp_flower_parse_actions()
268 err = mlxsw_sp_acl_rulei_act_sample(mlxsw_sp, rulei, in mlxsw_sp_flower_parse_actions()
286 if (rulei->ipv6_valid) { in mlxsw_sp_flower_parse_actions()
295 mlxsw_sp_flower_parse_meta_iif(struct mlxsw_sp_acl_rule_info *rulei, in mlxsw_sp_flower_parse_meta_iif() argument
329 mlxsw_sp_acl_rulei_keymask_u32(rulei, in mlxsw_sp_flower_parse_meta_iif()
337 static int mlxsw_sp_flower_parse_meta(struct mlxsw_sp_acl_rule_info *rulei, in mlxsw_sp_flower_parse_meta() argument
349 mlxsw_sp_acl_rulei_keymask_u32(rulei, MLXSW_AFK_ELEMENT_FDB_MISS, in mlxsw_sp_flower_parse_meta()
352 return mlxsw_sp_flower_parse_meta_iif(rulei, block, &match, in mlxsw_sp_flower_parse_meta()
356 static void mlxsw_sp_flower_parse_ipv4(struct mlxsw_sp_acl_rule_info *rulei, in mlxsw_sp_flower_parse_ipv4() argument
363 mlxsw_sp_acl_rulei_keymask_buf(rulei, MLXSW_AFK_ELEMENT_SRC_IP_0_31, in mlxsw_sp_flower_parse_ipv4()
366 mlxsw_sp_acl_rulei_keymask_buf(rulei, MLXSW_AFK_ELEMENT_DST_IP_0_31, in mlxsw_sp_flower_parse_ipv4()
371 static void mlxsw_sp_flower_parse_ipv6(struct mlxsw_sp_acl_rule_info *rulei, in mlxsw_sp_flower_parse_ipv6() argument
378 mlxsw_sp_acl_rulei_keymask_buf(rulei, MLXSW_AFK_ELEMENT_SRC_IP_96_127, in mlxsw_sp_flower_parse_ipv6()
381 mlxsw_sp_acl_rulei_keymask_buf(rulei, MLXSW_AFK_ELEMENT_SRC_IP_64_95, in mlxsw_sp_flower_parse_ipv6()
384 mlxsw_sp_acl_rulei_keymask_buf(rulei, MLXSW_AFK_ELEMENT_SRC_IP_32_63, in mlxsw_sp_flower_parse_ipv6()
387 mlxsw_sp_acl_rulei_keymask_buf(rulei, MLXSW_AFK_ELEMENT_SRC_IP_0_31, in mlxsw_sp_flower_parse_ipv6()
390 mlxsw_sp_acl_rulei_keymask_buf(rulei, MLXSW_AFK_ELEMENT_DST_IP_96_127, in mlxsw_sp_flower_parse_ipv6()
393 mlxsw_sp_acl_rulei_keymask_buf(rulei, MLXSW_AFK_ELEMENT_DST_IP_64_95, in mlxsw_sp_flower_parse_ipv6()
396 mlxsw_sp_acl_rulei_keymask_buf(rulei, MLXSW_AFK_ELEMENT_DST_IP_32_63, in mlxsw_sp_flower_parse_ipv6()
399 mlxsw_sp_acl_rulei_keymask_buf(rulei, MLXSW_AFK_ELEMENT_DST_IP_0_31, in mlxsw_sp_flower_parse_ipv6()
405 struct mlxsw_sp_acl_rule_info *rulei, in mlxsw_sp_flower_parse_ports() argument
422 mlxsw_sp_acl_rulei_keymask_u32(rulei, MLXSW_AFK_ELEMENT_DST_L4_PORT, in mlxsw_sp_flower_parse_ports()
425 mlxsw_sp_acl_rulei_keymask_u32(rulei, MLXSW_AFK_ELEMENT_SRC_L4_PORT, in mlxsw_sp_flower_parse_ports()
433 struct mlxsw_sp_acl_rule_info *rulei, in mlxsw_sp_flower_parse_ports_range() argument
464 rulei->src_port_range_reg_index = prr_index; in mlxsw_sp_flower_parse_ports_range()
465 rulei->src_port_range_reg_valid = true; in mlxsw_sp_flower_parse_ports_range()
482 rulei->dst_port_range_reg_index = prr_index; in mlxsw_sp_flower_parse_ports_range()
483 rulei->dst_port_range_reg_valid = true; in mlxsw_sp_flower_parse_ports_range()
487 mlxsw_sp_acl_rulei_keymask_u32(rulei, MLXSW_AFK_ELEMENT_L4_PORT_RANGE, in mlxsw_sp_flower_parse_ports_range()
494 struct mlxsw_sp_acl_rule_info *rulei, in mlxsw_sp_flower_parse_tcp() argument
518 mlxsw_sp_acl_rulei_keymask_u32(rulei, MLXSW_AFK_ELEMENT_TCP_FLAGS, in mlxsw_sp_flower_parse_tcp()
525 struct mlxsw_sp_acl_rule_info *rulei, in mlxsw_sp_flower_parse_ip() argument
543 mlxsw_sp_acl_rulei_keymask_u32(rulei, MLXSW_AFK_ELEMENT_IP_TTL_, in mlxsw_sp_flower_parse_ip()
546 mlxsw_sp_acl_rulei_keymask_u32(rulei, MLXSW_AFK_ELEMENT_IP_ECN, in mlxsw_sp_flower_parse_ip()
550 mlxsw_sp_acl_rulei_keymask_u32(rulei, MLXSW_AFK_ELEMENT_IP_DSCP, in mlxsw_sp_flower_parse_ip()
559 struct mlxsw_sp_acl_rule_info *rulei, in mlxsw_sp_flower_parse() argument
587 mlxsw_sp_acl_rulei_priority(rulei, f->common.prio); in mlxsw_sp_flower_parse()
589 err = mlxsw_sp_flower_parse_meta(rulei, f, block); in mlxsw_sp_flower_parse()
615 mlxsw_sp_acl_rulei_keymask_u32(rulei, in mlxsw_sp_flower_parse()
620 mlxsw_sp_acl_rulei_keymask_u32(rulei, in mlxsw_sp_flower_parse()
630 mlxsw_sp_acl_rulei_keymask_buf(rulei, in mlxsw_sp_flower_parse()
634 mlxsw_sp_acl_rulei_keymask_buf(rulei, in mlxsw_sp_flower_parse()
638 mlxsw_sp_acl_rulei_keymask_buf(rulei, in mlxsw_sp_flower_parse()
642 mlxsw_sp_acl_rulei_keymask_buf(rulei, in mlxsw_sp_flower_parse()
661 rulei->egress_bind_blocker = 1; in mlxsw_sp_flower_parse()
664 mlxsw_sp_acl_rulei_keymask_u32(rulei, in mlxsw_sp_flower_parse()
669 mlxsw_sp_acl_rulei_keymask_u32(rulei, in mlxsw_sp_flower_parse()
676 mlxsw_sp_flower_parse_ipv4(rulei, f); in mlxsw_sp_flower_parse()
679 mlxsw_sp_flower_parse_ipv6(rulei, f); in mlxsw_sp_flower_parse()
681 err = mlxsw_sp_flower_parse_ports(mlxsw_sp, rulei, f, ip_proto); in mlxsw_sp_flower_parse()
685 err = mlxsw_sp_flower_parse_ports_range(mlxsw_sp, rulei, f, ip_proto); in mlxsw_sp_flower_parse()
689 err = mlxsw_sp_flower_parse_tcp(mlxsw_sp, rulei, f, ip_proto); in mlxsw_sp_flower_parse()
693 err = mlxsw_sp_flower_parse_ip(mlxsw_sp, rulei, f, n_proto_key & n_proto_mask); in mlxsw_sp_flower_parse()
697 return mlxsw_sp_flower_parse_actions(mlxsw_sp, block, rulei, in mlxsw_sp_flower_parse()
734 struct mlxsw_sp_acl_rule_info *rulei; in mlxsw_sp_flower_replace() local
756 rulei = mlxsw_sp_acl_rule_rulei(rule); in mlxsw_sp_flower_replace()
757 err = mlxsw_sp_flower_parse(mlxsw_sp, block, rulei, f); in mlxsw_sp_flower_replace()
761 err = mlxsw_sp_acl_rulei_commit(rulei); in mlxsw_sp_flower_replace()
847 struct mlxsw_sp_acl_rule_info rulei; in mlxsw_sp_flower_tmplt_create() local
850 memset(&rulei, 0, sizeof(rulei)); in mlxsw_sp_flower_tmplt_create()
851 err = mlxsw_sp_flower_parse(mlxsw_sp, block, &rulei, f); in mlxsw_sp_flower_tmplt_create()
857 &rulei.values.elusage); in mlxsw_sp_flower_tmplt_create()