Hey Kees,
thanks for the patch.
can you please send this patch to linux-scsi and CC the SCSI Maintainers
(Martin and James) instead (having linux-s390 on CC is fine)? zFCP doesn't go
via s390, being a SCSI driver.
On Thu, Nov 16, 2023 at 11:14:35AM -0800, Kees Cook wrote:
> strlcpy() reads the e
On 24.10.2023 08:37, Luka Panio wrote:
> Initial support for Xiaomi Pad 6 tablet, that have sm8250 soc.
>
> Signed-off-by: Luka Panio
> ---
[...]
> +
> + gpio_keys: gpio-keys {
> + compatible = "gpio-keys";
> +
> + pinctrl-names = "default";
> + pinctrl-0
On 21.10.2023 12:20, Xilin Wu via B4 Relay wrote:
> From: Xilin Wu
>
> Add support for Xiaomi Mi 11 Ultra. This commit brings support for:
> * Front and rear display panels (initialized by bootloader)
> * USB
> * UFS
> * PCIe0
> * Thermistor sensors
> * ADSP/CDSP/Modem/SLPI
> * IR Transmitter
> *
The SLAB implementation is going to be removed, and mm-api.rst currently
uses mm/slab.c to obtain kerneldocs for some API functions. Switch it to
mm/slub.c and move the relevant kerneldocs of exported functions from
one to the other. The rest of kerneldocs in slab.c is for static SLAB
implementatio
With SLAB removed and SLUB the only remaining allocator, we can clean up
some code that was depending on the choice.
Reviewed-by: Kees Cook
Reviewed-by: Marco Elver
Signed-off-by: Vlastimil Babka
---
mm/kasan/common.c | 13 ++---
mm/kasan/kasan.h | 3 +--
mm/kasan/quarantine.
With SLAB removed, these are never true anymore so we can clean up.
Reviewed-by: Kees Cook
Acked-by: Michal Hocko
Signed-off-by: Vlastimil Babka
---
mm/memcontrol.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/mm/memcontrol.c b/mm/memcontrol.c
index 774bd6e21e27..94
4026 -
mm/slab.h | 551 ++---
mm/slab_common.c | 231 +--
mm/slub.c | 617 +-
29 files changed, 815 insertions(+), 5134 deletions(-)
---
base-commit: b85ea95d086471afb4ad062012a4d73cd328fa86
change-id: 202
The CPUHP_SLAB_PREPARE hooks are only used by SLAB which is removed.
SLUB defines them as NULL, so we can remove those altogether.
Signed-off-by: Vlastimil Babka
---
include/linux/cpuhotplug.h | 1 -
include/linux/slab.h | 8
kernel/cpu.c | 5 -
3 files changed,
CONFIG_DEBUG_SLAB is going away with CONFIG_SLAB, so remove dead ifdefs
in mempool and dmapool code.
Reviewed-by: Kees Cook
Signed-off-by: Vlastimil Babka
---
mm/dmapool.c | 2 +-
mm/mempool.c | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/mm/dmapool.c b/mm/dmapool.c
Some struct slab fields are initialized differently for SLAB and SLUB so
we can simplify with SLUB being the only remaining allocator.
Reviewed-by: Kees Cook
Reviewed-by: Marco Elver
Signed-off-by: Vlastimil Babka
---
mm/kfence/core.c | 4
1 file changed, 4 deletions(-)
diff --git a/mm/k
Nothing outside SLUB itself accesses the struct kmem_cache_cpu fields so
it does not need to be declared in slub_def.h. This allows also to move
enum stat_item.
Reviewed-by: Kees Cook
Signed-off-by: Vlastimil Babka
---
include/linux/slub_def.h | 54 --
In slab_common.c and slab.h headers, we can now remove all code behind
CONFIG_SLAB and CONFIG_DEBUG_SLAB ifdefs, and remove all CONFIG_SLUB
ifdefs.
Reviewed-by: Kees Cook
Signed-off-by: Vlastimil Babka
---
include/linux/slab.h | 14 ++-
mm/slab.h| 69
mm/slab.h is the only place to include include/linux/slub_def.h which
has allowed switching between SLAB and SLUB. Now we can simply move the
contents over and remove slub_def.h.
Use this opportunity to fix up some whitespace (alignment) issues.
Reviewed-by: Kees Cook
Signed-off-by: Vlastimil Ba
We don't share those between SLAB and SLUB anymore, so most memcg
related functions can be moved to slub.c proper.
Reviewed-by: Kees Cook
Acked-by: Michal Hocko
Signed-off-by: Vlastimil Babka
---
mm/slab.h | 206 --
mm/slub.c | 205 ++
In preparation for the next patch, move the kmalloc_slab() function to
the header, as it will have callers from two files, and make it inline.
To avoid unnecessary bloat, remove all size checks/warnings from
kmalloc_slab() as they just duplicate those in callers, especially after
recent changes to
Remove CONFIG_SLAB, CONFIG_DEBUG_SLAB, CONFIG_SLAB_DEPRECATED and
everything in Kconfig files and mm/Makefile that depends on those. Since
SLUB is the only remaining allocator, remove the allocator choice, make
CONFIG_SLUB a "def_bool y" for now and remove all explicit dependencies
on SLUB or SLAB
The #include's are scattered at several places of the file, but it does
not seem this is needed to prevent any include loops (anymore?) so
consolidate them at the top. Also move the misplaced kmem_cache_init()
declaration away from the top.
Signed-off-by: Vlastimil Babka
---
mm/slab.h | 28 +
The declaration and associated helpers are not used anywhere else
anymore.
Reviewed-by: Kees Cook
Signed-off-by: Vlastimil Babka
---
mm/slab.h | 29 -
mm/slub.c | 27 +++
2 files changed, 27 insertions(+), 29 deletions(-)
diff --git a/mm/slab
This should result in better code. Currently kfree() makes a function
call between compilation units to __kmem_cache_free() which does its own
virt_to_slab(), throwing away the struct slab pointer we already had in
kfree(). Now it can be reused. Additionally kfree() can now inline the
whole SLUB fr
Inspection of kmem_cache_free() disassembly showed we could make the
fast path smaller by providing few more hints to the compiler, and
splitting the memcg_slab_free_hook() into an inline part that only
checks if there's work to do, and an out of line part doing the actual
uncharge.
bloat-o-meter
slab_alloc() is a thin wrapper around slab_alloc_node() with only one
caller. Replace with direct call of slab_alloc_node().
__kmem_cache_alloc_lru() itself is a thin wrapper with two callers,
so replace it with direct calls of slab_alloc_node() and
trace_kmem_cache_alloc().
This also makes sure
We don't share the hooks between two slab implementations anymore so
they can be moved away from the header. As part of the move, also move
should_failslab() from slab_common.c as the pre_alloc hook uses it.
This means slab.h can stop including fault-inject.h and kmemleak.h.
Fix up some files that
This will eliminate a call between compilation units through
__kmem_cache_alloc_node() and allow better inlining of the allocation
fast path.
Reviewed-by: Kees Cook
Signed-off-by: Vlastimil Babka
---
mm/slab.h| 3 --
mm/slab_common.c | 119 -
With allocation fastpaths no longer divided between two .c files, we
have better inlining, however checking the disassembly of
kmem_cache_alloc() reveals we can do better to make the fastpaths
smaller and move the less common situations out of line or to separate
functions, to reduce instruction ca
Remove the SLAB implementation. Update CREDITS.
Also update and properly sort the SLOB entry there.
RIP SLAB allocator (1996 - 2024)
Reviewed-by: Kees Cook
Signed-off-by: Vlastimil Babka
---
CREDITS | 12 +-
include/linux/slab_def.h | 124 --
mm/slab.c| 4005
25 matches
Mail list logo