Kconfig (d754ed2821fd9675d203cb73c4afcd593e28b7d0) Kconfig (67f2df3b82d091ed095d0e47e1f3a9d3e18e4e41)
1# SPDX-License-Identifier: GPL-2.0-only
2
3menu "Memory Management options"
4
5#
6# For some reason microblaze and nios2 hard code SWAP=n. Hopefully we can
7# add proper SWAP support to them, in which case this can be remove.
8#

--- 259 unchanged lines hidden (view full) ---

268 bool "Harden slab freelist metadata"
269 depends on !SLUB_TINY
270 help
271 Many kernel heap attacks try to target slab cache metadata and
272 other infrastructure. This options makes minor performance
273 sacrifices to harden the kernel slab allocator against common
274 freelist exploit methods.
275
1# SPDX-License-Identifier: GPL-2.0-only
2
3menu "Memory Management options"
4
5#
6# For some reason microblaze and nios2 hard code SWAP=n. Hopefully we can
7# add proper SWAP support to them, in which case this can be remove.
8#

--- 259 unchanged lines hidden (view full) ---

268 bool "Harden slab freelist metadata"
269 depends on !SLUB_TINY
270 help
271 Many kernel heap attacks try to target slab cache metadata and
272 other infrastructure. This options makes minor performance
273 sacrifices to harden the kernel slab allocator against common
274 freelist exploit methods.
275
276config SLAB_BUCKETS
277 bool "Support allocation from separate kmalloc buckets"
278 depends on !SLUB_TINY
279 default SLAB_FREELIST_HARDENED
280 help
281 Kernel heap attacks frequently depend on being able to create
282 specifically-sized allocations with user-controlled contents
283 that will be allocated into the same kmalloc bucket as a
284 target object. To avoid sharing these allocation buckets,
285 provide an explicitly separated set of buckets to be used for
286 user-controlled allocations. This may very slightly increase
287 memory fragmentation, though in practice it's only a handful
288 of extra pages since the bulk of user-controlled allocations
289 are relatively long-lived.
290
291 If unsure, say Y.
292
276config SLUB_STATS
277 default n
278 bool "Enable performance statistics"
279 depends on SYSFS && !SLUB_TINY
280 help
281 The statistics are useful to debug slab allocation behavior in
282 order find ways to optimize the allocator. This should never be
283 enabled for production use since keeping statistics slows down

--- 971 unchanged lines hidden ---
293config SLUB_STATS
294 default n
295 bool "Enable performance statistics"
296 depends on SYSFS && !SLUB_TINY
297 help
298 The statistics are useful to debug slab allocation behavior in
299 order find ways to optimize the allocator. This should never be
300 enabled for production use since keeping statistics slows down

--- 971 unchanged lines hidden ---