aboutsummaryrefslogtreecommitdiff
path: root/lib/test_fortify/write_overflow-strlcpy-src.c
diff options
context:
space:
mode:
authorTianchen Ding <[email protected]>2022-03-22 14:48:10 -0700
committerLinus Torvalds <[email protected]>2022-03-22 15:57:11 -0700
commit698361bca2d59fd29d46c757163854454df477f1 (patch)
treec1e26247a7a199ae6730c8edd22bd72931e23ab4 /lib/test_fortify/write_overflow-strlcpy-src.c
parent56eb8e9416e85ca7db4550b58e93ac88d7993c13 (diff)
kfence: allow re-enabling KFENCE after system startup
Patch series "provide the flexibility to enable KFENCE", v3. If CONFIG_CONTIG_ALLOC is not supported, we fallback to try alloc_pages_exact(). Allocating pages in this way has limits about MAX_ORDER (default 11). So we will not support allocating kfence pool after system startup with a large KFENCE_NUM_OBJECTS. When handling failures in kfence_init_pool_late(), we pair free_pages_exact() to alloc_pages_exact() for compatibility consideration, though it actually does the same as free_contig_range(). This patch (of 2): If once KFENCE is disabled by: echo 0 > /sys/module/kfence/parameters/sample_interval KFENCE could never be re-enabled until next rebooting. Allow re-enabling it by writing a positive num to sample_interval. Link: https://lkml.kernel.org/r/[email protected] Link: https://lkml.kernel.org/r/[email protected] Signed-off-by: Tianchen Ding <[email protected]> Reviewed-by: Marco Elver <[email protected]> Cc: Alexander Potapenko <[email protected]> Cc: Dmitry Vyukov <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'lib/test_fortify/write_overflow-strlcpy-src.c')
0 files changed, 0 insertions, 0 deletions