From 7a7413265c027b9f4ea0a502050e45cd87918b69 Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Fri, 15 Feb 2019 11:57:22 -0500 Subject: [PATCH] zebra: Reorder `struct route_entry` to reduce size Reduce the size of the data structure from 88 bytes to 80 bytes Signed-off-by: Donald Sharp --- zebra/rib.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/zebra/rib.h b/zebra/rib.h index 8a59cea6d0..141152b04f 100644 --- a/zebra/rib.h +++ b/zebra/rib.h @@ -99,9 +99,6 @@ struct route_entry { /* Type fo this route. */ int type; - /* Source protocol instance */ - unsigned short instance; - /* VRF identifier. */ vrf_id_t vrf_id; @@ -115,9 +112,6 @@ struct route_entry { uint32_t mtu; uint32_t nexthop_mtu; - /* Distance. */ - uint8_t distance; - /* Flags of this route. * This flag's definition is in lib/zebra.h ZEBRA_FLAG_* and is exposed * to clients via Zserv @@ -146,6 +140,12 @@ struct route_entry { /* Sequence value incremented for each dataplane operation */ uint32_t dplane_sequence; + + /* Source protocol instance */ + uint16_t instance; + + /* Distance. */ + uint8_t distance; }; /* meta-queue structure: -- 2.39.5