Whamcloud - gitweb
LU-12093 osc: don't check capability for every page 20/34920/3
authorLi Dongyang <dongyangli@ddn.com>
Thu, 21 Mar 2019 03:05:14 +0000 (14:05 +1100)
committerOleg Drokin <green@whamcloud.com>
Sat, 8 Jun 2019 02:36:58 +0000 (02:36 +0000)
commitc628bc742747e739dddf8ec0a24329da01e97c8a
treecfb37ec2387740271638b6e7425b90101323ca23
parentb5cbe49a16b68ad60a8e7293d1b5450e0f97a430
LU-12093 osc: don't check capability for every page

We check CFS_CAP_SYS_RESOURCE for every page during the io.
This is expensive on apparmor enabled systems, we can only
do that once for the entire io and use the result when
submitting the pages.

Don't init the oap_brw_flags during osc_page_init(), the flag
will be set in either osc_queue_async_io() or osc_page_submit().

Lustre-change: https://review.whamcloud.com/34478
Lustre-commit: c1cab789aaa25bbb4062208aeb2822fde3007cd4

Signed-off-by: Li Dongyang <dongyangli@ddn.com>
Change-Id: I0e664f43ce31c276b33476fdff11794185ab0a3b
Reviewed-by: Patrick Farrell <pfarrell@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Gu Zheng <gzheng@ddn.com>
Signed-off-by: Minh Diep <mdiep@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/34920
Tested-by: Jenkins
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/lustre_osc.h
lustre/osc/osc_cache.c
lustre/osc/osc_io.c
lustre/osc/osc_page.c