Commit fb579e6
rcu: Annotate struct kvfree_rcu_bulk_data with __counted_by()
Add the __counted_by compiler attribute to the flexible array member
records to improve access bounds-checking via CONFIG_UBSAN_BOUNDS and
CONFIG_FORTIFY_SOURCE.
Increment nr_records before adding a new pointer to the records array.
Signed-off-by: Thorsten Blum <thorsten.blum@toblux.com>
Reviewed-by: "Gustavo A. R. Silva" <gustavoars@kernel.org>
Reviewed-by: "Uladzislau Rezki (Sony)" <urezki@gmail.com>
Reviewed-by: Paul E. McKenney <paulmck@kernel.org>
Signed-off-by: Neeraj Upadhyay <neeraj.upadhyay@kernel.org>1 parent 9aed3b5 commit fb579e6
1 file changed
Lines changed: 3 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3227 | 3227 | | |
3228 | 3228 | | |
3229 | 3229 | | |
3230 | | - | |
| 3230 | + | |
3231 | 3231 | | |
3232 | 3232 | | |
3233 | 3233 | | |
| |||
3767 | 3767 | | |
3768 | 3768 | | |
3769 | 3769 | | |
3770 | | - | |
| 3770 | + | |
| 3771 | + | |
3771 | 3772 | | |
3772 | 3773 | | |
3773 | 3774 | | |
| |||
0 commit comments