[Intel-gfx] [PATCH] drm/i915/gvt: set ring buffer size to default for guc submission

2017-02-15 Thread Chuanxiao Dong
When not using GuC submission, the ring buffer size for GVT context is 512KB which is the max size. When switching to GuC submission, the ring buffer size is required to be less than 16KB. So use the GVT context default ring buffer size if GuC submission is enabled. Signed-off-by: Chuanxiao Dong

[Intel-gfx] [PATCH v4] drm/i915/scheduler: add gvt notification for guc submission

2017-03-23 Thread Chuanxiao Dong
: kevin.t...@intel.com Cc: joonas.lahti...@linux.intel.com Cc: ch...@chris-wilson.co.uk Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/i915_guc_submission.c | 4 drivers/gpu/drm/i915/intel_lrc.c | 27 ++- drivers/gpu/dr

[Intel-gfx] [PATCH v2 2/2] drm/i915/scheduler: add gvt notification for guc

2017-03-28 Thread Chuanxiao Dong
...@intel.com Cc: joonas.lahti...@linux.intel.com Cc: ch...@chris-wilson.co.uk Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/i915_guc_submission.c | 4 drivers/gpu/drm/i915/intel_gvt.h | 12 drivers/gpu/drm/i915/intel_lrc.c

[Intel-gfx] [PATCH v2 1/2] drm/i915/scheduler: add gvt force-single-submission for guc

2017-03-28 Thread Chuanxiao Dong
) Cc: ch...@chris-wilson.co.uk Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/i915_guc_submission.c | 7 ++- drivers/gpu/drm/i915/intel_gvt.h | 11 +++ drivers/gpu/drm/i915/intel_lrc.c | 25 - 3 files c

[Intel-gfx] [PATCH v2 0/2] drm/i915/scheduler: add gvt force-single-submission and notification for guc

2017-03-28 Thread Chuanxiao Dong
GVT requires force-single-submission and notification when i915 using execlist submit, and these should be extended to GuC when i915 using GuC submit. Below two patches are used to implement this Chuanxiao Dong (2): drm/i915/scheduler: add gvt force-single-submission for guc drm/i915

[Intel-gfx] [PATCH 1/2] drm/i915/scheduler: add gvt force-single-submission for guc

2017-03-27 Thread Chuanxiao Dong
GVT needs single submission and cannot allow merge. So when GuC submitting a GVT request, the next one should be submitted to guc later until the previous one is completed. This is following the usage when using execlist mode submission. Cc: ch...@chris-wilson.co.uk Signed-off-by: Chuanxiao Dong

[Intel-gfx] [PATCH 0/2] drm/i915/scheduler: add gvt force-single-submission and notification for guc

2017-03-27 Thread Chuanxiao Dong
GVT requires force-single-submission and notification when i915 using execlist submit, and these should be extended to GuC when i915 using GuC submit. Below two patches are used to implement this Chuanxiao Dong (2): drm/i915/scheduler: add gvt force-single-submission for guc drm/i915

[Intel-gfx] [PATCH 2/2] drm/i915/scheduler: add gvt notification for guc

2017-03-27 Thread Chuanxiao Dong
...@intel.com Cc: joonas.lahti...@linux.intel.com Cc: ch...@chris-wilson.co.uk Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/i915_guc_submission.c | 4 drivers/gpu/drm/i915/intel_gvt.h | 13 + drivers/gpu/drm/i915/intel_lrc.c

[Intel-gfx] [PATCH v5] drm/i915/scheduler: add gvt notification for guc submission

2017-03-27 Thread Chuanxiao Dong
intel_gvt_notify_context_status to intel_gvt.h (Joonas) Cc: xiao.zh...@intel.com Cc: kevin.t...@intel.com Cc: joonas.lahti...@linux.intel.com Cc: ch...@chris-wilson.co.uk Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/i915_guc_submission.c | 4 drivers/gpu/drm/i915/intel

[Intel-gfx] [PATCH] drm/i915/scheduler: add gvt notification for guc submission

2017-03-19 Thread Chuanxiao Dong
GVT request needs a manual mmio load/restore. Before GuC submit a request, send notification to gvt for mmio loading. And after the GuC finished this GVT request, notify gvt again for mmio restore. This follows the usage when using execlists submission. Signed-off-by: Chuanxiao Dong <chuanxia

[Intel-gfx] [PATCH v2] drm/i915/scheduler: add gvt notification for guc submission

2017-03-20 Thread Chuanxiao Dong
of execlists_context_status_change for better understanding (ZhengXiao) Cc: xiao.zh...@intel.com Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/i915_guc_submission.c | 12 drivers/gpu/drm/i915/intel_lrc.c | 21 +++-- d

[Intel-gfx] [PATCH v3] drm/i915/scheduler: add gvt notification for guc submission

2017-03-22 Thread Chuanxiao Dong
of execlists_context_status_change for better understanding (ZhengXiao) v3: remove the comment as it is obvious and not friendly to the caller (Kevin) Cc: xiao.zh...@intel.com Cc: kevin.t...@intel.com Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/dr

[Intel-gfx] [PATCH v3 2/2] drm/i915/scheduler: add gvt notification for guc

2017-04-04 Thread Chuanxiao Dong
...@intel.com Cc: joonas.lahti...@linux.intel.com Cc: ch...@chris-wilson.co.uk Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/i915_guc_submission.c | 4 drivers/gpu/drm/i915/intel_gvt.h | 12 drivers/gpu/drm/i915/intel_lrc.c

[Intel-gfx] [PATCH v3 1/2] drm/i915/scheduler: add gvt force-single-submission for guc

2017-04-04 Thread Chuanxiao Dong
: keep the original code implementation (Chris) Cc: ch...@chris-wilson.co.uk Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/i915_gem_context.h| 13 + drivers/gpu/drm/i915/i915_guc_submission.c | 6 +- drivers/gpu/drm/i915/intel

[Intel-gfx] [PATCH v3 0/2] drm/i915/scheduler: add gvt force-single-submission and notification for guc

2017-04-04 Thread Chuanxiao Dong
GVT requires force-single-submission and notification when i915 using execlist submit, and these should be extended to GuC when i915 using GuC submit. Below two patches are used to implement this Chuanxiao Dong (2): drm/i915/scheduler: add gvt force-single-submission for guc drm/i915

[Intel-gfx] [PATCH 3/4] drm/i915/scheduler: add gvt force-single-submission for guc

2017-04-19 Thread Chuanxiao Dong
GVT needs single submission and cannot allow merge. So when GuC submitting a GVT request, the next one should be submitted to guc later until the previous one is completed. This is following the usage when using execlist mode submission. Cc: ch...@chris-wilson.co.uk Signed-off-by: Chuanxiao Dong

[Intel-gfx] [PATCH 4/4] drm/i915/scheduler: add gvt notification for guc

2017-04-19 Thread Chuanxiao Dong
...@intel.com Cc: joonas.lahti...@linux.intel.com Cc: ch...@chris-wilson.co.uk Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/i915_guc_submission.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/gpu/drm/i915/i915_guc_submission.c b/drivers/gpu/dr

[Intel-gfx] [PATCH 2/4] drm/i915: refactor gvt context notification

2017-04-19 Thread Chuanxiao Dong
to intel_gvt_notify_context_status(Chris) move intel_gvt_notify_context_status to intel_gvt.h(Joonas) Cc: xiao.zh...@intel.com Cc: kevin.t...@intel.com Cc: joonas.lahti...@linux.intel.com Cc: ch...@chris-wilson.co.uk Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/dr

[Intel-gfx] [PATCH 1/4] drm/i915: refactor gvt force-single-submission

2017-04-19 Thread Chuanxiao Dong
refactor gvt force-single-submission to proper files v1: make force-single-submission specific to gvt (Chris) keep the original code implementation (Chris) Cc: ch...@chris-wilson.co.uk Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/i915_gem_context.

[Intel-gfx] [PATCH v2] drm/i915/gvt: add enable_execlists check before enable gvt

2017-03-09 Thread Chuanxiao Dong
The GVT-g needs execlists to be enabled otherwise gvt should be disabled. Add a check for enable_execlists before enabling gvt. v2: use DRM_INFO in response to the user action Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/intel_gvt.c | 5 + 1 file c

[Intel-gfx] [PATCH] drm/i915/gvt: add enable_execlists check before enable gvt

2017-03-05 Thread Chuanxiao Dong
The GVT-g needs execlists to be enabled otherwise gvt should be disabled. Add a check for enable_execlists before enabling gvt. Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/intel_gvt.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/g

[Intel-gfx] [PATCH v2] drm/i915: Fix the kernel panic when using aliasing ppgtt

2017-07-07 Thread Chuanxiao Dong
The ppgtt should be get directly from i915_address_space *vm instead of vma->vm. v2: - add one more fix for bxt. (Chris) Fixes: 4a234c5fae16 ("drm/i915: pass the vma to insert_entries") Bugzilla:https://bugs.freedesktop.org/show_bug.cgi?id=101713 Signed-off-by: Chuanxiao Dong

[Intel-gfx] [PATCH] drm/i915: Fix the port submission race during engine reset in execlists mode

2017-07-19 Thread Chuanxiao Dong
: a1ef70e14453 ("drm/i915: Add support for per engine reset recovery") Cc: Michel Thierry <michel.thie...@intel.com> Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/i915_drv.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git

[Intel-gfx] [PATCH] drm/i915: Fix the kernel panic when using aliasing ppgtt

2017-07-07 Thread Chuanxiao Dong
The ppgtt should be get directly from i915_address_space *vm instead of vma->vm as in alias ppgtt case the vma->vm is not same with vm. Fixes: 4a234c5fae16 ("drm/i915: pass the vma to insert_entries") Bugzilla:https://bugs.freedesktop.org/show_bug.cgi?id=101713 Signed-off-by

[Intel-gfx] [PATCH] drm/i915: set initialised only when init_context callback is NULL

2017-05-11 Thread Chuanxiao Dong
initialised is fixup by the GVT shadow context as true to avoid the init from the host because it cannot take the settings from the host. Add a check to let host driver only overwrite it when the init callback is NULL Cc: Chris Wilson <ch...@chris-wilson.co.uk> Signed-off-by: Chuanxia

[Intel-gfx] [PATCH v2] drm/i915/gvt: disable GVT-g if host GuC submission is enabled

2017-05-09 Thread Chuanxiao Dong
Currently GVT-g cannot work properly when host GuC submission is enabled, so disable GVT in this case. v2: update the user message (Joonas) Cc: Zhenyu Wang <zhen...@linux.intel.com> Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/intel_gvt.c | 5 +

[Intel-gfx] [PATCH v2 1/3] drm/i915/gvt: Add gvt options sanitize function

2017-05-27 Thread Chuanxiao Dong
: Chris Wilson <ch...@chris-wilson.co.uk> Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/i915_drv.c | 2 ++ drivers/gpu/drm/i915/intel_gvt.c | 36 ++-- drivers/gpu/drm/i915/intel_gvt.h | 5 + 3 files changed,

[Intel-gfx] [PATCH v2 3/3] drm/i915/gvt: Return -EIO if host GuC submission is enabled when loading GVT-g

2017-05-27 Thread Chuanxiao Dong
co.uk> Cc: Joonas Lahtinen <joonas.lahti...@linux.intel.com> Cc: Chris Wilson <ch...@chris-wilson.co.uk> Cc: Zhenyu Wang <zhen...@linux.intel.com> Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/intel_gvt.c | 5 + 1 file changed, 5

[Intel-gfx] [PATCH v2 2/3] drm/i915/gvt: Return -EIO if host enable_execlists not enabled when loading GVT-g

2017-05-27 Thread Chuanxiao Dong
nas.lahti...@linux.intel.com> Cc: Joonas Lahtinen <joonas.lahti...@linux.intel.com> Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/intel_gvt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_gvt.

[Intel-gfx] [PATCH v2 0/3] drm/i915/gvt: GVT-g options sanitize series

2017-05-27 Thread Chuanxiao Dong
In this series, options sanitize API is added for GVT-g, and GVT-g init will fail with -EIO if detected incompatible i915 parameters. Chuanxiao Dong (3): drm/i915/gvt: Add gvt options sanitize function drm/i915/gvt: Return -EIO if host enable_execlists not enabled when loading GVT-g drm

[Intel-gfx] [PATCH 0/3] drm/i915/gvt: GVT-g options sanitize series

2017-05-25 Thread Chuanxiao Dong
In this series, options sanitize API is added for GVT-g, and GVT-g init will fail with -EIO if detected incompatible i915 parameters. Chuanxiao Dong (3): drm/i915/gvt: Add gvt options sanitize function drm/i915/gvt: Return -EIO if host enable_execlists not enabled when loading GVT-g drm

[Intel-gfx] [PATCH 3/3] drm/i915/gvt: Return -EIO if host GuC submission is enabled when loading GVT-g

2017-05-25 Thread Chuanxiao Dong
x.intel.com> Cc: Chris Wilson <ch...@chris-wilson.co.uk> Cc: Zhenyu Wang <zhen...@linux.intel.com> Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/intel_gvt.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/gpu/drm/i91

[Intel-gfx] [PATCH 1/3] drm/i915/gvt: Add gvt options sanitize function

2017-05-25 Thread Chuanxiao Dong
The intel_gvt_sanitize_options will sanitize the GVT-g related options before doing GVT-g init. Suggested-by: Joonas Lahtinen <joonas.lahti...@linux.intel.com> Cc: Joonas Lahtinen <joonas.lahti...@linux.intel.com> Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- dr

[Intel-gfx] [PATCH 2/3] drm/i915/gvt: Return -EIO if host enable_execlists not enabled when loading GVT-g

2017-05-25 Thread Chuanxiao Dong
GVT-g relies on the enable_execlists parameter in i915. If this option is not enabled for GVT-g, should return -EIO to make i915 driver loading failed. Suggested-by: Joonas Lahtinen <joonas.lahti...@linux.intel.com> Cc: Joonas Lahtinen <joonas.lahti...@linux.intel.com> Signed-off-b

[Intel-gfx] [PATCH] drm/i915/gvt: disable GVT-g if host GuC submission is enabled

2017-05-02 Thread Chuanxiao Dong
Currently GVT-g cannot work properly when host GuC submission is enabled, so disable GVT in this case. Cc: Zhenyu Wang <zhen...@linux.intel.com> Signed-off-by: Chuanxiao Dong <chuanxiao.d...@intel.com> --- drivers/gpu/drm/i915/intel_gvt.c | 5 + 1 file changed, 5 insertions(+)