summaryrefslogtreecommitdiffstats
path: root/drivers/staging/lustre/include/linux/libcfs/libcfs.h
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.com>2018-05-07 10:54:48 +1000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-05-08 13:09:20 +0200
commit85b6542bbade42935386661cb45d90c4e13766b7 (patch)
tree89fdc35f730dc656d631e526c4f8ac4846b8afb0 /drivers/staging/lustre/include/linux/libcfs/libcfs.h
parentfc5f499af16c247c5bff68d2625a6d1ca48b3332 (diff)
downloadop-kernel-dev-85b6542bbade42935386661cb45d90c4e13766b7.zip
op-kernel-dev-85b6542bbade42935386661cb45d90c4e13766b7.tar.gz
staging: lustre: llite: remove redundant lookup in dump_pgcache
Both the 'next' and the 'show' functions for the dump_page_cache seqfile perform a lookup based on the current file index. This is needless duplication. The reason appears to be that the state that needs to be communicated from "next" to "show" is two pointers, but seq_file only provides for a single pointer to be returned from next and passed to show. So make use of the new 'seq_private' structure to store the extra pointer. So when 'next' (or 'start') find something, it returns the page and stores the clob in the private area. 'show' accepts the page as an argument, and finds the clob where it was stored. Signed-off-by: NeilBrown <neilb@suse.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/lustre/include/linux/libcfs/libcfs.h')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud