{"id":2192594,"url":"http://patchwork.ozlabs.org/api/1.2/patches/2192594/?format=json","web_url":"http://patchwork.ozlabs.org/project/ovn/patch/20260203202354.228161-1-lucas.vdias@luizalabs.com/","project":{"id":68,"url":"http://patchwork.ozlabs.org/api/1.2/projects/68/?format=json","name":"Open Virtual Network development","link_name":"ovn","list_id":"ovs-dev.openvswitch.org","list_email":"ovs-dev@openvswitch.org","web_url":"http://openvswitch.org/","scm_url":"","webscm_url":"","list_archive_url":"","list_archive_url_format":"","commit_url_format":""},"msgid":"<20260203202354.228161-1-lucas.vdias@luizalabs.com>","list_archive_url":null,"date":"2026-02-03T20:23:54","name":"[ovs-dev,v2] northd, ic: Add hub-spoke options to adv DR routes learned in ovn-ic.","commit_ref":null,"pull_url":null,"state":"changes-requested","archived":false,"hash":"491f2d9d574eae45d6687d7948ea0d4adea55529","submitter":{"id":90169,"url":"http://patchwork.ozlabs.org/api/1.2/people/90169/?format=json","name":"Lucas Vargas Dias","email":"lucas.vdias@luizalabs.com"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/ovn/patch/20260203202354.228161-1-lucas.vdias@luizalabs.com/mbox/","series":[{"id":490879,"url":"http://patchwork.ozlabs.org/api/1.2/series/490879/?format=json","web_url":"http://patchwork.ozlabs.org/project/ovn/list/?series=490879","date":"2026-02-03T20:23:54","name":"[ovs-dev,v2] northd, ic: Add hub-spoke options to adv DR routes learned in ovn-ic.","version":2,"mbox":"http://patchwork.ozlabs.org/series/490879/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/patches/2192594/comments/","check":"success","checks":"http://patchwork.ozlabs.org/api/patches/2192594/checks/","tags":{},"related":[],"headers":{"Return-Path":"<ovs-dev-bounces@openvswitch.org>","X-Original-To":["incoming@patchwork.ozlabs.org","dev@openvswitch.org"],"Delivered-To":["patchwork-incoming@legolas.ozlabs.org","ovs-dev@lists.linuxfoundation.org"],"Authentication-Results":["legolas.ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n unprotected) header.d=luizalabs.com header.i=@luizalabs.com\n header.a=rsa-sha256 header.s=google header.b=nly+CRQK;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org\n (client-ip=2605:bc80:3010::138; helo=smtp1.osuosl.org;\n envelope-from=ovs-dev-bounces@openvswitch.org; receiver=patchwork.ozlabs.org)","smtp1.osuosl.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key,\n unprotected) header.d=luizalabs.com header.i=@luizalabs.com\n header.a=rsa-sha256 header.s=google header.b=nly+CRQK","smtp3.osuosl.org; dmarc=pass (p=quarantine dis=none)\n header.from=luizalabs.com","smtp3.osuosl.org; dkim=pass (1024-bit key,\n unprotected) header.d=luizalabs.com header.i=@luizalabs.com\n header.a=rsa-sha256 header.s=google header.b=nly+CRQK"],"Received":["from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4f5FLv13hsz1xpg\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 04 Feb 2026 07:24:07 +1100 (AEDT)","from localhost (localhost [127.0.0.1])\n\tby smtp1.osuosl.org (Postfix) with ESMTP id 2D63783E1B;\n\tTue,  3 Feb 2026 20:24:05 +0000 (UTC)","from smtp1.osuosl.org ([127.0.0.1])\n by localhost (smtp1.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP\n id mhsDoICwKhMM; Tue,  3 Feb 2026 20:24:03 +0000 (UTC)","from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56])\n\tby smtp1.osuosl.org (Postfix) with ESMTPS id 7462683E05;\n\tTue,  3 Feb 2026 20:24:03 +0000 (UTC)","from lf-lists.osuosl.org (localhost [127.0.0.1])\n\tby lists.linuxfoundation.org (Postfix) with ESMTP id 4E12AC04FB;\n\tTue,  3 Feb 2026 20:24:03 +0000 (UTC)","from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136])\n by lists.linuxfoundation.org (Postfix) with ESMTP id 94C09C04FA\n for <dev@openvswitch.org>; Tue,  3 Feb 2026 20:24:02 +0000 (UTC)","from localhost (localhost [127.0.0.1])\n by smtp3.osuosl.org (Postfix) with ESMTP id 82831606C6\n for <dev@openvswitch.org>; Tue,  3 Feb 2026 20:24:02 +0000 (UTC)","from smtp3.osuosl.org ([127.0.0.1])\n by localhost (smtp3.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP\n id 1hPtFG4jMSRT for <dev@openvswitch.org>;\n Tue,  3 Feb 2026 20:24:01 +0000 (UTC)","from mail-vk1-xa2b.google.com (mail-vk1-xa2b.google.com\n [IPv6:2607:f8b0:4864:20::a2b])\n by smtp3.osuosl.org (Postfix) with ESMTPS id 1CF1C605C6\n for <dev@openvswitch.org>; Tue,  3 Feb 2026 20:24:00 +0000 (UTC)","by mail-vk1-xa2b.google.com with SMTP id\n 71dfb90a1353d-5664634a27fso11682e0c.1\n for <dev@openvswitch.org>; Tue, 03 Feb 2026 12:24:00 -0800 (PST)","from WNEC-73GS814.. ([186.237.124.134])\n by smtp.gmail.com with ESMTPSA id\n a1e0cc1a2514c-948dffae497sm123987241.13.2026.02.03.12.23.58\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Tue, 03 Feb 2026 12:23:58 -0800 (PST)"],"X-Virus-Scanned":["amavis at osuosl.org","amavis at osuosl.org"],"X-Comment":"SPF check N/A for local connections - client-ip=140.211.9.56;\n helo=lists.linuxfoundation.org;\n envelope-from=ovs-dev-bounces@openvswitch.org; receiver=<UNKNOWN> ","DKIM-Filter":["OpenDKIM Filter v2.11.0 smtp1.osuosl.org 7462683E05","OpenDKIM Filter v2.11.0 smtp3.osuosl.org 1CF1C605C6"],"Received-SPF":"Pass (mailfrom) identity=mailfrom;\n client-ip=2607:f8b0:4864:20::a2b; helo=mail-vk1-xa2b.google.com;\n envelope-from=lucas.vdias@luizalabs.com; receiver=<UNKNOWN>","DMARC-Filter":"OpenDMARC Filter v1.4.2 smtp3.osuosl.org 1CF1C605C6","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=luizalabs.com; s=google; t=1770150239; x=1770755039; darn=openvswitch.org;\n h=content-transfer-encoding:mime-version:message-id:date:subject:cc\n :to:from:from:to:cc:subject:date:message-id:reply-to;\n bh=eZLMvW/8jmuzCPUvTTsyhS7jRPKM9FTk6kWy4wULMgY=;\n b=nly+CRQKMowZGK44txEAvysSA8bgqTbaf4aPyEayC7kFXVUJ1ztdX7EtD5T/vjj6Vk\n JFkuTOuMcP13trPyX+TvFBfKk2AXXyYDGgkVUALxruWLufOZf4TwmL21zZ+TFSM7b+GS\n oPgTNrw1PuqsUlwg2IGf5IrZM2wOCCd4j6NDM=","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20230601; t=1770150239; x=1770755039;\n h=content-transfer-encoding:mime-version:message-id:date:subject:cc\n :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date\n :message-id:reply-to;\n bh=eZLMvW/8jmuzCPUvTTsyhS7jRPKM9FTk6kWy4wULMgY=;\n b=manGkxtuGZQMB5m9xsf0IGLCu5t04wu4MOZhFUDpfuajJ1xLaHeUvSkyEMmzCLQgdQ\n gWd/uj0vDS1fSj2ghCDCP40r1yCrQh+WCw/kOndpVqzz3SfVD4XhPOfANybu8fTqG+/p\n fHOH/7Vs0SSeMIBCCAIasdCGD4DeyrRhWYvqY9wN+sB5s9f2Npx/vkquo5wSGwBYB2G1\n QqJaHmEl2KukqH5x990wfVewZMY75wYOziU/FHPv3++llw9o59hacgyo+3Cwc9+gZseY\n 3FNd+cbXbbRwx9jEgZ51kWlqHHY9naR0oimHogZnqsxTZ+MN3w9J5ADtuTRoaKmHilZv\n vlBQ==","X-Gm-Message-State":"AOJu0YyFYqLZ+m2aFLItn0wxgtupkeWqgtRVyDsgvgOW56GMN+IQqArJ\n BhXWi5m02cfgR63BO80wwV/KBEwtrcWicrmY8qag30yUnPooEf6ga1k7tt4U//Q+wqUIZyxHpt3\n lKxZcADoCVK6TP81VFriVlHYcgKVd584XYq27OuFInCic4Pzh4GvZ47O7XGiF","X-Gm-Gg":"AZuq6aIinXSO7iOiFnWD0Xd/iYF82BS6X3o1C47xMLDrch7cVZ3GAbV44CBi2G+DuOw\n ZsTuxQpKFB+eBIr+lD2ci4fij+O2s+Z4RdNIAOFwnqMqiAC6IpGBH8LBKHITewGE3SGDJ3iy8tK\n QfSWSWPmggnTgU6AIQSANx2oKdDjzRESradK371F6hBu2SIICb7QQeM5RrA9Zol6GAbRfQSnOz9\n NleZ+WNtsFEI6LM5aPS6CR2lUCd09TlOT1VAGE3B9Y16z65SYMVA8iNHEU0hFvoCH2j1NfbvPOS\n UgjvWy5iVRBAp4GJkLLayA3OBzhZPhy9V1jcgzKTGFJEFo6yrtas2ylcZyNpsah91k+MS1YFUTt\n +WHWXfTXBgNkF09/NiXIET54mw+EBFlOeo5DiNPyCHstlhFQtPGajRvRJ1kswsJXLr7CK+Xi30O\n Xc8Tmm+uPBuc4wK8CF5zwMDPY=","X-Received":"by 2002:a05:6122:322c:b0:54c:da0:f711 with SMTP id\n 71dfb90a1353d-566e7ffb2e5mr309471e0c.7.1770150239138;\n Tue, 03 Feb 2026 12:23:59 -0800 (PST)","To":"dev@openvswitch.org","Date":"Tue,  3 Feb 2026 17:23:54 -0300","Message-ID":"<20260203202354.228161-1-lucas.vdias@luizalabs.com>","X-Mailer":"git-send-email 2.43.0","MIME-Version":"1.0","Subject":"[ovs-dev] [PATCH ovn v2] northd,\n ic: Add hub-spoke options to adv DR routes learned in ovn-ic.","X-BeenThere":"ovs-dev@openvswitch.org","X-Mailman-Version":"2.1.30","Precedence":"list","List-Id":"<ovs-dev.openvswitch.org>","List-Unsubscribe":"<https://mail.openvswitch.org/mailman/options/ovs-dev>,\n <mailto:ovs-dev-request@openvswitch.org?subject=unsubscribe>","List-Archive":"<http://mail.openvswitch.org/pipermail/ovs-dev/>","List-Post":"<mailto:ovs-dev@openvswitch.org>","List-Help":"<mailto:ovs-dev-request@openvswitch.org?subject=help>","List-Subscribe":"<https://mail.openvswitch.org/mailman/listinfo/ovs-dev>,\n <mailto:ovs-dev-request@openvswitch.org?subject=subscribe>","From":"Lucas Vargas Dias via dev <ovs-dev@openvswitch.org>","Reply-To":"Lucas Vargas Dias <lucas.vdias@luizalabs.com>","Content-Type":"text/plain; charset=\"iso-8859-1\"","Content-Transfer-Encoding":"quoted-printable","Errors-To":"ovs-dev-bounces@openvswitch.org","Sender":"\"dev\" <ovs-dev-bounces@openvswitch.org>"},"content":"Consider the scenario where there are 2 AZs using ovn-ic, each AZ has\none LR and its LS. The LRs are interconnected by a transit switch.\nOn each AZ, we can configure the dynamic routing and exchange routes\nvia BGP with external BGP speakers.\n\nAZ1\nLS1 - LR1 - BGP Speaker1 - Local subnet1\n       \\\n   -----------------------\n    transit switch\n   -----------------------\nAZ2    /\nLS2 - LR2 - BGP Speaker2 - Local subnet2\n\nThe LR2 will learn the subnet1 prefix via ovn-ic but this prefix will\nnot be redistributed to BGP Speaker2 and it also happens with LR1.\nThis scenario uses the network's hub-and-spoke terminology where we can\nenable the hub-spoke on the LR for such redistribution.\nsubnet1 and subnet2 are configured as ic-source-dynamic=true in ovn-ic.\nAlso, consider the same scenario, but LR1 and LR2 learn the same subnet\nfor redundancy, hub-spoke option is disabled to not adv the subnet learned\nfrom BGP and advertised in ovn-ic in BGP speakers.\n\nSigned-off-by: Lucas Vargas Dias <lucas.vdias@luizalabs.com>\n---\n NEWS                              |  6 ++\n ic/ovn-ic.c                       | 28 +++++++---\n northd/en-advertised-route-sync.c |  3 +\n northd/northd.c                   | 10 +++-\n northd/northd.h                   |  5 +-\n northd/ovn-northd.c               |  1 -\n ovn-nb.xml                        | 21 +++++++\n tests/ovn-ic.at                   | 92 +++++++++++++++++++++++++++++++\n 8 files changed, 156 insertions(+), 10 deletions(-)","diff":"diff --git a/NEWS b/NEWS\nindex 2a2b5e12d..6002820f3 100644\n--- a/NEWS\n+++ b/NEWS\n@@ -40,6 +40,8 @@ Post v25.09.0\n      * Add the \"options:dynamic-routing-no-learning\" to Logical Routers ports.\n        If set to true, router port will not learn routes and will forget\n        learned routes. This option has priority over its router counterpart.\n+     * Add support for hub-and-spoke propagation via the \"hub-spoke\" option\n+       in dynamic-routing-redistribute settings.\n    - Add support for Network Function insertion in OVN with stateful traffic\n      redirection capability in Logical Switch datapath. The feature introduces\n      three new NB database tables:\n@@ -98,6 +100,10 @@ Post v25.09.0\n      reserving an unused IP from the backend's subnet. This change allows\n      using LRP IPs directly, eliminating the need to reserve additional IPs\n      per backend port.\n+   - Add the external_ids:ic-source-dynamic key for\n+     Logical_Router_Static_Route to indicate whether a learned OVN-IC route\n+     originated from dynamic routing sources in the advertising availability\n+     zone.\n \n OVN v25.09.0 - xxx xx xxxx\n --------------------------\ndiff --git a/ic/ovn-ic.c b/ic/ovn-ic.c\nindex fd5ecefb3..e9fff2d4d 100644\n--- a/ic/ovn-ic.c\n+++ b/ic/ovn-ic.c\n@@ -1283,6 +1283,7 @@ struct ic_route_info {\n     struct in6_addr prefix;\n     unsigned int plen;\n     struct in6_addr nexthop;\n+    bool is_src_dynamic;\n     const char *origin;\n     const char *route_table;\n     const char *route_tag;\n@@ -1554,7 +1555,7 @@ add_to_routes_ad(struct hmap *routes_ad, const struct in6_addr prefix,\n                  const struct nbrec_logical_router_static_route *nb_route,\n                  const struct nbrec_logical_router *nb_lr,\n                  const struct nbrec_load_balancer *nb_lb,\n-                 const char *route_tag)\n+                 const char *route_tag, bool is_src_dynamic)\n {\n     ovs_assert(nb_route || nb_lrp || nb_lb || nb_lr);\n \n@@ -1573,6 +1574,7 @@ add_to_routes_ad(struct hmap *routes_ad, const struct in6_addr prefix,\n         ic_route->nb_route = nb_route;\n         ic_route->origin = origin;\n         ic_route->route_table = route_table;\n+        ic_route->is_src_dynamic = is_src_dynamic;\n         ic_route->nb_lrp = nb_lrp;\n         ic_route->nb_lr = nb_lr;\n         ic_route->nb_lb = nb_lb;\n@@ -1649,7 +1651,7 @@ add_static_to_routes_ad(\n \n     add_to_routes_ad(routes_ad, prefix, plen, nexthop, ROUTE_ORIGIN_STATIC,\n                      nb_route->route_table, NULL, nb_route, nb_lr,\n-                     NULL, route_tag);\n+                     NULL, route_tag, false);\n }\n \n static void\n@@ -1659,7 +1661,8 @@ add_network_to_routes_ad(struct hmap *routes_ad, const char *network,\n                          const struct smap *nb_options,\n                          const struct nbrec_logical_router *nb_lr,\n                          const char *route_tag,\n-                         const struct nbrec_logical_router_port *ts_lrp)\n+                         const struct nbrec_logical_router_port *ts_lrp,\n+                         bool is_src_dynamic)\n {\n     struct in6_addr prefix, nexthop;\n     unsigned int plen;\n@@ -1711,7 +1714,8 @@ add_network_to_routes_ad(struct hmap *routes_ad, const char *network,\n \n     /* directly-connected routes go to <main> route table */\n     add_to_routes_ad(routes_ad, prefix, plen, nexthop, ROUTE_ORIGIN_CONNECTED,\n-                     NULL, nb_lrp, NULL, nb_lr, NULL, route_tag);\n+                     NULL, nb_lrp, NULL, nb_lr, NULL, route_tag,\n+                     is_src_dynamic);\n }\n \n static void\n@@ -1769,7 +1773,7 @@ add_lb_vip_to_routes_ad(struct hmap *routes_ad, const char *vip_key,\n \n     /* Lb vip routes go to <main> route table */\n     add_to_routes_ad(routes_ad, vip_ip, plen, nexthop, ROUTE_ORIGIN_LB,\n-                     NULL, NULL, NULL, nb_lr, nb_lb, route_tag);\n+                     NULL, NULL, NULL, nb_lr, nb_lb, route_tag, false);\n out:\n     free(vip_str);\n }\n@@ -2187,6 +2191,12 @@ sync_learned_routes(struct ic_context *ctx,\n                 nbrec_logical_router_static_route_update_options_setkey(\n                     nb_route, \"origin\", isb_route->origin);\n                 free(uuid_s);\n+                bool is_src_dynamic = smap_get_bool(&isb_route->external_ids,\n+                    \"ic-source-dynamic\", false);\n+                char *ic_source_dynamic_str = is_src_dynamic ?\n+                    \"true\" : \"false\";\n+                nbrec_logical_router_static_route_update_external_ids_setkey(\n+                    nb_route, \"ic-source-dynamic\", ic_source_dynamic_str);\n                 nbrec_logical_router_update_static_routes_addvalue(ic_lr->lr,\n                     nb_route);\n             }\n@@ -2243,6 +2253,10 @@ ad_route_sync_external_ids(const struct ic_route_info *route_adv,\n                                                      \"ic-route-tag\");\n         }\n     }\n+\n+    char *ic_src_dynamic_str = route_adv->is_src_dynamic ? \"true\" : \"false\";\n+    icsbrec_route_update_external_ids_setkey(isb_route, \"ic-source-dynamic\",\n+                                             ic_src_dynamic_str);\n }\n \n /* Sync routes from routes_ad to IC-SB. */\n@@ -2372,7 +2386,7 @@ build_ts_routes_to_adv(struct ic_context *ctx,\n                 add_network_to_routes_ad(routes_ad, lrp->networks[j], lrp,\n                                          ts_port_addrs,\n                                          &nb_global->options,\n-                                         lr, route_tag, ts_lrp);\n+                                         lr, route_tag, ts_lrp, false);\n             }\n         } else {\n             /* The router port of the TS port is ignored. */\n@@ -2427,7 +2441,7 @@ build_ts_routes_to_adv(struct ic_context *ctx,\n         add_network_to_routes_ad(routes_ad, sb_route->ip_prefix, NULL,\n                                  ts_port_addrs,\n                                  &nb_global->options,\n-                                 lr, route_tag, ts_lrp);\n+                                 lr, route_tag, ts_lrp, true);\n     }\n     sbrec_learned_route_index_destroy_row(filter);\n }\ndiff --git a/northd/en-advertised-route-sync.c b/northd/en-advertised-route-sync.c\nindex be771391d..be046769f 100644\n--- a/northd/en-advertised-route-sync.c\n+++ b/northd/en-advertised-route-sync.c\n@@ -675,6 +675,8 @@ should_advertise_route(const struct uuidset *host_route_lrps,\n         return drr_mode_NAT_is_set(drr);\n     case ROUTE_SOURCE_LB:\n         return drr_mode_LB_is_set(drr);\n+    case ROUTE_SOURCE_IC_DYNAMIC:\n+        return drr_mode_IC_DYNAMIC_is_set(drr);\n     case ROUTE_SOURCE_LEARNED:\n         OVS_NOT_REACHED();\n     default:\n@@ -745,6 +747,7 @@ advertise_route_track_od(struct advertised_route_sync_data *data,\n                            &tracked_op->od->nbr->header_.uuid);\n         }\n         break;\n+    case ROUTE_SOURCE_IC_DYNAMIC:\n     case ROUTE_SOURCE_CONNECTED:\n     case ROUTE_SOURCE_STATIC:\n         break;\ndiff --git a/northd/northd.c b/northd/northd.c\nindex b4bb4ba6d..fbb75533c 100644\n--- a/northd/northd.c\n+++ b/northd/northd.c\n@@ -870,6 +870,10 @@ parse_dynamic_routing_redistribute(\n             out |= DRRM_LB;\n             continue;\n         }\n+        if (!strcmp(token, \"hub-spoke\")) {\n+            out |= DRRM_IC_DYNAMIC;\n+            continue;\n+        }\n         static struct vlog_rate_limit rl = VLOG_RATE_LIMIT_INIT(5, 1);\n         VLOG_WARN_RL(&rl,\n                      \"unknown dynamic-routing-redistribute option '%s' on %s\",\n@@ -12034,7 +12038,10 @@ parsed_routes_add_static(const struct ovn_datapath *od,\n     enum route_source source;\n     if (!strcmp(smap_get_def(&route->options, \"origin\", \"\"),\n                 ROUTE_ORIGIN_CONNECTED)) {\n-        source = ROUTE_SOURCE_CONNECTED;\n+        bool ic_src_dynamic = smap_get_bool(&route->external_ids,\n+                                            \"ic-source-dynamic\", false);\n+        source = ic_src_dynamic ?\n+                 ROUTE_SOURCE_IC_DYNAMIC : ROUTE_SOURCE_CONNECTED;\n     } else {\n         source = ROUTE_SOURCE_STATIC;\n     }\n@@ -12129,6 +12136,7 @@ route_source_to_offset(enum route_source source)\n {\n     switch (source) {\n     case ROUTE_SOURCE_CONNECTED:\n+    case ROUTE_SOURCE_IC_DYNAMIC:\n         return ROUTE_PRIO_OFFSET_CONNECTED;\n     case ROUTE_SOURCE_STATIC:\n         return ROUTE_PRIO_OFFSET_STATIC;\ndiff --git a/northd/northd.h b/northd/northd.h\nindex eb5c15f34..e6ed2cc3e 100644\n--- a/northd/northd.h\n+++ b/northd/northd.h\n@@ -372,7 +372,8 @@ struct mcast_port_info {\n     DRR_MODE(CONNECTED_AS_HOST, 1) \\\n     DRR_MODE(STATIC,            2) \\\n     DRR_MODE(NAT,               3) \\\n-    DRR_MODE(LB,                4)\n+    DRR_MODE(LB,                4) \\\n+    DRR_MODE(IC_DYNAMIC,        5)\n \n enum dynamic_routing_redistribute_mode_bits {\n #define DRR_MODE(PROTOCOL, BIT) DRRM_##PROTOCOL##_BIT = BIT,\n@@ -826,6 +827,8 @@ enum route_source {\n     ROUTE_SOURCE_NAT,\n     /* The route is derived from a LB's VIP. */\n     ROUTE_SOURCE_LB,\n+    /* The route is derived from an ovn-controller and advertised to IC. */\n+    ROUTE_SOURCE_IC_DYNAMIC,\n };\n \n struct parsed_route {\ndiff --git a/northd/ovn-northd.c b/northd/ovn-northd.c\nindex 7d7568c6f..bc3969053 100644\n--- a/northd/ovn-northd.c\n+++ b/northd/ovn-northd.c\n@@ -905,7 +905,6 @@ main(int argc, char *argv[])\n         &nbrec_load_balancer_col_external_ids,\n         &nbrec_load_balancer_health_check_col_external_ids,\n         &nbrec_logical_router_policy_col_external_ids,\n-        &nbrec_logical_router_static_route_col_external_ids,\n         &nbrec_meter_col_external_ids,\n         &nbrec_meter_band_col_external_ids,\n         &nbrec_mirror_col_external_ids,\ndiff --git a/ovn-nb.xml b/ovn-nb.xml\nindex 1acbf202b..5f9b47491 100644\n--- a/ovn-nb.xml\n+++ b/ovn-nb.xml\n@@ -3374,6 +3374,13 @@ or\n           Logical Switch.\n         </p>\n \n+        <p>\n+          If <code>hub-spoke</code> is in the list then northd will synchronize\n+          dynamic routes learned through OVN-IC from other routers into the\n+          <ref table=\"Advertised_Route\" db=\"OVN_Southbound\"/> table, enabling\n+          hub-and-spoke propagation.\n+        </p>\n+\n         <p>\n           This value can be overwritten on a per LRP basis using\n           <ref column=\"options\" key=\"dynamic-routing-redistribute\"\n@@ -4461,6 +4468,13 @@ or\n           via shared Logical Switch.\n         </p>\n \n+        <p>\n+          If <code>hub-spoke</code> is in the list then northd will synchronize\n+          dynamic routes learned through OVN-IC from other routers into the\n+          <ref table=\"Advertised_Route\" db=\"OVN_Southbound\"/> table, enabling\n+          hub-and-spoke propagation.\n+        </p>\n+\n         <p>\n           If not set the value from <ref column=\"options\"\n           key=\"dynamic-routing-redistribute\" table=\"Logical_Router\"/> on the\n@@ -4823,6 +4837,13 @@ or\n       database.\n     </column>\n \n+    <column name=\"external_ids\" key=\"ic-source-dynamic\">\n+      <code>ovn-ic</code> populates this key for routes learned from\n+      <ref db=\"OVN_IC_Southbound\"/>. The value is <code>true</code> if the\n+      learned route originated from dynamic sources (e.g. learned routes)\n+      in the advertising availability zone, otherwise <code>false</code>.\n+    </column>\n+\n     <group title=\"Common Columns\">\n       <column name=\"external_ids\">\n         See <em>External IDs</em> at the beginning of this document.\ndiff --git a/tests/ovn-ic.at b/tests/ovn-ic.at\nindex 370a755be..a62d02da0 100644\n--- a/tests/ovn-ic.at\n+++ b/tests/ovn-ic.at\n@@ -4586,3 +4586,95 @@ OVN_CLEANUP_IC([az1], [az2])\n \n AT_CLEANUP\n ])\n+\n+\n+OVN_FOR_EACH_NORTHD([\n+AT_SETUP([ovn-ic -- Check ovn-ic adv and learn from SB Learned Route - hub and spoke mode])\n+\n+ovn_init_ic_db\n+\n+for i in 1 2; do\n+    ovn_start az$i\n+    ovn_as az$i\n+\n+    # Enable route learning at AZ level\n+    check ovn-nbctl set nb_global . options:ic-route-learn=true\n+    # Enable route advertising at AZ level\n+    check ovn-nbctl set nb_global . options:ic-route-adv=true\n+done\n+\n+# Create new transit switches and LRs. Test topology is next:\n+#\n+#\n+# logical router (lr11) - transit switch (ts11) - logical router (lr12)\n+#\n+#\n+\n+# Create lr11, lr12 and ts11 and connect them\n+for i in 1 2; do\n+    ovn_as az$i\n+\n+    lr=lr1$i\n+    check ovn-nbctl lr-add $lr\n+\n+    ts=ts11\n+    check ovn-ic-nbctl --wait=sb --may-exist ts-add $ts\n+\n+    lrp=lrp-$lr-$ts\n+    lsp=lsp-$ts-$lr\n+    # Create LRP and connect to TS\n+    check ovn-nbctl lrp-add $lr $lrp aa:aa:aa:aa:a1:0$i 169.254.101.$i/24\n+    check ovn-nbctl lsp-add-router-port $ts $lsp $lrp\n+done\n+\n+# Create directly-connected route in lr12\n+check ovn_as az2 ovn-nbctl lrp-add lr12 lrp-lr12 aa:aa:aa:aa:bb:01 \"192.168.0.1/24\"\n+OVS_WAIT_FOR_OUTPUT([ovn_as az1 ovn-nbctl lr-route-list lr11 | grep 192.168 |\n+             grep learned | awk '{print $1, $2}' | sort ], [0], [dnl\n+192.168.0.0/24 169.254.101.2\n+])\n+\n+ovn_as az2\n+check ovn-nbctl --wait=sb set Logical_Router lr12 option:dynamic-routing=true \\\n+    option:dynamic-routing-redistribute=\"connected,static\"\n+check ovn_as az2 ovn-nbctl --wait=sb lrp-add lr12 lr12-dr1 00:00:00:00:ff:01 10.0.0.1/24\n+dr1=$(fetch_column port_binding _uuid logical_port=lr12-dr1)\n+datapath=$(fetch_column datapath_binding _uuid external_ids:name=lr12)\n+\n+check_uuid ovn-sbctl create Learned_Route \\\n+    datapath=$datapath                    \\\n+    logical_port=$dr1                     \\\n+    ip_prefix=192.168.1.0/24              \\\n+    nexthop=10.0.0.20\n+\n+# Check Learned_Route adv in ovn-ic\n+OVS_WAIT_FOR_OUTPUT([ovn_as az1 ovn-nbctl lr-route-list lr11 |\n+             grep learned | awk '{print $1, $2}' | sort ], [0], [dnl\n+10.0.0.0/24 169.254.101.2\n+192.168.0.0/24 169.254.101.2\n+192.168.1.0/24 169.254.101.2\n+])\n+\n+ovn_as az1\n+check ovn-nbctl --wait=sb set Logical_Router lr11 option:dynamic-routing=true \\\n+    option:dynamic-routing-redistribute=\"connected,static\"\n+# Advertise just 10.0.0.0/24 and 192.168.0.0/24 routes\n+check_row_count Advertised_Route 1 ip_prefix=192.168.0.0/24\n+check_row_count Advertised_Route 1 ip_prefix=10.0.0.0/24\n+check_row_count Advertised_Route 0 ip_prefix=192.168.1.0/24\n+\n+\n+ovn_as az1\n+check ovn-nbctl --wait=sb set Logical_Router lr11 \\\n+    option:dynamic-routing-redistribute=\"connected,static,hub-spoke\"\n+# Advertise just 10.0.0.0/24, 192.168.0.0/24 and 192.168.1.0/24 routes\n+# Route 192.168.1.0/24 is learned by DR from other logical routes (lr12)\n+# And lr12 Advertised it in ovn-ic. Hub-spoke option enable re-routing in lr11\n+check_row_count Advertised_Route 1 ip_prefix=192.168.0.0/24\n+check_row_count Advertised_Route 1 ip_prefix=10.0.0.0/24\n+check_row_count Advertised_Route 1 ip_prefix=192.168.1.0/24\n+\n+OVN_CLEANUP_IC([az1], [az2])\n+\n+AT_CLEANUP\n+])\n","prefixes":["ovs-dev","v2"]}