diff mbox series

[ovs-dev,RFC,3/5] northd: Synchronize the MAC binding age threshold

Message ID 20230615140513.289357-4-amusil@redhat.com
State Superseded
Headers show
Series Add MAC binding aging timestamp refresh mechanism | expand

Checks

Context Check Description
ovsrobot/apply-robot success apply and check: success
ovsrobot/github-robot-_Build_and_Test success github build: passed
ovsrobot/github-robot-_ovn-kubernetes fail github build: failed

Commit Message

Ales Musil June 15, 2023, 2:05 p.m. UTC
Synchrinoize the MAC binding age threashold to
SB datapath.

This is a preparation for the MAC binding refresh mechanism.

Signed-off-by: Ales Musil <amusil@redhat.com>
---
 northd/northd.c | 7 +++++++
 1 file changed, 7 insertions(+)
diff mbox series

Patch

diff --git a/northd/northd.c b/northd/northd.c
index 9d2562e84..f97741936 100644
--- a/northd/northd.c
+++ b/northd/northd.c
@@ -1150,6 +1150,13 @@  ovn_datapath_update_external_ids(struct ovn_datapath *od)
         if (!learn_from_arp_request) {
             smap_add(&ids, "always_learn_from_arp_request", "false");
         }
+
+        uint32_t age_threshold = smap_get_uint(&od->nbr->options,
+                                               "mac_binding_age_threshold", 0);
+        if (age_threshold) {
+            smap_add_format(&ids, "mac_binding_age_threshold",
+                            "%u", age_threshold);
+        }
     }
 
     sbrec_datapath_binding_set_external_ids(od->sb, &ids);