[PATCH v2] drm/i915/gvt: Add runtime_pm get/put to proctect MMIO accessing

Zhenyu Wang zhenyuw at linux.intel.com
Thu Jun 1 01:46:02 UTC 2017


On 2017.05.31 09:51:24 +0000, Dong, Chuanxiao wrote:
> 
> Just realized that, the gtt write operations may come from the emulated_gtt_mmio_write from guest thus gvt cannot know when the set of ggtt operations are done.

yeah, in that gtt write trap we can't avoid it but better to do invalidate after gtt_mmio_write.

> 
> And adding runtime_pm_get/put just around the I915_WRITE won't cause the overkill because i915 are using the autosuspend runtime PM which has a latency (probably 10s) to suspend after called runtime_pm_put, the i915 HW can only to suspend if there is no more runtime_pm_get to be called in these 10s. So actually even we just call runtime_pm_get/runtime_pm_put in emulate_mmio_write/read function, there won't be overkill.
> 

I don't mean overkill for runtime pm but for that flush register hw write, e.g in reset ggtt
we should really just do once after all writes. So for that better to move that outside of write
pte function.

-- 
Open Source Technology Center, Intel ltd.

$gpg --keyserver wwwkeys.pgp.net --recv-keys 4D781827
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/intel-gvt-dev/attachments/20170601/89603de0/attachment.sig>


More information about the intel-gvt-dev mailing list