Coverage Report

Created: 2025-10-08 06:07

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/frr/zebra/zebra_evpn_vxlan.h
Line
Count
Source
1
// SPDX-License-Identifier: GPL-2.0-or-later
2
/*
3
 * Zebra EVPN for VxLAN code
4
 * Copyright (C) 2016, 2017 Cumulus Networks, Inc.
5
 */
6
7
/* Get the VRR interface for SVI if any */
8
static inline struct interface *
9
zebra_get_vrr_intf_for_svi(struct interface *ifp)
10
0
{
11
0
  struct zebra_vrf *zvrf = NULL;
12
0
  struct interface *tmp_if = NULL;
13
0
  struct zebra_if *zif = NULL;
14
15
0
  zvrf = ifp->vrf->info;
16
0
  assert(zvrf);
17
18
0
  FOR_ALL_INTERFACES (zvrf->vrf, tmp_if) {
19
0
    zif = tmp_if->info;
20
0
    if (!zif)
21
0
      continue;
22
23
0
    if (!IS_ZEBRA_IF_MACVLAN(tmp_if))
24
0
      continue;
25
26
0
    if (zif->link == ifp)
27
0
      return tmp_if;
28
0
  }
29
30
0
  return NULL;
31
0
}
Unexecuted instantiation: zebra_l2_bridge_if.c:zebra_get_vrr_intf_for_svi
Unexecuted instantiation: zebra_evpn.c:zebra_get_vrr_intf_for_svi
Unexecuted instantiation: zebra_vxlan.c:zebra_get_vrr_intf_for_svi
Unexecuted instantiation: zebra_vxlan_if.c:zebra_get_vrr_intf_for_svi
32
33
/* EVPN<=>vxlan_zif association */
34
static inline void zevpn_vxlan_if_set(struct zebra_evpn *zevpn,
35
              struct interface *ifp, bool set)
36
0
{
37
0
  struct zebra_if *zif;
38
39
0
  if (set) {
40
0
    if (zevpn->vxlan_if == ifp)
41
0
      return;
42
0
    zevpn->vxlan_if = ifp;
43
0
  } else {
44
0
    if (!zevpn->vxlan_if)
45
0
      return;
46
0
    zevpn->vxlan_if = NULL;
47
0
  }
48
49
0
  if (ifp)
50
0
    zif = ifp->info;
51
0
  else
52
0
    zif = NULL;
53
54
0
  zebra_evpn_vxl_evpn_set(zif, zevpn, set);
55
0
}
Unexecuted instantiation: zebra_l2_bridge_if.c:zevpn_vxlan_if_set
Unexecuted instantiation: zebra_evpn.c:zevpn_vxlan_if_set
Unexecuted instantiation: zebra_vxlan.c:zevpn_vxlan_if_set
Unexecuted instantiation: zebra_vxlan_if.c:zevpn_vxlan_if_set
56
57
/* EVPN<=>Bridge interface association */
58
static inline void zevpn_bridge_if_set(struct zebra_evpn *zevpn,
59
               struct interface *ifp, bool set)
60
0
{
61
0
  if (set) {
62
0
    if (zevpn->bridge_if == ifp)
63
0
      return;
64
0
    zevpn->bridge_if = ifp;
65
0
  } else {
66
0
    if (!zevpn->bridge_if)
67
0
      return;
68
0
    zevpn->bridge_if = NULL;
69
0
  }
70
0
}
Unexecuted instantiation: zebra_l2_bridge_if.c:zevpn_bridge_if_set
Unexecuted instantiation: zebra_evpn.c:zevpn_bridge_if_set
Unexecuted instantiation: zebra_vxlan.c:zevpn_bridge_if_set
Unexecuted instantiation: zebra_vxlan_if.c:zevpn_bridge_if_set
71
72
/* EVPN<=>Bridge interface association */
73
static inline void zl3vni_bridge_if_set(struct zebra_l3vni *zl3vni,
74
          struct interface *ifp, bool set)
75
0
{
76
0
  if (set) {
77
0
    if (zl3vni->bridge_if == ifp)
78
0
      return;
79
0
    zl3vni->bridge_if = ifp;
80
0
  } else {
81
0
    if (!zl3vni->bridge_if)
82
0
      return;
83
0
    zl3vni->bridge_if = NULL;
84
0
  }
85
0
}
Unexecuted instantiation: zebra_l2_bridge_if.c:zl3vni_bridge_if_set
Unexecuted instantiation: zebra_evpn.c:zl3vni_bridge_if_set
Unexecuted instantiation: zebra_vxlan.c:zl3vni_bridge_if_set
Unexecuted instantiation: zebra_vxlan_if.c:zl3vni_bridge_if_set