diff options
author | Russell King <rmk+kernel@armlinux.org.uk> | 2020-01-03 19:41:39 +0000 |
---|---|---|
committer | Russell King <rmk+kernel@armlinux.org.uk> | 2020-03-30 12:38:57 +0100 |
commit | 406e21b10db69e05bd909727fd8b6f4f4866e810 (patch) | |
tree | 9efe3c83aafe8a885f0afdfb2a910fabe4a5e5f5 /include | |
parent | 5ecdbb6b1f782f468214ef5bdb89d6ebe373ea44 (diff) |
net: linkmode: make linkmode_test_bit() take const pointer
linkmode_test_bit() does not modify the address; test_bit() is also
declared const volatile for the same reason. There's no need for
linkmode_test_bit() to be any different, and allows implementation of
helpers that take a const linkmode pointer.
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/linkmode.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/linkmode.h b/include/linux/linkmode.h index fe740031339d..8e5b352e44f2 100644 --- a/include/linux/linkmode.h +++ b/include/linux/linkmode.h @@ -71,7 +71,7 @@ static inline void linkmode_change_bit(int nr, volatile unsigned long *addr) __change_bit(nr, addr); } -static inline int linkmode_test_bit(int nr, volatile unsigned long *addr) +static inline int linkmode_test_bit(int nr, const volatile unsigned long *addr) { return test_bit(nr, addr); } |