diff options
author | David S. Miller <davem@davemloft.net> | 2015-04-06 21:52:19 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-04-06 22:34:15 -0400 |
commit | c85d6975ef923cffdd56de3e0e6aba0977282cff (patch) | |
tree | cb497deea01827951809c9c7c0f1c22780c146be /lib | |
parent | 60302ff631f0f3eac0ec592e128b776f0676b397 (diff) | |
parent | f22e6e847115abc3a0e2ad7bb18d243d42275af1 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Conflicts:
drivers/net/ethernet/mellanox/mlx4/cmd.c
net/core/fib_rules.c
net/ipv4/fib_frontend.c
The fib_rules.c and fib_frontend.c conflicts were locking adjustments
in 'net' overlapping addition and removal of code in 'net-next'.
The mlx4 conflict was a bug fix in 'net' happening in the same
place a constant was being replaced with a more suitable macro.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/lcm.c | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -12,3 +12,14 @@ unsigned long lcm(unsigned long a, unsigned long b) | |||
12 | return 0; | 12 | return 0; |
13 | } | 13 | } |
14 | EXPORT_SYMBOL_GPL(lcm); | 14 | EXPORT_SYMBOL_GPL(lcm); |
15 | |||
16 | unsigned long lcm_not_zero(unsigned long a, unsigned long b) | ||
17 | { | ||
18 | unsigned long l = lcm(a, b); | ||
19 | |||
20 | if (l) | ||
21 | return l; | ||
22 | |||
23 | return (b ? : a); | ||
24 | } | ||
25 | EXPORT_SYMBOL_GPL(lcm_not_zero); | ||