[PATCH v3 1/3] maple: fix build error due to missing include of linux/device.h

Florian Fuchs fuchsfl at gmail.com
Mon May 18 04:45:19 PDT 2026


The commit 313162d0b838 ("device.h: audit and cleanup users in main
include dir") removed the include linux/device.h from linux/maple.h,
which led to build errors as linux/maple.h embeds struct device via
struct maple_device. So restore this, as it otherwise results in errors:

./include/linux/maple.h:81:16: error: field 'dev' has incomplete type
  struct device dev;

Fixes: 313162d0b838 ("device.h: audit and cleanup users in main include dir")
Cc: stable at vger.kernel.org
Signed-off-by: Florian Fuchs <fuchsfl at gmail.com>
---
v2->v3: no functional change, reword commit message, align subject to
	main includedir, add Cc tag
v1->v2: no functional change, just rebase patch

v2: https://lore.kernel.org/lkml/20260427114750.2480900-2-fuchsfl@gmail.com/
v1: https://lore.kernel.org/lkml/20251117224408.498449-2-fuchsfl@gmail.com/

 include/linux/maple.h | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/include/linux/maple.h b/include/linux/maple.h
index 3be4e567473c..22f2930251ed 100644
--- a/include/linux/maple.h
+++ b/include/linux/maple.h
@@ -2,10 +2,9 @@
 #ifndef __LINUX_MAPLE_H
 #define __LINUX_MAPLE_H
 
+#include <linux/device.h>
 #include <mach/maple.h>
 
-struct device;
-
 /* Maple Bus command and response codes */
 enum maple_code {
 	MAPLE_RESPONSE_FILEERR =	-5,
-- 
2.43.0




More information about the linux-mtd mailing list