git: d4be9d601d35 - stable/13 - netlink: export nextop group kernel index when dumping multipath route.

From: Alexander V. Chernikov <melifaro_at_FreeBSD.org>
Date: Thu, 09 Feb 2023 16:49:05 UTC
The branch stable/13 has been updated by melifaro:

URL: https://cgit.FreeBSD.org/src/commit/?id=d4be9d601d356e0790334d1ae039cab5ecaf0a2c

commit d4be9d601d356e0790334d1ae039cab5ecaf0a2c
Author:     Alexander V. Chernikov <melifaro@FreeBSD.org>
AuthorDate: 2023-01-28 15:37:58 +0000
Commit:     Alexander V. Chernikov <melifaro@FreeBSD.org>
CommitDate: 2023-02-09 16:44:53 +0000

    netlink: export nextop group kernel index when dumping multipath route.
    
    MFC after:      2 weeks
    
    (cherry picked from commit 95b47ba6299401b487f29a05ac859629ee7d4f0b)
---
 sys/netlink/route/rt.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sys/netlink/route/rt.c b/sys/netlink/route/rt.c
index 07735cd9d5bc..9173f5cc58ea 100644
--- a/sys/netlink/route/rt.c
+++ b/sys/netlink/route/rt.c
@@ -175,6 +175,7 @@ dump_rc_nhg(struct nl_writer *nw, const struct nhgrp_object *nhg, struct rtmsg *
 
 	if (uidx != 0)
 		nlattr_add_u32(nw, NL_RTA_NH_ID, uidx);
+	nlattr_add_u32(nw, NL_RTA_KNH_ID, nhgrp_get_idx(nhg));
 
 	nlattr_add_u32(nw, NL_RTA_RTFLAGS, base_rtflags);
 	int off = nlattr_add_nested(nw, NL_RTA_MULTIPATH);