linux/drivers/gpu/drm/i915/gvt
Michel Thierry 0b29c75a01 drm/i915/lrc: Clarify the format of the context image
Not only the context image consist of two parts (the PPHWSP, and the
logical context state), but we also allocate a header at the start of
for sharing data with GuC. Thus every lrc looks like this:

  | [guc]          | [hwsp] [logical state] |
  |<- our header ->|<- context image      ->|

So far, we have oversimplified whenever we use each of these parts of the
context, just because the GuC header happens to be in page 0, and the
(PP)HWSP is in page 1. But this had led to using the same define for more
than one meaning (as a page index in the lrc and as 1 page).

This patch adds defines for the GuC shared page, the PPHWSP page and the
start of the logical state. It also updated the places where the old
define was being used. Since we are not changing the size (or format) of
the context, there are no functional changes.

v2: Use PPHWSP index for hws again.

Suggested-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Michel Thierry <michel.thierry@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>
Cc: Oscar Mateo <oscar.mateo@intel.com>
Cc: intel-gvt-dev@lists.freedesktop.org
Link: http://patchwork.freedesktop.org/patch/msgid/20170712193032.27080-1-michel.thierry@intel.com
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Link: https://patchwork.freedesktop.org/patch/msgid/20170913085605.18299-1-chris@chris-wilson.co.uk
2017-09-13 15:02:15 +01:00
..
aperture_gm.c drm/i915: Add interface to reserve fence registers for vGPU 2017-09-04 16:34:59 +01:00
cfg_space.c drm/i915/gvt: Add support for PCIe extended configuration space 2017-09-08 14:21:16 +08:00
cmd_parser.c drm/i915/gvt: Refine error handling for perform_bb_shadow 2017-09-08 14:21:15 +08:00
cmd_parser.h drm/i915/gvt: Factor out scan and shadow from workload dispatch 2017-08-10 10:26:06 +08:00
debug.h drm/i915/gvt: replace the gvt_err with gvt_vgpu_err 2017-03-17 16:46:45 +08:00
display.c Merge tag 'drm-intel-next-2017-08-18' of git://anongit.freedesktop.org/git/drm-intel into drm-next 2017-08-22 10:03:07 +10:00
display.h drm/i915/gvt: add resolution definition for vGPU type 2017-02-24 13:25:18 +08:00
edid.c drm/i915/gvt: Fix guest fail to read EDID leading to black guest console issue. 2017-03-21 10:50:02 +08:00
edid.h drm/i915/gvt: Fix static checker warning on intel_gvt_i2c_handle_aux_ch_write() 2016-11-14 18:06:44 +08:00
execlist.c drm/i915/gvt: Refine error handling for prepare_execlist_workload 2017-09-08 14:21:14 +08:00
execlist.h drm/i915/gvt: fix crash in vgpu_reset_execlist 2016-11-14 18:06:43 +08:00
firmware.c drm/i915/gvt: Initialize MMIO Block with HW state 2017-08-04 17:39:41 +08:00
gtt.c drm/i915/gvt: Refine error handling for intel_vgpu_pin_mm 2017-09-08 14:21:15 +08:00
gtt.h drm/i915/gvt: Refine the intel_vgpu_reset_gtt reset function 2017-08-10 10:26:10 +08:00
gvt.c drm/i915/gvt: Add support for PCIe extended configuration space 2017-09-08 14:21:16 +08:00
gvt.h drm/i915/gvt: Add support for PCIe extended configuration space 2017-09-08 14:21:16 +08:00
handlers.c Merge tag 'drm-intel-next-2017-08-18' of git://anongit.freedesktop.org/git/drm-intel into drm-next 2017-08-22 10:03:07 +10:00
hypercall.h drm/i915/gvt: remove detect_host() MPT hook 2017-02-07 17:21:44 +08:00
interrupt.c drm/i915/gvt: Change flood gvt dmesg into trace 2017-06-08 13:59:16 +08:00
interrupt.h drm/i915/gvt: vGPU command scanner 2016-10-14 18:15:25 +08:00
kvmgt.c drm/i915/gvt: Add support for PCIe extended configuration space 2017-09-08 14:21:16 +08:00
Makefile drm/i915/gvt: remove redundant -Wall 2017-06-08 13:59:18 +08:00
mmio.c drm/i915/gvt: Add emulation for BAR2 (aperture) with normal file RW approach 2017-09-08 14:21:13 +08:00
mmio.h drm/i915/gvt: Refine virtual reset function 2017-06-08 13:59:21 +08:00
mpt.h drm/i915/gvt: Change flood gvt dmesg into trace 2017-06-08 13:59:16 +08:00
opregion.c drm/i915/gvt: replace the gvt_err with gvt_vgpu_err 2017-03-17 16:46:45 +08:00
reg.h drm/i915/gvt: cleanup opregion memory allocation code 2017-01-09 11:11:32 +08:00
render.c drm/i915/gvt: Optimize ring siwtch 2x faster again by light weight mmio access wrapper 2017-08-10 10:26:06 +08:00
render.h drm/i915/gvt: implement per-vm mmio switching optimization 2017-06-08 13:59:15 +08:00
sched_policy.c Merge tag 'gvt-next-2017-06-08' of https://github.com/01org/gvt-linux into drm-intel-next-queued 2017-06-16 10:03:01 +03:00
sched_policy.h drm/i915/gvt: use hrtimer replace delayed_work in scheduler 2017-03-30 13:32:24 +08:00
scheduler.c drm/i915/lrc: Clarify the format of the context image 2017-09-13 15:02:15 +01:00
scheduler.h drm/i915/gvt: Add error handling for intel_gvt_scan_and_shadow_workload 2017-09-08 14:21:14 +08:00
trace_points.c drm/i915/gvt: trace stub 2016-10-14 18:12:11 +08:00
trace.h drm/i915/gvt: Change flood gvt dmesg into trace 2017-06-08 13:59:16 +08:00
vgpu.c Merge tag 'drm-intel-next-2017-08-18' of git://anongit.freedesktop.org/git/drm-intel into drm-next 2017-08-22 10:03:07 +10:00