All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Hellstrom <thellstrom@vmware.com>
To: airlied@gmail.com, Dave Airlie <airlied@redhat.com>
Cc: Thomas Hellstrom <thellstrom@vmware.com>,
	dri-devel@lists.freedesktop.org
Subject: Re: [PATCH 1/8][RESEND] vmwgfx: Use the revised fifo hw version register when	present
Date: Thu, 15 Dec 2011 13:29:14 +0100	[thread overview]
Message-ID: <4EE9E81A.2060302@vmware.com> (raw)
In-Reply-To: <1322482755-6925-1-git-send-email-thellstrom@vmware.com>

Dave,

Please pull this series into drm-fixes for 3.2!

Thanks,
Thomas



On 11/28/2011 01:19 PM, Thomas Hellstrom wrote:
> The driver implements the needed resource management required
> to use that register.
>
> Signed-off-by: Thomas Hellstrom<thellstrom@vmware.com>
> Reviewed-by: Jakob Bornecrantz<jakob@vmware.com>
> ---
>   drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c  |    8 +++++++-
>   drivers/gpu/drm/vmwgfx/vmwgfx_ioctl.c |    8 +++++++-
>   2 files changed, 14 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c b/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c
> index 03bbc2a..a0c2f12 100644
> --- a/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c
> +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c
> @@ -33,6 +33,7 @@ bool vmw_fifo_have_3d(struct vmw_private *dev_priv)
>   {
>   	__le32 __iomem *fifo_mem = dev_priv->mmio_virt;
>   	uint32_t fifo_min, hwversion;
> +	const struct vmw_fifo_state *fifo =&dev_priv->fifo;
>
>   	if (!(dev_priv->capabilities&  SVGA_CAP_EXTENDED_FIFO))
>   		return false;
> @@ -41,7 +42,12 @@ bool vmw_fifo_have_3d(struct vmw_private *dev_priv)
>   	if (fifo_min<= SVGA_FIFO_3D_HWVERSION * sizeof(unsigned int))
>   		return false;
>
> -	hwversion = ioread32(fifo_mem + SVGA_FIFO_3D_HWVERSION);
> +	hwversion = ioread32(fifo_mem +
> +			     ((fifo->capabilities&
> +			       SVGA_FIFO_CAP_3D_HWVERSION_REVISED) ?
> +			      SVGA_FIFO_3D_HWVERSION_REVISED :
> +			      SVGA_FIFO_3D_HWVERSION));
> +
>   	if (hwversion == 0)
>   		return false;
>
> diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_ioctl.c b/drivers/gpu/drm/vmwgfx/vmwgfx_ioctl.c
> index 3f63435..a9e2193 100644
> --- a/drivers/gpu/drm/vmwgfx/vmwgfx_ioctl.c
> +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_ioctl.c
> @@ -58,8 +58,14 @@ int vmw_getparam_ioctl(struct drm_device *dev, void *data,
>   	case DRM_VMW_PARAM_FIFO_HW_VERSION:
>   	{
>   		__le32 __iomem *fifo_mem = dev_priv->mmio_virt;
> -
> -		param->value = ioread32(fifo_mem + SVGA_FIFO_3D_HWVERSION);
> +		const struct vmw_fifo_state *fifo =&dev_priv->fifo;
> +
> +		param->value =
> +			ioread32(fifo_mem +
> +				 ((fifo->capabilities&
> +				   SVGA_FIFO_CAP_3D_HWVERSION_REVISED) ?
> +				  SVGA_FIFO_3D_HWVERSION_REVISED :
> +				  SVGA_FIFO_3D_HWVERSION));
>   		break;
>   	}
>   	default:
>    

      parent reply	other threads:[~2011-12-15 12:32 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-28 12:19 [PATCH 1/8] vmwgfx: Use the revised fifo hw version register when present Thomas Hellstrom
2011-11-28 12:19 ` [PATCH 2/8] vmwgfx: Remove dmabuf check in present ioctl Thomas Hellstrom
2011-11-28 12:19 ` [PATCH 3/8] vmwgfx: Refactor cursor update Thomas Hellstrom
2011-11-28 12:19 ` [PATCH 4/8] vmwgfx: Add helper function to get surface or dmabuf Thomas Hellstrom
2011-11-28 12:19 ` [PATCH 5/8] vmwgfx: Refactor kms code to use vmw_user_lookup_handle helper Thomas Hellstrom
2011-11-28 12:19 ` [PATCH 6/8] vmwgfx: Do better culling of presents Thomas Hellstrom
2011-11-28 12:19 ` [PATCH 7/8] vmwgfx: Resend the cursor after legacy modeset Thomas Hellstrom
2011-11-28 12:19 ` [PATCH 8/8] vmwgfx: Clip cliprects against screen boundaries in present and dirty Thomas Hellstrom
2011-12-15 12:29 ` Thomas Hellstrom [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4EE9E81A.2060302@vmware.com \
    --to=thellstrom@vmware.com \
    --cc=airlied@gmail.com \
    --cc=airlied@redhat.com \
    --cc=dri-devel@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.