Whamcloud - gitweb
LU-6142 lustre: use list_first_entry() in lustre subdirectory. 38/44338/2
authorMr. NeilBrown <neilb@suse.de>
Sun, 18 Jul 2021 12:57:33 +0000 (08:57 -0400)
committerOleg Drokin <green@whamcloud.com>
Tue, 10 Aug 2021 08:06:22 +0000 (08:06 +0000)
commit8c166f6bf42c1bc70b017c89d802f24ed6184988
treef28cd08612e275f9710b306c7da66e660eda6391
parent163870abfb7c3fe37ba1481dd7f84ed34be1d0a7
LU-6142 lustre: use list_first_entry() in lustre subdirectory.

Convert
  list_entry(foo->next .....)
to
  list_first_entry(foo, ....)

in 'lustre'

In several cases the call is combined with
a list_empty() test and list_first_entry_or_null() is used

Signed-off-by: Mr. NeilBrown <neilb@suse.de>
Change-Id: I27b8b55cac2cfeaf95bb66930958c49ad422156e
Reviewed-on: https://review.whamcloud.com/44338
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Arshad Hussain <arshad.hussain@aeoncomputing.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
14 files changed:
lustre/include/cl_object.h
lustre/llite/statahead.c
lustre/lov/lov_io.c
lustre/obdclass/genops.c
lustre/obdclass/lustre_peer.c
lustre/osc/osc_cache.c
lustre/osc/osc_lock.c
lustre/osc/osc_page.c
lustre/osc/osc_request.c
lustre/ptlrpc/client.c
lustre/ptlrpc/nrs_fifo.c
lustre/ptlrpc/pack_generic.c
lustre/ptlrpc/sec_gc.c
lustre/ptlrpc/service.c