diff options
author | Marc Kleine-Budde <mkl@pengutronix.de> | 2017-10-17 07:18:35 +0200 |
---|---|---|
committer | Marc Kleine-Budde <mkl@pengutronix.de> | 2017-10-19 13:05:53 +0200 |
commit | cae1d5b78fb4874086170ad07921bca59ea2e893 (patch) | |
tree | 81530dfc1b20ce28497e9a0187a0867c2f070c54 /mm/bootmem.c | |
parent | 62c04647c6f44fa3d5d0c077133da0aa1cbbc34c (diff) | |
download | linux-cae1d5b78fb4874086170ad07921bca59ea2e893.tar.bz2 |
can: af_can: do not access proto_tab directly use rcu_access_pointer instead
"proto_tab" is a RCU protected array, when directly accessing the array,
sparse throws these warnings:
CHECK /srv/work/frogger/socketcan/linux/net/can/af_can.c
net/can/af_can.c:115:14: error: incompatible types in comparison expression (different address spaces)
net/can/af_can.c:795:17: error: incompatible types in comparison expression (different address spaces)
net/can/af_can.c:816:9: error: incompatible types in comparison expression (different address spaces)
This patch fixes the problem by using rcu_access_pointer() and
annotating "proto_tab" array as __rcu.
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'mm/bootmem.c')
0 files changed, 0 insertions, 0 deletions