Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

tipc: initialise addr_trail_end when setting node addresses

We set the field 'addr_trial_end' to 'jiffies', instead of the current
value 0, at the moment the node address is initialized. This guarantees
we don't inadvertently enter an address trial period when the node
address is explicitly set by the user.

Signed-off-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
Acked-by: Jon Maloy <jon.maloy@ericsson.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Chris Packham and committed by
David S. Miller
8874ecae 58799865

+1
+1
net/tipc/addr.c
··· 75 75 tipc_set_node_id(net, node_id); 76 76 } 77 77 tn->trial_addr = addr; 78 + tn->addr_trial_end = jiffies; 78 79 pr_info("32-bit node address hash set to %x\n", addr); 79 80 } 80 81