From: Shivaprasad G Bhat <sbhat@linux.ibm.com>
To: Jason Gunthorpe <jgg@ziepe.ca>
Cc: Venkat Rao Bagalkote <venkat88@linux.vnet.ibm.com>,
iommu@lists.linux.dev, linuxppc-dev@lists.ozlabs.org,
linux-kernel@vger.kernel.org, npiggin@gmail.com,
christophe.leroy@csgroup.eu, aneesh.kumar@kernel.org,
naveen.n.rao@linux.ibm.com, jroedel@suse.de,
tpearson@raptorengineering.com, aik@amd.com, bgray@linux.ibm.com,
gregkh@linuxfoundation.org, gbatra@linux.vnet.ibm.com,
vaibhav@linux.ibm.com, Michael Ellerman <mpe@ellerman.id.au>
Subject: Re: [PATCH] powerpc/iommu: Fix the missing iommu_group_put() during platform domain attach
Date: Wed, 14 Feb 2024 23:43:28 +0530 [thread overview]
Message-ID: <0abafe3e-7dfd-4067-8a47-fa8eea00b232@linux.ibm.com> (raw)
In-Reply-To: <20240214125819.GA1299735@ziepe.ca>
On 2/14/24 18:28, Jason Gunthorpe wrote:
> On Wed, Feb 14, 2024 at 11:53:20PM +1100, Michael Ellerman wrote:
>> Venkat Rao Bagalkote <venkat88@linux.vnet.ibm.com> writes:
>>> Thanks for the patch. Applied this patch and verified and issue is fixed.
>>>
>>> This issue way originally reported in the below mail.
>>>
>>> https://marc.info/?l=linux-kernel&m=170737160630106&w=2
>> Please use lore for links, in this case:
>>
>> https://lore.kernel.org/all/274e0d2b-b5cc-475e-94e6-8427e88e271d@linux.vnet.ibm.com/
> Also if you are respinning you may prefer this
>
> @@ -1285,14 +1285,15 @@ spapr_tce_platform_iommu_attach_dev(struct iommu_domain *platform_domain,
> struct device *dev)
> {
> struct iommu_domain *domain = iommu_get_domain_for_dev(dev);
> - struct iommu_group *grp = iommu_group_get(dev);
> struct iommu_table_group *table_group;
> + struct iommu_group *grp;
> int ret = -EINVAL;
>
> /* At first attach the ownership is already set */
> if (!domain)
> return 0;
>
> + grp = iommu_group_get(dev);
> if (!grp)
> return -ENODEV;
>
> Which is sort of why this happened in the first place :)
Right! Posted the v2 here
https://lore.kernel.org/linux-iommu/170793401503.7491.9431631474642074097.stgit@linux.ibm.com/
Thanks,
Shivaprasad
> Jason
WARNING: multiple messages have this Message-ID (diff)
From: Shivaprasad G Bhat <sbhat@linux.ibm.com>
To: Jason Gunthorpe <jgg@ziepe.ca>
Cc: Venkat Rao Bagalkote <venkat88@linux.vnet.ibm.com>,
jroedel@suse.de, gbatra@linux.vnet.ibm.com,
gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org,
aneesh.kumar@kernel.org, tpearson@raptorengineering.com,
iommu@lists.linux.dev, npiggin@gmail.com, bgray@linux.ibm.com,
naveen.n.rao@linux.ibm.com, vaibhav@linux.ibm.com,
linuxppc-dev@lists.ozlabs.org, aik@amd.com
Subject: Re: [PATCH] powerpc/iommu: Fix the missing iommu_group_put() during platform domain attach
Date: Wed, 14 Feb 2024 23:43:28 +0530 [thread overview]
Message-ID: <0abafe3e-7dfd-4067-8a47-fa8eea00b232@linux.ibm.com> (raw)
In-Reply-To: <20240214125819.GA1299735@ziepe.ca>
On 2/14/24 18:28, Jason Gunthorpe wrote:
> On Wed, Feb 14, 2024 at 11:53:20PM +1100, Michael Ellerman wrote:
>> Venkat Rao Bagalkote <venkat88@linux.vnet.ibm.com> writes:
>>> Thanks for the patch. Applied this patch and verified and issue is fixed.
>>>
>>> This issue way originally reported in the below mail.
>>>
>>> https://marc.info/?l=linux-kernel&m=170737160630106&w=2
>> Please use lore for links, in this case:
>>
>> https://lore.kernel.org/all/274e0d2b-b5cc-475e-94e6-8427e88e271d@linux.vnet.ibm.com/
> Also if you are respinning you may prefer this
>
> @@ -1285,14 +1285,15 @@ spapr_tce_platform_iommu_attach_dev(struct iommu_domain *platform_domain,
> struct device *dev)
> {
> struct iommu_domain *domain = iommu_get_domain_for_dev(dev);
> - struct iommu_group *grp = iommu_group_get(dev);
> struct iommu_table_group *table_group;
> + struct iommu_group *grp;
> int ret = -EINVAL;
>
> /* At first attach the ownership is already set */
> if (!domain)
> return 0;
>
> + grp = iommu_group_get(dev);
> if (!grp)
> return -ENODEV;
>
> Which is sort of why this happened in the first place :)
Right! Posted the v2 here
https://lore.kernel.org/linux-iommu/170793401503.7491.9431631474642074097.stgit@linux.ibm.com/
Thanks,
Shivaprasad
> Jason
next prev parent reply other threads:[~2024-02-14 18:13 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-13 16:05 [PATCH] powerpc/iommu: Fix the missing iommu_group_put() during platform domain attach Shivaprasad G Bhat
2024-02-13 16:05 ` Shivaprasad G Bhat
2024-02-13 17:21 ` Jason Gunthorpe
2024-02-13 17:21 ` Jason Gunthorpe
2024-02-14 5:34 ` Venkat Rao Bagalkote
2024-02-14 5:34 ` Venkat Rao Bagalkote
2024-02-14 12:53 ` Michael Ellerman
2024-02-14 12:53 ` Michael Ellerman
2024-02-14 12:58 ` Jason Gunthorpe
2024-02-14 12:58 ` Jason Gunthorpe
2024-02-14 18:13 ` Shivaprasad G Bhat [this message]
2024-02-14 18:13 ` Shivaprasad G Bhat
2024-02-15 12:57 ` Michael Ellerman
2024-02-15 12:57 ` Michael Ellerman
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=0abafe3e-7dfd-4067-8a47-fa8eea00b232@linux.ibm.com \
--to=sbhat@linux.ibm.com \
--cc=aik@amd.com \
--cc=aneesh.kumar@kernel.org \
--cc=bgray@linux.ibm.com \
--cc=christophe.leroy@csgroup.eu \
--cc=gbatra@linux.vnet.ibm.com \
--cc=gregkh@linuxfoundation.org \
--cc=iommu@lists.linux.dev \
--cc=jgg@ziepe.ca \
--cc=jroedel@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=mpe@ellerman.id.au \
--cc=naveen.n.rao@linux.ibm.com \
--cc=npiggin@gmail.com \
--cc=tpearson@raptorengineering.com \
--cc=vaibhav@linux.ibm.com \
--cc=venkat88@linux.vnet.ibm.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 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.