public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] [v2] accel/amdxdna: include linux/slab.h
@ 2024-12-18  8:58 Arnd Bergmann
  2024-12-18 14:30 ` Mario Limonciello
  0 siblings, 1 reply; 2+ messages in thread
From: Arnd Bergmann @ 2024-12-18  8:58 UTC (permalink / raw)
  To: Min Ma, Lizhi Hou, Oded Gabbay, Jeffrey Hugo
  Cc: Arnd Bergmann, Mario Limonciello, Narendra Gutta, dri-devel,
	linux-kernel

From: Arnd Bergmann <arnd@arndb.de>

This driver fails to build in random configurations:

drivers/accel/amdxdna/aie2_solver.c: In function 'remove_partition_node':
drivers/accel/amdxdna/aie2_solver.c:121:9: error: implicit declaration of function 'kfree' [-Wimplicit-function-declaration]
  121 |         kfree(pt_node);
      |         ^~~~~
drivers/accel/amdxdna/aie2_solver.c: In function 'get_free_partition':
drivers/accel/amdxdna/aie2_solver.c:153:19: error: implicit declaration of function 'kzalloc' [-Wimplicit-function-declaration]
  153 |         pt_node = kzalloc(sizeof(*pt_node), GFP_KERNEL);

Add the missing include.

Fixes: c88d3325ae69 ("accel/amdxdna: Add hardware resource solver")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
This one is still needed, I had previously combined two missing includes
in one patch
---
 drivers/accel/amdxdna/aie2_solver.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/accel/amdxdna/aie2_solver.c b/drivers/accel/amdxdna/aie2_solver.c
index 1939625d6027..2013d1f13aae 100644
--- a/drivers/accel/amdxdna/aie2_solver.c
+++ b/drivers/accel/amdxdna/aie2_solver.c
@@ -8,6 +8,7 @@
 #include <drm/drm_print.h>
 #include <linux/bitops.h>
 #include <linux/bitmap.h>
+#include <linux/slab.h>
 
 #include "aie2_solver.h"
 
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] [v2] accel/amdxdna: include linux/slab.h
  2024-12-18  8:58 [PATCH] [v2] accel/amdxdna: include linux/slab.h Arnd Bergmann
@ 2024-12-18 14:30 ` Mario Limonciello
  0 siblings, 0 replies; 2+ messages in thread
From: Mario Limonciello @ 2024-12-18 14:30 UTC (permalink / raw)
  To: Arnd Bergmann, Min Ma, Lizhi Hou, Oded Gabbay, Jeffrey Hugo
  Cc: Arnd Bergmann, Narendra Gutta, dri-devel, linux-kernel

On 12/18/2024 02:58, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
> 
> This driver fails to build in random configurations:
> 
> drivers/accel/amdxdna/aie2_solver.c: In function 'remove_partition_node':
> drivers/accel/amdxdna/aie2_solver.c:121:9: error: implicit declaration of function 'kfree' [-Wimplicit-function-declaration]
>    121 |         kfree(pt_node);
>        |         ^~~~~
> drivers/accel/amdxdna/aie2_solver.c: In function 'get_free_partition':
> drivers/accel/amdxdna/aie2_solver.c:153:19: error: implicit declaration of function 'kzalloc' [-Wimplicit-function-declaration]
>    153 |         pt_node = kzalloc(sizeof(*pt_node), GFP_KERNEL);
> 
> Add the missing include.
> 
> Fixes: c88d3325ae69 ("accel/amdxdna: Add hardware resource solver")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
> This one is still needed, I had previously combined two missing includes
> in one patch

Reviewed-by: Mario Limonciello <mario.limonciello@amd.com>

Applied to drm-misc-next.

221e29e197981 accel/amdxdna: include linux/slab.h

> ---
>   drivers/accel/amdxdna/aie2_solver.c | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/accel/amdxdna/aie2_solver.c b/drivers/accel/amdxdna/aie2_solver.c
> index 1939625d6027..2013d1f13aae 100644
> --- a/drivers/accel/amdxdna/aie2_solver.c
> +++ b/drivers/accel/amdxdna/aie2_solver.c
> @@ -8,6 +8,7 @@
>   #include <drm/drm_print.h>
>   #include <linux/bitops.h>
>   #include <linux/bitmap.h>
> +#include <linux/slab.h>
>   
>   #include "aie2_solver.h"
>   


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-12-18 14:30 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-18  8:58 [PATCH] [v2] accel/amdxdna: include linux/slab.h Arnd Bergmann
2024-12-18 14:30 ` Mario Limonciello

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox