Skip to content

RFC kref improvements

Peter Zijlstra lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest7 patches 81 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/7kref: Add KREF_INIT()drivers/block/drbd/drbd_bitmap.c fs/fuse/fuse_i.h include/linux/kref.h +2 more+6 -80 replies
2/7kref: Add kref_read()drivers/block/drbd/drbd_req.c drivers/block/rbd.c drivers/block/virtio_blk.c +52 more+120 -11629 replies
3/7kref: Kill kref_sub()drivers/block/drbd/drbd_main.c drivers/block/drbd/drbd_req.c drivers/gpu/drm/ttm/ttm_bo.c +3 more+36 -1120 replies
4/7kref: Use kref_get_unless_zero() moresecurity/apparmor/include/apparmor.h security/apparmor/include/policy.h+2 -80 replies
5/7kref: Implement kref_put_lock()include/linux/kref.h net/sunrpc/svcauth.c+25 -112 replies
6/7kref: Avoid more abusedrivers/usb/mon/mon_main.c+1 -10 replies
7/7kref: Implement using refcount_tinclude/linux/kref.h include/linux/refcount.h+232 -1852 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [RFC][PATCH 0/7] kref improvements

This series unfscks kref and then implements it in terms of refcount_t.

x86_64-allyesconfig compile tested and boot tested with my regular config.

refcount_t is as per the previous thread, it BUGs on over-/underflow and saturates at UINT_MAX, such that if we ever overflow, we'll never free again.