Whamcloud - gitweb
LU-13783 libcfs: provide fallback kallsyms_lookup_name()
authorMr NeilBrown <neilb@suse.de>
Tue, 11 May 2021 06:41:37 +0000 (23:41 -0700)
committerLi Xi <lixi@ddn.com>
Tue, 18 May 2021 01:47:16 +0000 (01:47 +0000)
commitf291b83db91518740dd29a37aa6d1681b9d85adc
tree8d124b95c4c8ab1576557cdb89a6218f1c024015
parentefb8046702214a3ccb280c2d03aae342bc641009
LU-13783 libcfs: provide fallback kallsyms_lookup_name()

Since Linux 5.7, kallsyms_lookup_name() is no longer exported, so we
cannot rely on it.

So test for this, and when not available provide a fallback which just
returns NULL.

As this was the only way to access apply_workqueue_attrs() in recent
kernels, we need to cope with the absence of that function.

Lustre-change: https://review.whamcloud.com/40826
Lustre-commit: d7249d9d70ac0fcfa665ece78634b495bc9a22cd

Signed-off-by: Mr NeilBrown <neilb@suse.de>
Change-Id: I09cc00047ec163a9395c5acd415505a8586e4e99
Reviewed-by: James Simmons <jsimmons@infradead.org>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/43647
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
libcfs/autoconf/lustre-libcfs.m4
libcfs/include/libcfs/linux/linux-misc.h
libcfs/libcfs/linux/linux-prim.c