xfrm: remove xfrm_state_get_afinfo conditional rcu locking
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest6 patches 1 replyIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/6 | xfrm: remove unused functionnet/ | +0 | 0 replies | |
| 2/6 | xfrm: avoid rcu sparse warningnet/ | +8 | 0 replies | |
| 3/6 | xfrm: remove xfrm_state_put_afinfoinclude/ net/ net/ | +16 | 0 replies | |
| 4/6 | xfrm: add and use xfrm_state_afinfo_get_rcuinclude/ net/ | +16 | 0 replies | |
| 5/6 | xfrm: state: simplify rcu_read_unlock handling in two spotsnet/ | +7 | 0 replies | |
| 6/6 | xfrm: remove xfrm_state_get_afinfoinclude/ net/ net/ | +62 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH ipsec-next 0/6] xfrm: remove xfrm_state_get_afinfo conditional rcu locking
xfrm_state_get_afinfo still uses a conditional locking scheme dating back to when this still used an rwlock:
If return value is NULL, no lock (rcu readlock) was taken, otherwise, rcu_read_unlock has to be called.
This series moves rcu read lock/unlock responsibility to the callers.
xfrm_state_put_afinfo is removed (it is equivalent to rcu_read_unlock so thats what will be used instead).
xfrm_state_get_afinfo is renamed to xfrm_state_afinfo_get_rcu() and is only a rcu dereference wrapper.
In one case, rcu read/unlock can be avoided as we're always called with rcu read lock held.