2023-01-27 07:02:39

by Stephen Rothwell

[permalink] [raw]
Subject: linux-next: build failure after merge of the rpmsg tree

Hi all,

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

drivers/remoteproc/qcom_q6v5_adsp.c: In function 'adsp_map_carveout':
drivers/remoteproc/qcom_q6v5_adsp.c:369:15: error: too few arguments to function 'iommu_map'
369 | ret = iommu_map(rproc->domain, iova, adsp->mem_phys,
| ^~~~~~~~~
In file included from drivers/remoteproc/qcom_q6v5_adsp.c:12:
include/linux/iommu.h:473:12: note: declared here
473 | extern int iommu_map(struct iommu_domain *domain, unsigned long iova,
| ^~~~~~~~~

Caused by commit

f22eedff28af ("remoteproc: qcom: Add support for memory sandbox")

interacting with commit

1369459b2e21 ("iommu: Add a gfp parameter to iommu_map()")

from the iommu tree.

I have applied the following merge fix patch.

From: Stephen Rothwell <[email protected]>
Date: Fri, 27 Jan 2023 17:58:15 +1100
Subject: [PATCH] remoteproc: fix for "iommu: Add a gfp parameter to iommu_map()"

Signed-off-by: Stephen Rothwell <[email protected]>
---
drivers/remoteproc/qcom_q6v5_adsp.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/remoteproc/qcom_q6v5_adsp.c b/drivers/remoteproc/qcom_q6v5_adsp.c
index 2dc850f48f00..08d8dad22ca7 100644
--- a/drivers/remoteproc/qcom_q6v5_adsp.c
+++ b/drivers/remoteproc/qcom_q6v5_adsp.c
@@ -367,7 +367,8 @@ static int adsp_map_carveout(struct rproc *rproc)
iova = adsp->mem_phys | (sid << 32);

ret = iommu_map(rproc->domain, iova, adsp->mem_phys,
- adsp->mem_size, IOMMU_READ | IOMMU_WRITE);
+ adsp->mem_size, IOMMU_READ | IOMMU_WRITE,
+ GFP_KERNEL);
if (ret) {
dev_err(adsp->dev, "Unable to map ADSP Physical Memory\n");
return ret;
--
2.35.1

--
Cheers,
Stephen Rothwell


Attachments:
(No filename) (488.00 B)
OpenPGP digital signature

2023-01-30 08:52:01

by Joerg Roedel

[permalink] [raw]
Subject: Re: linux-next: build failure after merge of the rpmsg tree

Thanks for the report, Stephen.

Bjorn, Mathieu,

On Fri, Jan 27, 2023 at 06:02:26PM +1100, Stephen Rothwell wrote:
> After merging the rpmsg tree, today's linux-next build (arm64 defconfig)
> failed like this:
>
> drivers/remoteproc/qcom_q6v5_adsp.c: In function 'adsp_map_carveout':
> drivers/remoteproc/qcom_q6v5_adsp.c:369:15: error: too few arguments to function 'iommu_map'
> 369 | ret = iommu_map(rproc->domain, iova, adsp->mem_phys,
> | ^~~~~~~~~
> In file included from drivers/remoteproc/qcom_q6v5_adsp.c:12:
> include/linux/iommu.h:473:12: note: declared here
> 473 | extern int iommu_map(struct iommu_domain *domain, unsigned long iova,
> | ^~~~~~~~~
>
> Caused by commit
>
> f22eedff28af ("remoteproc: qcom: Add support for memory sandbox")
>
> interacting with commit
>
> 1369459b2e21 ("iommu: Add a gfp parameter to iommu_map()")
>
> from the iommu tree.

The patch-set causing this is in a separate branch in the IOMMU tree
which you can be merged into the rpmsg tree for a fixup there:

git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git iommu-memory-accounting

Regards,

--
J?rg R?del
[email protected]

SUSE Software Solutions Germany GmbH
Frankenstra?e 146
90461 N?rnberg
Germany

(HRB 36809, AG N?rnberg)
Gesch?ftsf?hrer: Ivo Totev, Andrew Myers, Andrew McDonald, Boudien Moerman