Skip to content

bonding: cleanup arp_interval related time math

Veaceslav Falico netdev 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2bonding: call slave_last_rx() only once per slavedrivers/net/bonding/bond_main.c+8 -70 replies
2/2bonding: add bond_time_in_interval() and use it for time comparisondrivers/net/bonding/bond_main.c+32 -530 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

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]>
 drivers/net/bonding/bond_main.c |   88 +++++++++++++++------------------------
 1 files changed, 34 insertions(+), 54 deletions(-)