Re: [PATCH 1/1] net/ipv4: Enable flow-based ECMP
From: Richard Laing <hidden>
Date: 2015-08-04 22:07:51
Hi Stephen, Given that fib_nhs is currently an int I would rather keep live_nexthops also as an int to match, probably fib_nhs could at least be set as unsigned or changed to u16 or even u8 perhaps. Best Regards, Richard On 08/04/2015 05:31 PM, Stephen Hemminger wrote:
On Tue, 4 Aug 2015 13:28:47 +1200 Richard Laing [off-list ref] wrote:quoted
diff --git a/include/net/ip_fib.h b/include/net/ip_fib.h index 5fa643b..7db9f72 100644 --- a/include/net/ip_fib.h +++ b/include/net/ip_fib.h@@ -117,6 +117,8 @@ struct fib_info { #ifdef CONFIG_IP_ROUTE_MULTIPATH int fib_power; #endif + /* Cache the number of live nexthops for flow based ECMP calculation. */ + int live_nexthops;unsigned or u16 ? rather than risking sign issues.
-- *Richard Laing* Software Team Leader* Allied Telesis Labs*| 27 Nazareth Ave | Christchurch 8024 | New Zealand Phone: +64 3 3393000 | DDI: +64 3 339 9248 | Web: *alliedtelesis.com <http://alliedtelesis.com/>*<skype:andrewriddell3?chat> http://productselector.alliedtelesis.eu/ <http://productselector.alliedtelesis.eu/>