lkml.org 
[lkml]   [2023]   [Mar]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [PATCH v2 1/5] iommufd: Add nesting related data structures for Intel VT-d
Date
> From: Jason Gunthorpe <jgg@nvidia.com>
> Sent: Monday, March 20, 2023 9:50 PM
>
> On Thu, Mar 09, 2023 at 12:22:03AM -0800, Yi Liu wrote:
>
> > +struct iommu_hwpt_invalidate_intel_vtd {
> > + __u8 granularity;
> > + __u8 padding[7];
> > + __u32 flags;
> > + __u32 __reserved;
> > + __u64 addr;
> > + __u64 granule_size;
> > + __u64 nb_granules;
> > +};
>
> Is there a reason this has such a weird layout? Put the granularity in
> the __reserved slot?

No special reason. This layout was from the previous merged version.
Will modify it as you suggested.

> Consider the discussion on ARM if you prefer to use the native HW
> command structure instead?

Yes, will think about it. at least granule_size and nb_granules are not
necessary. They was added in the previous abstracted invalidation
uapi structure.

Regards,
Yi Liu

\
 
 \ /
  Last update: 2023-03-27 01:10    [W:0.068 / U:0.264 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site