From: Jason Gunthorpe <jgg@nvidia.com>
To: Dan Carpenter <dan.carpenter@linaro.org>
Cc: iommu@lists.linux.dev, Joerg Roedel <joro@8bytes.org>,
Robin Murphy <robin.murphy@arm.com>,
Will Deacon <will@kernel.org>,
Lu Baolu <baolu.lu@linux.intel.com>,
Joerg Roedel <jroedel@suse.de>,
Jerry Snitselaar <jsnitsel@redhat.com>
Subject: Re: [PATCH] iommu: Fix return code in iommu_group_alloc_default_domain()
Date: Wed, 4 Oct 2023 09:06:40 -0300 [thread overview]
Message-ID: <20231004120640.GE682044@nvidia.com> (raw)
In-Reply-To: <39c620e7-86fb-4372-ab0e-9f772cdc60aa@kadam.mountain>
On Wed, Oct 04, 2023 at 03:03:41PM +0300, Dan Carpenter wrote:
> On Wed, Oct 04, 2023 at 08:59:43AM -0300, Jason Gunthorpe wrote:
> > This function returns NULL on errors, not ERR_PTR.
> >
> > Fixes: 1c68cbc64fe6 ("iommu: Add IOMMU_DOMAIN_PLATFORM")
> > Reported-by: Dan Carpenter <dan.carpenter@linaro.org>
> > Link: https://lore.kernel.org/r/8fb75157-6c81-4a9c-9992-d73d49902fa8@moroto.mountain
> > Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
> > ---
> > drivers/iommu/iommu.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/iommu/iommu.c b/drivers/iommu/iommu.c
> > index 13b911e4323d06..f9f315d58a3a14 100644
> > --- a/drivers/iommu/iommu.c
> > +++ b/drivers/iommu/iommu.c
> > @@ -1787,7 +1787,7 @@ iommu_group_alloc_default_domain(struct iommu_group *group, int req_type)
> > */
> > if (ops->default_domain) {
> > if (req_type)
> > - return -EINVAL;
> > + return NULL;
>
> This looks like a merge conflict? -EINVAL is an int and NULL is a
> pointer. #strange
Uhh.. the power patch I was working on accidently collected half of
this change and I didn't notice :\
Thanks,
Jason
prev parent reply other threads:[~2023-10-04 12:06 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-04 11:59 [PATCH] iommu: Fix return code in iommu_group_alloc_default_domain() Jason Gunthorpe
2023-10-04 12:03 ` Dan Carpenter
2023-10-04 12:06 ` Jason Gunthorpe [this message]
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=20231004120640.GE682044@nvidia.com \
--to=jgg@nvidia.com \
--cc=baolu.lu@linux.intel.com \
--cc=dan.carpenter@linaro.org \
--cc=iommu@lists.linux.dev \
--cc=joro@8bytes.org \
--cc=jroedel@suse.de \
--cc=jsnitsel@redhat.com \
--cc=robin.murphy@arm.com \
--cc=will@kernel.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.