]> git.puffer.fish Git - matthieu/frr.git/commit
ospfd: fix interface param type update
authorChirag Shah <chirag@nvidia.com>
Fri, 26 May 2023 20:43:50 +0000 (13:43 -0700)
committerChirag Shah <chirag@nvidia.com>
Thu, 1 Jun 2023 17:39:21 +0000 (10:39 -0700)
commit0d005b2d5c294d9d0a8db9d8beca83b97e0fd8ff
treefff1907e2793d169639933dc3a9241df68e9edf2
parent3f1b34c49820773b25b46091f7f05be88e0763f0
ospfd: fix interface param type update

interface link update event needs
to be handle properly in ospf interface
cache.

Example:
When vrf (interface) is created its default type
would be set to BROADCAST because ifp->status
is not set to VRF.
Subsequent link event sets ifp->status to vrf,
ospf interface update need to compare current type
to new default type which would be VRF (OSPF_IFTYPE_LOOPBACK).
Since ospf type param was created in first add event,
ifp vrf link event didn't update ospf type param which
leads to treat vrf as non loopback interface.

Ticket:#3459451
Testing Done:

Running config suppose to bypass rendering default
network broadcast for loopback/vrf types.

Before fix:

vrf vrf1
 vni 4001
exit-vrf
!
interface vrf1
 ip ospf network broadcast
exit

After fix: (interface vrf1 is not displayed).

vrf vrf1
 vni 4001
exit-vrf

Signed-off-by: Chirag Shah <chirag@nvidia.com>
ospfd/ospf_interface.c