On 9/1/18 2:43 PM, Stephen Hemminger wrote: > On Fri, 31 Aug 2018 17:49:53 -0700 > dsah...@kernel.org wrote: > >> +static inline unsigned int fib_info_hashfn_cfg(const struct fib_config *cfg) >> +{ >> + unsigned int mask = (fib_info_hash_size - 1); >> + unsigned int val = 0; >> + >> + val ^= (cfg->fc_protocol << 8) | cfg->fc_scope; > > Why do assignment to 0 than do initial xor? > Why not instead just do assignment in the first statement which would be > clearer. >
Side effect of copy-paste-adjust of the original. Will fix for the next rfc (really need to not have 2 versions of the hashfn; need to think through it).