Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

memblock tests: Fix mutex related build error

Fix mutex and free_reserved_area() related build errors which have
been introduced by commit 74e2498ccf7b ("mm/memblock: Add reserved
memory release function").

Fixes: 74e2498ccf7b ("mm/memblock: Add reserved memory release function")
Reported-by: Wei Yang <richard.weiyang@gmail.com>
Closes: https://lore.kernel.org/all/20250405023018.g2ae52nrz2757b3n@master/
Signed-off-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
Link: https://lore.kernel.org/r/174399023133.47537.7375975856054461445.stgit@devnote2
Signed-off-by: Mike Rapoport (Microsoft) <rppt@kernel.org>

authored by

Masami Hiramatsu (Google) and committed by
Mike Rapoport (Microsoft)
ed471e19 0af2f6be

+20
+6
tools/testing/memblock/internal.h
··· 24 24 { 25 25 } 26 26 27 + static inline unsigned long free_reserved_area(void *start, void *end, 28 + int poison, const char *s) 29 + { 30 + return 0; 31 + } 32 + 27 33 #endif
+14
tools/testing/memblock/linux/mutex.h
··· 1 + /* SPDX-License-Identifier: GPL-2.0 */ 2 + #ifndef _MUTEX_H 3 + #define _MUTEX_H 4 + 5 + #define DEFINE_MUTEX(name) int name 6 + 7 + static inline void dummy_mutex_guard(int *name) 8 + { 9 + } 10 + 11 + #define guard(mutex) \ 12 + dummy_##mutex##_guard 13 + 14 + #endif /* _MUTEX_H */