Re: [PATCH] memblock tests: fix implicit declaration of function 'numa_valid_node'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Mike,

Missed this one?

On Mon, Jun 24, 2024 at 01:54:32AM +0000, Wei Yang wrote:
>commit 8043832e2a12 ("memblock: use numa_valid_node() helper to check
>for invalid node ID") introduce a new helper numa_valid_node(), which is
>not defined in memblock tests.
>
>Let's add it in the corresponding header file.
>
>Signed-off-by: Wei Yang <richard.weiyang@xxxxxxxxx>
>CC: Mike Rapoport (IBM) <rppt@xxxxxxxxxx>
>---
> tools/include/linux/numa.h | 5 +++++
> 1 file changed, 5 insertions(+)
>
>diff --git a/tools/include/linux/numa.h b/tools/include/linux/numa.h
>index 110b0e5d0fb0..c8b9369335e0 100644
>--- a/tools/include/linux/numa.h
>+++ b/tools/include/linux/numa.h
>@@ -13,4 +13,9 @@
> 
> #define	NUMA_NO_NODE	(-1)
> 
>+static inline bool numa_valid_node(int nid)
>+{
>+	return nid >= 0 && nid < MAX_NUMNODES;
>+}
>+
> #endif /* _LINUX_NUMA_H */
>-- 
>2.34.1

-- 
Wei Yang
Help you, Help me




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux