Skip to contentSkip to conversation

linux-next: build failures after merge of the devicetree tree

PATCH Stephen Rothwell 1 participant 1 message Apr 11, 2023

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

Hi all,

After merging the devicetree tree, today's linux-next build (i386 defconfig) failed like this:

In file included from kernel/irq/irqdomain.c:15:
include/linux/of_address.h:111:12: error: 'of_property_read_reg' defined but not used [-Werror=unused-function]
111 | static int of_property_read_reg(struct device_node *np, int idx, u64 *addr, u64 *size)

      |            ^~~~~~~~~~~~~~~~~~~~
In file included from drivers/base/property.c:14:
include/linux/of_address.h:111:12: error: 'of_property_read_reg' defined but not used [-Werror=unused-function]
  111 | static int of_property_read_reg(struct device_node *np, int idx, u64 *addr, u64 *size)
      |            ^~~~~~~~~~~~~~~~~~~~
In file included from lib/devres.c:7:
include/linux/of_address.h:111:12: error: 'of_property_read_reg' defined but not used [-Werror=unused-function]
  111 | static int of_property_read_reg(struct device_node *np, int idx, u64 *addr, u64 *size)
      |            ^~~~~~~~~~~~~~~~~~~~

Introduced by commit

87b764b15f9a ("of/address: Add of_property_read_reg() helper")

I applied the following fix patch:

From: Stephen Rothwell <[email protected]>
Date: Tue, 11 Apr 2023 16:09:19 +1000
Subject: [PATCH] of/address: fixup for "Add of_property_read_reg() helper"

---
 include/linux/of_address.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/linux/of_address.h +1 -1
index 95cb6c5c2d67..26a19daf0d09 100644
@@ -108,7 +108,7 @@ static inline const __be32 *__of_get_address(struct device_node *dev, int index,
 	return NULL;
 }
 
-static int of_property_read_reg(struct device_node *np, int idx, u64 *addr, u64 *size)
+static inline int of_property_read_reg(struct device_node *np, int idx, u64 *addr, u64 *size)
 {
 	return -ENOSYS;
 }
Signature · 5 lines
2.39.2

-- 
Cheers,
Stephen Rothwell