Skip to content

Commit a081748

Browse files
committed
of/flattree: forward declare struct device_node in of_fdt.h
This patch forward declares struct device_node to fix a compile error when of_fdt.h is included, but of.h is not. Alternately, including linux/of.h could have been added to of_fdt.h, but that pulls in a lot of unnecessary declarations when only working with the flattened form. Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
1 parent 672d8ea commit a081748

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

‎include/linux/of_fdt.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,8 @@ struct boot_param_header {
5959

6060
#if defined(CONFIG_OF_FLATTREE)
6161

62+
struct device_node;
63+
6264
/* For scanning an arbitrary device-tree at any time */
6365
extern char *of_fdt_get_string(struct boot_param_header *blob, u32 offset);
6466
extern void *of_fdt_get_property(struct boot_param_header *blob,

0 commit comments

Comments
 (0)