Re: [PATCH v2] drm/i915/dmabuf: avoid global wbinvd on dma-buf import
"Prabhakaran, Krishna" <[email protected]>
| Newsgroups | org.freedesktop.lists.intel-gfx,org.freedesktop.lists.dri-devel |
|---|---|
| Message-ID | <IA1PR11MB641816D15A8673AFD5667E22FAA42@IA1PR11MB6418.namprd11.prod.outlook.com> |
> I think we can bump this now for dg2? I think we treat dgfx as always > coherent with system memory. So maybe s/IS_DG1/IS_DGFX/ in a separate > patch? Pretty sure the rest of the driver is the same. Agreed. I'll send that as a separate patch, "drm/i915/dmabuf: skip acquire flush on all discrete GPUs", with you as Suggested-by. > Do we need the flush under the else here? If it's not placed in system > memory what is this flushing, from i915 pov? Right. i915_gem_dmabuf_attach() migrates the exporter to SMEM (INTEL_REGION_SMEM) before get_pages() runs, so dma_obj is always struct-page backed here and the else was effectively dead code; a wbinvd of device memory doesn't make sense from i915's point of view. Dropped in v3 -- the own-dma-buf branch is now just: drm_clflush_sg(dma_obj->mm.pages); Thanks Krishna