bonding: cleanup arp_interval related time math
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest2 patches 1 replyIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | bonding: call slave_last_rx() only once per slavedrivers/ | +8 | 0 replies | |
| 2/2 | bonding: add bond_time_in_interval() and use it for time comparisondrivers/ | +32 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH net-next 0/2] bonding: cleanup arp_interval related time math
Current implementation uses heavily time_in_range() with similar, lengthy, params. By moving it to a separate function we can simplify the code a lot.
First patch saves a possibly heavy slave_last_rx() function to a variable and uses the variable in the calculation.
Second patch introduces helper function bond_time_in_interval() to make the arp_interval math and uses it instead of lengthy time_in_range() calls.
Both of them don't change anything logically and in terms of speed and are purely cleanup patches.
CC Jay Vosburgh <[email protected]>
CC Andy Gospodarek <[email protected]>
Signed-off-by Veaceslav Falico <[email protected]>
drivers/net/bonding/bond_main.c | 88 +++++++++++++++------------------------ 1 files changed, 34 insertions(+), 54 deletions(-)