Lines Matching refs:key_layer

175 			      u32 *key_layer_two, u8 *key_layer, int *key_size,  in nfp_flower_calc_udp_tun_layer()  argument
185 *key_layer |= NFP_FLOWER_LAYER_VXLAN; in nfp_flower_calc_udp_tun_layer()
188 *key_layer |= NFP_FLOWER_LAYER_EXT_META; in nfp_flower_calc_udp_tun_layer()
207 *key_layer |= NFP_FLOWER_LAYER_EXT_META; in nfp_flower_calc_udp_tun_layer()
249 u8 key_layer; in nfp_flower_calculate_key_layers() local
269 key_layer = NFP_FLOWER_LAYER_PORT; in nfp_flower_calculate_key_layers()
275 key_layer |= NFP_FLOWER_LAYER_MAC; in nfp_flower_calculate_key_layers()
290 key_layer |= NFP_FLOWER_LAYER_EXT_META; in nfp_flower_calculate_key_layers()
307 key_layer |= NFP_FLOWER_LAYER_EXT_META; in nfp_flower_calculate_key_layers()
373 key_layer |= NFP_FLOWER_LAYER_EXT_META; in nfp_flower_calculate_key_layers()
400 &key_layer, in nfp_flower_calculate_key_layers()
424 key_layer |= NFP_FLOWER_LAYER_IPV4; in nfp_flower_calculate_key_layers()
429 key_layer |= NFP_FLOWER_LAYER_IPV6; in nfp_flower_calculate_key_layers()
442 if (!(key_layer & NFP_FLOWER_LAYER_MAC)) { in nfp_flower_calculate_key_layers()
443 key_layer |= NFP_FLOWER_LAYER_MAC; in nfp_flower_calculate_key_layers()
468 key_layer |= NFP_FLOWER_LAYER_TP; in nfp_flower_calculate_key_layers()
474 if (!(key_layer & NFP_FLOWER_LAYER_TP) && in nfp_flower_calculate_key_layers()
510 if (!(key_layer & NFP_FLOWER_LAYER_IPV4) && in nfp_flower_calculate_key_layers()
511 !(key_layer & NFP_FLOWER_LAYER_IPV6)) { in nfp_flower_calculate_key_layers()
514 key_layer |= NFP_FLOWER_LAYER_IPV4; in nfp_flower_calculate_key_layers()
519 key_layer |= NFP_FLOWER_LAYER_IPV6; in nfp_flower_calculate_key_layers()
540 ret_key_ls->key_layer = key_layer; in nfp_flower_calculate_key_layers()
548 nfp_flower_allocate_new(struct nfp_fl_key_ls *key_layer) in nfp_flower_allocate_new() argument
556 flow_pay->meta.key_len = key_layer->key_size; in nfp_flower_allocate_new()
557 flow_pay->unmasked_data = kmalloc(key_layer->key_size, GFP_KERNEL); in nfp_flower_allocate_new()
561 flow_pay->meta.mask_len = key_layer->key_size; in nfp_flower_allocate_new()
562 flow_pay->mask_data = kmalloc(key_layer->key_size, GFP_KERNEL); in nfp_flower_allocate_new()
711 u8 key_layer, match_size; in nfp_flower_populate_merge_match() local
716 key_layer = meta_tci->nfp_flow_key_layer; in nfp_flower_populate_merge_match()
718 if (key_layer & ~NFP_FLOWER_MERGE_FIELDS && !extra_fields) in nfp_flower_populate_merge_match()
724 if (key_layer & NFP_FLOWER_LAYER_EXT_META) in nfp_flower_populate_merge_match()
729 if (key_layer & NFP_FLOWER_LAYER_MAC) { in nfp_flower_populate_merge_match()
735 if (key_layer & NFP_FLOWER_LAYER_TP) { in nfp_flower_populate_merge_match()
741 if (key_layer & NFP_FLOWER_LAYER_IPV4) { in nfp_flower_populate_merge_match()
746 if (key_layer & NFP_FLOWER_LAYER_IPV6) { in nfp_flower_populate_merge_match()
1140 u8 key_layer; in nfp_flower_validate_pre_tun_rule() local
1143 key_layer = key_ls->key_layer; in nfp_flower_validate_pre_tun_rule()
1156 if (key_layer & ~NFP_FLOWER_PRE_TUN_RULE_FIELDS) { in nfp_flower_validate_pre_tun_rule()
1164 if (!(key_layer & NFP_FLOWER_LAYER_MAC)) { in nfp_flower_validate_pre_tun_rule()
1169 if (!(key_layer & NFP_FLOWER_LAYER_IPV4) && in nfp_flower_validate_pre_tun_rule()
1170 !(key_layer & NFP_FLOWER_LAYER_IPV6)) { in nfp_flower_validate_pre_tun_rule()
1175 if (key_layer & NFP_FLOWER_LAYER_IPV6) in nfp_flower_validate_pre_tun_rule()
1229 if (key_layer & NFP_FLOWER_LAYER_IPV4 || in nfp_flower_validate_pre_tun_rule()
1230 key_layer & NFP_FLOWER_LAYER_IPV6) { in nfp_flower_validate_pre_tun_rule()
1237 size = key_layer & NFP_FLOWER_LAYER_IPV4 ? in nfp_flower_validate_pre_tun_rule()
1340 struct nfp_fl_key_ls *key_layer; in nfp_flower_add_offload() local
1357 key_layer = kmalloc(sizeof(*key_layer), GFP_KERNEL); in nfp_flower_add_offload()
1358 if (!key_layer) in nfp_flower_add_offload()
1361 err = nfp_flower_calculate_key_layers(app, netdev, key_layer, rule, in nfp_flower_add_offload()
1366 flow_pay = nfp_flower_allocate_new(key_layer); in nfp_flower_add_offload()
1372 err = nfp_flower_compile_flow_match(app, rule, key_layer, netdev, in nfp_flower_add_offload()
1382 err = nfp_flower_validate_pre_tun_rule(app, flow_pay, key_layer, extack); in nfp_flower_add_offload()
1432 kfree(key_layer); in nfp_flower_add_offload()
1450 kfree(key_layer); in nfp_flower_add_offload()