diff options
author | Tetsuo Handa <[email protected]> | 2022-07-20 23:47:55 +0900 |
---|---|---|
committer | akpm <[email protected]> | 2022-07-29 18:07:13 -0700 |
commit | 14773bfa70e67f4d4ebd60e60cb6e25e8c84d4c0 (patch) | |
tree | 67152cd43719fd51e7975bf56bf1194bafbfa181 /net/lapb/lapb_in.c | |
parent | 187e7c41445a0f202bb551f08ca7f8158fea1cd7 (diff) |
mm: shrinkers: fix double kfree on shrinker name
syzbot is reporting double kfree() at free_prealloced_shrinker() [1], for
destroy_unused_super() calls free_prealloced_shrinker() even if
prealloc_shrinker() returned an error. Explicitly clear shrinker name
when prealloc_shrinker() called kfree().
[[email protected]: zero shrinker->name in all cases where shrinker->name is freed]
Link: https://lkml.kernel.org/r/YtgteTnQTgyuKUSY@castle
Link: https://syzkaller.appspot.com/bug?extid=8b481578352d4637f510 [1]
Link: https://lkml.kernel.org/r/[email protected]
Fixes: e33c267ab70de424 ("mm: shrinkers: provide shrinkers with names")
Reported-by: syzbot <[email protected]>
Signed-off-by: Tetsuo Handa <[email protected]>
Acked-by: Roman Gushchin <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Diffstat (limited to 'net/lapb/lapb_in.c')
0 files changed, 0 insertions, 0 deletions