lkml.org 
[lkml]   [2023]   [May]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH v2 04/11] iommufd: Pass parent hwpt and user_data to iommufd_hw_pagetable_alloc()
On Fri, May 19, 2023 at 09:34:38AM +0000, Tian, Kevin wrote:

> > From: Liu, Yi L <yi.l.liu@intel.com>
> > Sent: Thursday, May 11, 2023 10:39 PM
> > @@ -89,9 +101,15 @@ iommufd_hw_pagetable_alloc(struct iommufd_ctx
> > *ictx, struct iommufd_ioas *ioas,
> > /* Pairs with iommufd_hw_pagetable_destroy() */
> > refcount_inc(&ioas->obj.users);
> > hwpt->ioas = ioas;
>
> presumably a user hwpt doesn't need store ioas?

hwpt->ioas has the refcount and mutex that are used by a user
hwpt too throughout the hwpt functions.

Thanks
Nic

\
 
 \ /
  Last update: 2023-05-19 21:15    [W:1.112 / U:0.024 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site