[PATCH v6 06/10] accel/rocket: Add IOCTL for BO creation
Tomeu Vizoso
tomeu at tomeuvizoso.net
Thu Jun 5 05:57:02 PDT 2025
On Thu, Jun 5, 2025 at 2:29 PM Daniel Stone <daniel at fooishbar.org> wrote:
>
> Hey,
>
> On Thu, 5 Jun 2025 at 08:41, Tomeu Vizoso <tomeu at tomeuvizoso.net> wrote:
> > > Indeed if you're using the IOMMU API directly then you need to do your
> > > own address space management either way, so matching bits of process VA
> > > space is pretty simple to put on the table.
> >
> > My impression was that the VM_BIND facility is intended for SVM as in
> > OpenCL and maybe Vulkan?
> >
> > Guess my question is, what would such an accelerator driver win by
> > letting userspace manage the address space?
>
> I mean, not a lot gained, but otoh there's also not much to be gained
> by using the kernel's range allocator either, and it saves userspace a
> roundtrip to discover the VA for a BO it just created/mapped?
Oh, I just map on creation and return the VA as an out arg in the
creation ioctl.
So it just seemed the simplest approach, with the least custom code in
the driver.
Cheers,
Tomeu
More information about the Linux-rockchip
mailing list