On Tue, Nov 18, 2025 at 03:44:01PM -0400, Jason Gunthorpe wrote: > On Thu, Nov 13, 2025 at 04:05:09PM -0800, Nicolin Chen wrote: > > > -struct iopt_pages *iopt_alloc_file_pages(struct file *file, unsigned > > > long start, > > > +struct iopt_pages *iopt_alloc_file_pages(struct file *file, > > > + unsigned long start_byte, > > > + unsigned long start, > > > unsigned long length, bool writable); > > > > Passing in start_byte looks like a cleanup to me, aligning with > > what iopt_map_common() has. > > > Since we are doing this cleanup, maybe we could follow the same > > sequence: xxx, start, length, start_byte, writable? > > ?? > > static int iopt_map_common(struct iommufd_ctx *ictx, struct io_pagetable > *iopt, > struct iopt_pages *pages, unsigned long *iova, > unsigned long length, unsigned long start_byte, > int iommu_prot, unsigned int flags) > > Not the same arguments, we don't pass start and start_byte there?
I found that iopt_map_common() has a "start_byte" following the "length". So, wondering if it'd be cleaner to do the same. But, yes, they are slightly different. Let's keep it as-is then. Thanks Nicolin
