rcu: introduce kfree_rcu V2
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest6 patches 25 repliesIn review
Changed from V1 from the cover letter
1) Implement kfree_rcu() in slab layer.
In V1, the offset from the container struct to the rcu member is calculated at compile time and stored in head->func instead of the function pointer. This disarrange rcu's algorithm a little, there is no bad side effect when we implement kfree_rcu() in slab layer.
2) kfree_rcu() API is changed, use the version that Manfred Spraul designed. This one allows compiler do more checking.
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/6 | slab: introduce __kfree_rcumm/ | +22 | 9 replies | |
| 2/6 | slob: introduce __kfree_rcumm/ | +51 | 0 replies | |
| 3/6 | slub: introduce __kfree_rcumm/ | +24 | 5 replies | |
| 4/6 | slqb: record slab's start address in slqb_pagemm/ | +2 | 1 reply | |
| 5/6 | slqb: introduce __kfree_rcumm/ | +17 | 2 replies | |
| 6/6 | rcu: introduce kfree_rcuinclude/ | +14 | 1 reply |
Reviews trailers per patch
1 of 6 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.
| Patch | Paul E. McKenney | Pekka Enberg |
|---|---|---|
| Series | R-b | |
| 1/6 | ||
| 2/6 | ||
| 3/6 | ||
| 4/6 | ||
| 5/6 | ||
| 6/6 | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH -mm 0/6] rcu: introduce kfree_rcu V2
There are 23 instances where the rcu callback just does
kfree(containerof(head,struct whatever_struct,rcu_member));
The 23 instances exist because there are 23 'struct whatever_struct' with their individual rcu_member. These patches creates a generic kfree_rcu() function that removes the need for these 23 helpers.
The number of this kind of rcu callback will increase, for this is the most common way to use rcu and define rcu callback.
And kfree_rcu() is also help for unloadable modules, kfree_rcu() does not queue any function which belong to the module, so a rcu_barrier() can be avoid when module exit. (If we queue any other function by call_rcu(), rcu_barrier() is still needed.)
Changed from V1:
1) Implement kfree_rcu() in slab layer.
In V1, the offset from the container struct to the rcu member is calculated at compile time and stored in head->func instead of the function pointer. This disarrange rcu's algorithm a little, there is no bad side effect when we implement kfree_rcu() in slab layer.
2) kfree_rcu() API is changed, use the version that Manfred Spraul designed. This one allows compiler do more checking.
---