From: Frediano Ziglio <fziglio@redhat.com>
To: Gerd Hoffmann <kraxel@redhat.com>
Cc: dri-devel@lists.freedesktop.org,
David Airlie <airlied@redhat.com>,
David Airlie <airlied@linux.ie>,
"open list:DRM DRIVER FOR QXL VIRTUAL GPU"
<spice-devel@lists.freedesktop.org>,
open list <linux-kernel@vger.kernel.org>,
"open list:DRM DRIVER FOR QXL VIRTUAL GPU"
<virtualization@lists.linux-foundation.org>
Subject: Re: [Spice-devel] [PATCH 1/3] drm/qxl: allow both PRIV and VRAM placement for QXL_GEM_DOMAIN_SURFACE
Date: Thu, 6 Dec 2018 05:55:58 -0500 (EST) [thread overview]
Message-ID: <1897496108.48579647.1544093758850.JavaMail.zimbra@redhat.com> (raw)
In-Reply-To: <20181206104638.23330-2-kraxel@redhat.com>
> qxl surfaces (used for framebuffers and gem objects) can live in both
> VRAM and PRIV ttm domains. Update placement setup to include both. Put
> PRIV first in the list so it is preferred, so VRAM will have more room
> for objects which must be allocated there.
>
> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
I remember these kind of changes in the past made migration
fails. I proposed similar patches years ago and they were rejected
for these reasons. Why now they are safe?
Looks like we are improving QXL, so that means we are actively working
on it. Should we not then thinking about moving feature in the proper
places (like spice-server for atomic mode setting instead of implementin
work around) ??
> ---
> drivers/gpu/drm/qxl/qxl_object.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/qxl/qxl_object.c
> b/drivers/gpu/drm/qxl/qxl_object.c
> index 91f3bbc73e..f7f9f4f4fe 100644
> --- a/drivers/gpu/drm/qxl/qxl_object.c
> +++ b/drivers/gpu/drm/qxl/qxl_object.c
> @@ -58,10 +58,10 @@ void qxl_ttm_placement_from_domain(struct qxl_bo *qbo,
> u32 domain, bool pinned)
>
> qbo->placement.placement = qbo->placements;
> qbo->placement.busy_placement = qbo->placements;
> - if (domain == QXL_GEM_DOMAIN_VRAM)
> - qbo->placements[c++].flags = TTM_PL_FLAG_CACHED | TTM_PL_FLAG_VRAM |
> pflag;
> if (domain == QXL_GEM_DOMAIN_SURFACE)
> qbo->placements[c++].flags = TTM_PL_FLAG_CACHED | TTM_PL_FLAG_PRIV |
> pflag;
> + if (domain == QXL_GEM_DOMAIN_SURFACE || domain == QXL_GEM_DOMAIN_VRAM)
> + qbo->placements[c++].flags = TTM_PL_FLAG_CACHED | TTM_PL_FLAG_VRAM |
> pflag;
> if (domain == QXL_GEM_DOMAIN_CPU)
> qbo->placements[c++].flags = TTM_PL_MASK_CACHING | TTM_PL_FLAG_SYSTEM |
> pflag;
> if (!c)
Frediano
next prev parent reply other threads:[~2018-12-06 10:56 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20181206104638.23330-1-kraxel@redhat.com>
2018-12-06 10:46 ` [PATCH 1/3] drm/qxl: allow both PRIV and VRAM placement for QXL_GEM_DOMAIN_SURFACE Gerd Hoffmann
2018-12-06 10:55 ` Frediano Ziglio [this message]
2018-12-06 11:34 ` [Spice-devel] " Gerd Hoffmann
2018-12-06 14:39 ` Frediano Ziglio
2018-12-07 8:26 ` Gerd Hoffmann
2018-12-06 10:46 ` [PATCH 2/3] drm/qxl: use QXL_GEM_DOMAIN_SURFACE for shadow bo Gerd Hoffmann
2018-12-06 10:46 ` [PATCH 3/3] drm/qxl: use QXL_GEM_DOMAIN_SURFACE for dumb gem objects Gerd Hoffmann
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=1897496108.48579647.1544093758850.JavaMail.zimbra@redhat.com \
--to=fziglio@redhat.com \
--cc=airlied@linux.ie \
--cc=airlied@redhat.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=kraxel@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=spice-devel@lists.freedesktop.org \
--cc=virtualization@lists.linux-foundation.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox