Whamcloud - gitweb
LU-15220 llite: Compat for set_pagevec_dirty 27/45927/6
authorPatrick Farrell <pfarrell@whamcloud.com>
Thu, 6 Jan 2022 18:20:59 +0000 (10:20 -0800)
committerOleg Drokin <green@whamcloud.com>
Thu, 20 Jan 2022 06:39:55 +0000 (06:39 +0000)
commit8fdef1381ea07657d6689818b2897d69cb7e9c83
treeb9e6fd75ecc2868eef0c156d35649494c4625535
parentda7f2848a2aae2ec4852b23e55d23d42a30205ce
LU-15220 llite: Compat for set_pagevec_dirty

If we can't access account_page_dirtied either via export
or via kallsyms lookup, the benefit of vvp_set_pagevec_dirty
is mostly lost, since we have to take the xarray lock
repeatedly to handle accounting dirty pages.

Replace the more complicated compat code by just falling
back to __set_page_dirty_nobuffers in a loop, since this
has the same effect and is much simpler.

This also resolves 5.14 compatibility, as __set_page_dirty
is no longer exported there.

Signed-off-by: Patrick Farrell <pfarrell@whamcloud.com>
Change-Id: I3feb526b8eaaec3811c689a895875b409204a159
Reviewed-on: https://review.whamcloud.com/45927
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
Reviewed-by: Yingjin Qian <qian@ddn.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/lustre_compat.h
lustre/llite/vvp_dev.c
lustre/llite/vvp_io.c