Whamcloud - gitweb
LU-9679 osc: convert oe_refc to kref 01/37601/9
authorNeilBrown <neilb@suse.com>
Wed, 12 Dec 2018 06:49:53 +0000 (17:49 +1100)
committerOleg Drokin <green@whamcloud.com>
Tue, 14 Apr 2020 08:09:08 +0000 (08:09 +0000)
commit9c2fb0b29cec8a02c0c080da7596c2c99921d47d
treee5f1b87dc9a3a71b57f5a41309effbf6ce114d11
parent8a05b7277ac029e765d2198682e2f000c14b95fc
LU-9679 osc: convert oe_refc to kref

oe_refc is used like a kref, so make it one.

As cl_object_put() needs an 'env', we cannot quite use
kref_put() as intended.  Maybe that can be fixed one day.

This requires kref_read() to be provided for older kernels.

The original Linux-commit also converted oe_users to a refcount_t
but that was later reverted.

Linux-Commit: 35ea2a7c694b ("lustre: osc: convert oe_refc and oe_users
to kref and refcount_")

Signed-off-by: Mr NeilBrown <neilb@suse.com>
Change-Id: I42fd17c4261b85b273387936b97fce463273e2b8
Reviewed-on: https://review.whamcloud.com/37601
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
Reviewed-by: Shaun Tancheff <shaun.tancheff@hpe.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
libcfs/autoconf/lustre-libcfs.m4
libcfs/include/libcfs/linux/linux-misc.h
lustre/include/lustre_osc.h
lustre/osc/osc_cache.c