summaryrefslogtreecommitdiffstats
path: root/kernel/crash_core.c
diff options
context:
space:
mode:
authorOmar Sandoval <osandov@fb.com>2018-08-21 21:55:13 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2018-08-22 10:52:46 -0700
commitbf991c2231117d50a7645792b514354fc8d19dae (patch)
treec7c74e6d467774e97be1a0022b26c1047a7465b8 /kernel/crash_core.c
parent37e949bd5293ddb70acf236eedf2ae8caa1db57b (diff)
downloadlinux-bf991c2231117d50a7645792b514354fc8d19dae.tar.bz2
proc/kcore: optimize multiple page reads
The current code does a full search of the segment list every time for every page. This is wasteful, since it's almost certain that the next page will be in the same segment. Instead, check if the previous segment covers the current page before doing the list search. Link: http://lkml.kernel.org/r/fd346c11090cf93d867e01b8d73a6567c5ac6361.1531953780.git.osandov@fb.com Signed-off-by: Omar Sandoval <osandov@fb.com> Cc: Alexey Dobriyan <adobriyan@gmail.com> Cc: Bhupesh Sharma <bhsharma@redhat.com> Cc: Eric Biederman <ebiederm@xmission.com> Cc: James Morse <james.morse@arm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel/crash_core.c')
0 files changed, 0 insertions, 0 deletions