mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-03-22 07:27:12 +08:00
arm64: module: remove unneeded call to kasan_alloc_module_shadow()
Since commit f6f37d9320 ("arm64: select KASAN_VMALLOC for SW/HW_TAGS
modes") KASAN_VMALLOC is always enabled when KASAN is on. This means
that allocations in module_alloc() will be tracked by KASAN protection
for vmalloc() and that kasan_alloc_module_shadow() will be always an
empty inline and there is no point in calling it.
Drop meaningless call to kasan_alloc_module_shadow() from
module_alloc().
Signed-off-by: Mike Rapoport (IBM) <rppt@kernel.org>
Signed-off-by: Luis Chamberlain <mcgrof@kernel.org>
This commit is contained in:
committed by
Luis Chamberlain
parent
086437d94a
commit
00be875879
@@ -141,11 +141,6 @@ void *module_alloc(unsigned long size)
|
||||
__func__);
|
||||
}
|
||||
|
||||
if (p && (kasan_alloc_module_shadow(p, size, GFP_KERNEL) < 0)) {
|
||||
vfree(p);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/* Memory is intended to be executable, reset the pointer tag. */
|
||||
return kasan_reset_tag(p);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user