On Mon, 9 Nov 2026 17:38:57 +0000 Daniel Stone <[email protected]> wrote:
> Hi Igor, > > On Mon, 9 Nov 2026 at 10:57, Igor Torrente <[email protected]> > wrote: > > Panthor currently does not allow exporting BOs with an exclusive VM. > > However, VDRM (native context) drivers export BOs for import by the guest > > VM, which does not attempt to bind them to any GPU VM. > > > > Allow these BOs to be exported and rely on > > panthor_vm_prepare_map_op_ctx() to reject attempts to bind them to a > > different GPU VM. > > I'm having a little trouble parsing this. > > Is the problem that: > - the guest requests allocation of a BO with exclusive_vm_root_gem = guest_vm > - the host passes that allocation through > - the host exports a dmabuf from the allocation (which fails) > - the host imports a dmabuf from the allocation (?) > - the guest requests the BO be attached to guest_vm > > i.e. is the problem that some host implementations (virglrenderer) > handle BO allocation exclusively via an export/import interface? > > If that is the problem, it seems like it would be cleaner to have the > host implementation strip the exclusive VM ID from the request, until > they can be fixed to not require the export/import dance. Dropping the exclusive_vm assignment is indeed an option. The big issue comes from the overhead incurred by BO access tracking when the BO is shared: - bo_wait() has to do a HANDLE_TO_FD + EXPORT_SYNC dance - attach_sync_point() has to do an EXPORT_SYNC_FILE + HANDLE_TO_FD + IMPORT_SYNC_FILE dance - the locking of shared BOs in the GROUP_SUBMIT path is more costly (one lock per shared BO instead of one lock for all private BOs) I don't have numbers, but I suspect lowering all private BOs to shared ones will have a noticeable impact on perfs.
