From: Stephen Rothwell <sfr@canb.auug.org.au>
To: Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Cc: Kris Chaplin <kris.chaplin@amd.com>,
Thomas Delev <thomas.delev@amd.com>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Linux Next Mailing List <linux-next@vger.kernel.org>
Subject: linux-next: build failure after merge of the devicetree tree
Date: Fri, 8 Dec 2023 13:51:33 +1100 [thread overview]
Message-ID: <20231208135133.42704925@canb.auug.org.au> (raw)
[-- Attachment #1: Type: text/plain, Size: 5808 bytes --]
Hi all,
After merging the devicetree tree, today's linux-next build (x86_64
allmodconfig) failed like this:
drivers/w1/masters/amd_axi_w1.c: In function 'amd_axi_w1_probe':
drivers/w1/masters/amd_axi_w1.c:296:35: error: invalid use of undefined type 'struct platform_device'
296 | struct device *dev = &pdev->dev;
| ^~
drivers/w1/masters/amd_axi_w1.c:307:25: error: implicit declaration of function 'devm_platform_ioremap_resource'; did you mean 'devm_ioremap_resource'? [-Werror=implicit-function-declaration]
307 | lp->base_addr = devm_platform_ioremap_resource(pdev, 0);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| devm_ioremap_resource
drivers/w1/masters/amd_axi_w1.c:307:23: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
307 | lp->base_addr = devm_platform_ioremap_resource(pdev, 0);
| ^
drivers/w1/masters/amd_axi_w1.c:311:19: error: implicit declaration of function 'platform_get_irq'; did you mean 'platform_notify'? [-Werror=implicit-function-declaration]
311 | lp->irq = platform_get_irq(pdev, 0);
| ^~~~~~~~~~~~~~~~
| platform_notify
drivers/w1/masters/amd_axi_w1.c:360:9: error: implicit declaration of function 'platform_set_drvdata' [-Werror=implicit-function-declaration]
360 | platform_set_drvdata(pdev, lp);
| ^~~~~~~~~~~~~~~~~~~~
drivers/w1/masters/amd_axi_w1.c: In function 'amd_axi_w1_remove':
drivers/w1/masters/amd_axi_w1.c:372:39: error: implicit declaration of function 'platform_get_drvdata' [-Werror=implicit-function-declaration]
372 | struct amd_axi_w1_local *lp = platform_get_drvdata(pdev);
| ^~~~~~~~~~~~~~~~~~~~
drivers/w1/masters/amd_axi_w1.c:372:39: warning: initialization of 'struct amd_axi_w1_local *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
drivers/w1/masters/amd_axi_w1.c: At top level:
drivers/w1/masters/amd_axi_w1.c:383:15: error: variable 'amd_axi_w1_driver' has initializer but incomplete type
383 | static struct platform_driver amd_axi_w1_driver = {
| ^~~~~~~~~~~~~~~
drivers/w1/masters/amd_axi_w1.c:384:10: error: 'struct platform_driver' has no member named 'probe'
384 | .probe = amd_axi_w1_probe,
| ^~~~~
drivers/w1/masters/amd_axi_w1.c:384:18: warning: excess elements in struct initializer
384 | .probe = amd_axi_w1_probe,
| ^~~~~~~~~~~~~~~~
drivers/w1/masters/amd_axi_w1.c:384:18: note: (near initialization for 'amd_axi_w1_driver')
drivers/w1/masters/amd_axi_w1.c:385:10: error: 'struct platform_driver' has no member named 'remove_new'
385 | .remove_new = amd_axi_w1_remove,
| ^~~~~~~~~~
drivers/w1/masters/amd_axi_w1.c:385:23: warning: excess elements in struct initializer
385 | .remove_new = amd_axi_w1_remove,
| ^~~~~~~~~~~~~~~~~
drivers/w1/masters/amd_axi_w1.c:385:23: note: (near initialization for 'amd_axi_w1_driver')
drivers/w1/masters/amd_axi_w1.c:386:10: error: 'struct platform_driver' has no member named 'driver'
386 | .driver = {
| ^~~~~~
drivers/w1/masters/amd_axi_w1.c:386:19: error: extra brace group at end of initializer
386 | .driver = {
| ^
drivers/w1/masters/amd_axi_w1.c:386:19: note: (near initialization for 'amd_axi_w1_driver')
drivers/w1/masters/amd_axi_w1.c:386:19: warning: excess elements in struct initializer
drivers/w1/masters/amd_axi_w1.c:386:19: note: (near initialization for 'amd_axi_w1_driver')
drivers/w1/masters/amd_axi_w1.c:391:1: warning: data definition has no type or storage class
391 | module_platform_driver(amd_axi_w1_driver);
| ^~~~~~~~~~~~~~~~~~~~~~
drivers/w1/masters/amd_axi_w1.c:391:1: error: type defaults to 'int' in declaration of 'module_platform_driver' [-Werror=implicit-int]
drivers/w1/masters/amd_axi_w1.c:391:1: warning: parameter names (without types) in function declaration
drivers/w1/masters/amd_axi_w1.c:383:31: error: storage size of 'amd_axi_w1_driver' isn't known
383 | static struct platform_driver amd_axi_w1_driver = {
| ^~~~~~~~~~~~~~~~~
drivers/w1/masters/amd_axi_w1.c:383:31: warning: 'amd_axi_w1_driver' defined but not used [-Wunused-variable]
Caused by commit
0d18bcdebb2f ("of: Stop circularly including of_device.h and of_platform.h")
interacting with commit
271c81935801 ("w1: Add AXI 1-wire host driver for AMD programmable logic IP core")
from the w1 tree.
I have applied the following merge fix patch for today (that could just
be applied to the w1 tree).
From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Fri, 8 Dec 2023 13:37:03 +1100
Subject: [PATCH] amd_axi_w1: include the correct files
This is to cope with "of: Stop circularly including of_device.h and
of_platform.h"
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
drivers/w1/masters/amd_axi_w1.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/w1/masters/amd_axi_w1.c b/drivers/w1/masters/amd_axi_w1.c
index 24a05c2de5f1..f8b31cae450d 100644
--- a/drivers/w1/masters/amd_axi_w1.c
+++ b/drivers/w1/masters/amd_axi_w1.c
@@ -13,7 +13,8 @@
#include <linux/jiffies.h>
#include <linux/kernel.h>
#include <linux/module.h>
-#include <linux/of_platform.h>
+#include <linux/platform_device.h>
+#include <linux/mod_devicetable.h>
#include <linux/types.h>
#include <linux/wait.h>
--
2.40.1
--
Cheers,
Stephen Rothwell
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next reply other threads:[~2023-12-08 2:51 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-08 2:51 Stephen Rothwell [this message]
2023-12-08 7:34 ` linux-next: build failure after merge of the devicetree tree Krzysztof Kozlowski
-- strict thread matches above, loose matches on Subject: below --
2023-12-11 5:05 Stephen Rothwell
2023-12-12 9:04 ` Sibi Sankar
2024-01-19 0:58 ` Stephen Rothwell
2024-01-19 14:07 ` Rob Herring
2023-12-07 1:57 Stephen Rothwell
2023-12-07 15:11 ` Rob Herring
2023-12-07 20:58 ` Stephen Rothwell
2023-12-07 22:05 ` Rob Herring
2023-12-08 3:11 ` Stephen Rothwell
2023-04-11 2:28 Stephen Rothwell
2014-05-26 5:05 Stephen Rothwell
2014-05-26 7:22 ` Thomas Petazzoni
2011-10-05 5:24 Stephen Rothwell
2011-10-05 5:54 ` Grant Likely
2010-07-30 3:57 Stephen Rothwell
2010-07-30 6:11 ` Grant Likely
2010-07-15 2:15 Stephen Rothwell
2010-07-15 6:06 ` Grant Likely
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20231208135133.42704925@canb.auug.org.au \
--to=sfr@canb.auug.org.au \
--cc=kris.chaplin@amd.com \
--cc=krzysztof.kozlowski@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@vger.kernel.org \
--cc=robh@kernel.org \
--cc=thomas.delev@amd.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).