Linux kernel modifications for the Kernel Hacking exam
Find a file
Peter Zijlstra 8af26be062 perf/core: Fix arch_perf_get_page_size()
The (new) page-table walker in arch_perf_get_page_size() is broken in
various ways. Specifically while it is used in a lockless manner, it
doesn't depend on CONFIG_HAVE_FAST_GUP nor uses the proper _lockless
offset methods, nor is careful to only read each entry only once.

Also the hugetlb support is broken due to calling pte_page() without
first checking pte_special().

Rewrite the whole thing to be a proper lockless page-table walker and
employ the new pXX_leaf_size() pgtable functions to determine the
pagetable size without looking at the page-frames.

Fixes: 51b646b2d9 ("perf,mm: Handle non-page-table-aligned hugetlbfs")
Fixes: 8d97e71811 ("perf/core: Add PERF_SAMPLE_DATA_PAGE_SIZE")
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Tested-by: Kan Liang <kan.liang@linux.intel.com>
Link: https://lkml.kernel.org/r/20201126124207.GM3040@hirez.programming.kicks-ass.net
2020-12-03 10:14:51 +01:00
arch Merge remote-tracking branch 'origin/master' into perf/core 2020-11-26 13:16:55 +01:00
block blk-cgroup: fix a hd_struct leak in blkcg_fill_root_iostats 2020-11-14 11:17:34 -07:00
certs
crypto drivers-5.10-2020-10-12 2020-10-13 13:04:41 -07:00
Documentation Staging/IIO fixes for 5.10-rc5 2020-11-22 11:58:49 -08:00
drivers media fixes for v5.10-rc6 2020-11-25 10:35:44 -08:00
fs Four smb3 fixes for stable 2020-11-24 15:33:18 -08:00
include mm: Introduce pXX_leaf_size() 2020-12-03 10:14:50 +01:00
init bootconfig: Extend the magic check range to the preceding 3 bytes 2020-11-12 20:36:52 -05:00
ipc
kernel perf/core: Fix arch_perf_get_page_size() 2020-12-03 10:14:51 +01:00
lib lib/strncpy_from_user.c: Mask out bytes after NUL terminator. 2020-11-19 11:56:16 -08:00
LICENSES
mm mm/gup: Provide gup_get_pte() more generic 2020-12-03 10:14:50 +01:00
net Merge https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf 2020-11-19 12:26:10 -08:00
samples Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf 2020-11-06 17:49:34 -08:00
scripts Networking fixes for 5.10-rc4, including fixes from the bpf subtree. 2020-11-12 14:02:04 -08:00
security selinux/stable-5.10 PR 20201113 2020-11-14 12:04:02 -08:00
sound ASoC: Fixes for v5.11 2020-11-19 19:56:29 +01:00
tools seccomp fixes for v5.10-rc5 2020-11-21 10:24:05 -08:00
usr
virt kvm: x86/mmu: Support dirty logging for the TDP MMU 2020-10-23 03:42:13 -04:00
.clang-format RDMA 5.10 pull request 2020-10-17 11:18:18 -07:00
.cocciconfig
.get_maintainer.ignore
.gitattributes
.gitignore
.mailmap mailmap: fix entry for Dmitry Baryshkov/Eremin-Solenikov 2020-11-14 11:26:03 -08:00
COPYING
CREDITS Samsung changes for v5.10 2020-11-13 13:16:27 +01:00
Kbuild
Kconfig
MAINTAINERS iommu fixes for -rc5 2020-11-20 10:20:16 -08:00
Makefile Linux 5.10-rc5 2020-11-22 15:36:08 -08:00
README

Linux kernel
============

There are several guides for kernel developers and users. These guides can
be rendered in a number of formats, like HTML and PDF. Please read
Documentation/admin-guide/README.rst first.

In order to build the documentation, use ``make htmldocs`` or
``make pdfdocs``.  The formatted documentation can also be read online at:

    https://www.kernel.org/doc/html/latest/

There are various text files in the Documentation/ subdirectory,
several of them using the Restructured Text markup notation.

Please read the Documentation/process/changes.rst file, as it contains the
requirements for building and running the kernel, and information about
the problems which may result by upgrading your kernel.