[PATCH v2 3/3] drm/i915/gvt: Move some MMIO definitions to reg.h

Yuan, Hang hang.yuan at intel.com
Thu Aug 2 05:33:10 UTC 2018


Reviewed-by: Hang Yuan <hang.yuan at intel.com>

> -----Original Message-----
> From: intel-gvt-dev [mailto:intel-gvt-dev-bounces at lists.freedesktop.org] On
> Behalf Of Zhenyu Wang
> Sent: Tuesday, July 31, 2018 11:02 AM
> To: intel-gvt-dev at lists.freedesktop.org
> Subject: [PATCH v2 3/3] drm/i915/gvt: Move some MMIO definitions to reg.h
> 
> To consolidate all gvt private MMIO definition in one place, this moves some
> not yet used in i915 to reg.h.
> 
> Signed-off-by: Zhenyu Wang <zhenyuw at linux.intel.com>
> ---
>  drivers/gpu/drm/i915/gvt/mmio_context.c | 13 -------------
>  drivers/gpu/drm/i915/gvt/reg.h          |  9 +++++++++
>  2 files changed, 9 insertions(+), 13 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/gvt/mmio_context.c
> b/drivers/gpu/drm/i915/gvt/mmio_context.c
> index 20be9a92600f..d20f2c9bda82 100644
> --- a/drivers/gpu/drm/i915/gvt/mmio_context.c
> +++ b/drivers/gpu/drm/i915/gvt/mmio_context.c
> @@ -37,19 +37,6 @@
>  #include "gvt.h"
>  #include "trace.h"
> 
> -/**
> - * Defined in Intel Open Source PRM.
> - * Ref: https://01.org/linuxgraphics/documentation/hardware-specification-
> prms
> - */
> -#define TRVATTL3PTRDW(i)	_MMIO(0x4de0 + (i)*4)
> -#define TRNULLDETCT		_MMIO(0x4de8)
> -#define TRINVTILEDETCT		_MMIO(0x4dec)
> -#define TRVADR			_MMIO(0x4df0)
> -#define TRTTE			_MMIO(0x4df4)
> -#define RING_EXCC(base)		_MMIO((base) + 0x28)
> -#define RING_GFX_MODE(base)	_MMIO((base) + 0x29c)
> -#define VF_GUARDBAND		_MMIO(0x83a4)
> -
>  #define GEN9_MOCS_SIZE		64
> 
>  /* Raw offset is appened to each line for convenience. */ diff --git
> a/drivers/gpu/drm/i915/gvt/reg.h b/drivers/gpu/drm/i915/gvt/reg.h index
> d4f7ce6dc1d7..60dcc6bb8425 100644
> --- a/drivers/gpu/drm/i915/gvt/reg.h
> +++ b/drivers/gpu/drm/i915/gvt/reg.h
> @@ -77,4 +77,13 @@
>  #define _RING_CTL_BUF_SIZE(ctl) (((ctl) & RB_TAIL_SIZE_MASK) + \
>  		I915_GTT_PAGE_SIZE)
> 
> +#define TRVATTL3PTRDW(i)	_MMIO(0x4de0 + (i) * 4)
> +#define TRNULLDETCT		_MMIO(0x4de8)
> +#define TRINVTILEDETCT		_MMIO(0x4dec)
> +#define TRVADR			_MMIO(0x4df0)
> +#define TRTTE			_MMIO(0x4df4)
> +#define RING_EXCC(base)		_MMIO((base) + 0x28)
> +#define RING_GFX_MODE(base)	_MMIO((base) + 0x29c)
> +#define VF_GUARDBAND		_MMIO(0x83a4)
> +
>  #endif
> --
> 2.18.0
> 
> _______________________________________________
> intel-gvt-dev mailing list
> intel-gvt-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gvt-dev


More information about the intel-gvt-dev mailing list