Files
linux-cix/include/linux
Uros Bizjak 8c5ad189e9 cleanup: Remove address space of returned pointer
[ Upstream commit f730fd535fc51573f982fad629f2fc6b4a0cde2f ]

Guard functions in local_lock.h are defined using DEFINE_GUARD() and
DEFINE_LOCK_GUARD_1() macros having lock type defined as pointer in
the percpu address space. The functions, defined by these macros
return value in generic address space, causing:

cleanup.h:157:18: error: return from pointer to non-enclosed address space

and

cleanup.h:214:18: error: return from pointer to non-enclosed address space

when strict percpu checks are enabled.

Add explicit casts to remove address space of the returned pointer.

Found by GCC's named address space checks.

Fixes: e4ab322fbaaa ("cleanup: Add conditional guard support")
Signed-off-by: Uros Bizjak <ubizjak@gmail.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20240819074124.143565-1-ubizjak@gmail.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-01-09 13:31:53 +01:00
..
2024-07-25 09:50:47 +02:00
2024-10-04 16:29:59 +02:00
2024-06-12 11:11:38 +02:00
2024-07-05 09:34:04 +02:00
2024-12-14 19:59:58 +01:00
2024-08-29 17:33:31 +02:00
2024-06-16 13:47:41 +02:00
2024-06-12 11:12:52 +02:00
2025-01-09 13:31:41 +01:00
2024-06-12 11:11:56 +02:00
2024-05-17 12:01:59 +02:00
2025-01-09 13:31:41 +01:00
2024-08-29 17:33:23 +02:00
2024-10-17 15:24:23 +02:00
2024-11-08 16:28:26 +01:00