summaryrefslogtreecommitdiffstats
path: root/kernel/kexec_internal.h
diff options
context:
space:
mode:
authorJohannes Thumshirn <jthumshirn@suse.de>2019-03-07 17:14:00 +0100
committerDavid Sterba <dsterba@suse.com>2019-04-29 19:02:19 +0200
commit443c8e2a839f18084cfdb5b0b62d90b8159f48ae (patch)
tree96eec479c95b9e5c93cda5d65b6c8d4b21051ca9 /kernel/kexec_internal.h
parenta1d198478e92cc8f05c26be746edd1c58f756c0f (diff)
downloadlinux-stable-443c8e2a839f18084cfdb5b0b62d90b8159f48ae.tar.gz
linux-stable-443c8e2a839f18084cfdb5b0b62d90b8159f48ae.tar.bz2
linux-stable-443c8e2a839f18084cfdb5b0b62d90b8159f48ae.zip
btrfs: reduce kmap_atomic time for checksumming
Since commit c40a3d38aff4 ("Btrfs: Compute and look up csums based on sectorsized blocks") we do a kmap_atomic() on the contents of a bvec. The code before c40a3d38aff4 had the kmap region just around the checksumming too. kmap_atomic() in turn does a preempt_disable() and pagefault_disable(), so we shouldn't map the data for too long. Reduce the time the bvec's page is mapped to when we actually need it. Performance wise it doesn't seem to make a huge difference with a 2 vcpu VM on a /dev/zram device: vanilla patched delta write 17.4MiB/s 17.8MiB/s +0.4MiB/s (+2%) read 40.6MiB/s 41.5MiB/s +0.9MiB/s (+2%) The following fio job profile was used in the comparision: [global] ioengine=libaio direct=1 sync=1 norandommap time_based runtime=10m size=100m group_reporting numjobs=2 [test] filename=/mnt/test/fio rw=randrw rwmixread=70 Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'kernel/kexec_internal.h')
0 files changed, 0 insertions, 0 deletions