From: Thomas Zimmermann <tzimmermann@suse.de>
To: airlied@linux.ie, daniel@ffwll.ch, sam@ravnborg.org,
christian.koenig@amd.com, kraxel@redhat.com
Cc: Thomas Zimmermann <tzimmermann@suse.de>, dri-devel@lists.freedesktop.org
Subject: [PATCH 1/2] drm/vram-helper: Don't put new BOs into VRAM
Date: Wed, 22 Apr 2020 16:40:54 +0200 [thread overview]
Message-ID: <20200422144055.27801-2-tzimmermann@suse.de> (raw)
In-Reply-To: <20200422144055.27801-1-tzimmermann@suse.de>
Most drivers that use VRAM helpers have only a few MiB of framebuffer
memory available. To reduce fragmentation, new BOs are now put into
system memory by default. Only pin operations are allowed to move BOs
into VRAM.
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
---
drivers/gpu/drm/drm_gem_vram_helper.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/drm_gem_vram_helper.c b/drivers/gpu/drm/drm_gem_vram_helper.c
index 8b2d5c945c95c..5d5bfb38bbed4 100644
--- a/drivers/gpu/drm/drm_gem_vram_helper.c
+++ b/drivers/gpu/drm/drm_gem_vram_helper.c
@@ -197,7 +197,7 @@ static int drm_gem_vram_init(struct drm_device *dev,
acc_size = ttm_bo_dma_acc_size(bdev, size, sizeof(*gbo));
gbo->bo.bdev = bdev;
- drm_gem_vram_placement(gbo, TTM_PL_FLAG_VRAM | TTM_PL_FLAG_SYSTEM);
+ drm_gem_vram_placement(gbo, TTM_PL_FLAG_SYSTEM);
ret = ttm_bo_init(bdev, &gbo->bo, size, ttm_bo_type_device,
&gbo->placement, pg_align, false, acc_size,
--
2.26.0
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
next prev parent reply other threads:[~2020-04-22 14:41 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-22 14:40 [PATCH 0/2] drm/vram-helper: Reduce memory fragmentation Thomas Zimmermann
2020-04-22 14:40 ` Thomas Zimmermann [this message]
2020-04-22 14:40 ` [PATCH 2/2] drm/vram-helper: Alternate between bottom-up and top-down placement Thomas Zimmermann
2020-04-23 11:18 ` Gerd Hoffmann
2020-04-23 12:44 ` Thomas Zimmermann
2020-04-23 13:57 ` Gerd Hoffmann
2020-04-23 15:04 ` Christian König
2020-04-24 6:27 ` Thomas Zimmermann
2020-04-24 6:56 ` Christian König
2020-04-24 7:03 ` Thomas Zimmermann
2020-04-24 7:39 ` Christian König
2020-04-24 6:59 ` Thomas Zimmermann
2020-04-24 9:38 ` Gerd Hoffmann
2020-04-28 15:16 ` Thomas Zimmermann
2020-04-29 7:25 ` Gerd Hoffmann
2020-04-29 9:11 ` Christian König
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=20200422144055.27801-2-tzimmermann@suse.de \
--to=tzimmermann@suse.de \
--cc=airlied@linux.ie \
--cc=christian.koenig@amd.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=kraxel@redhat.com \
--cc=sam@ravnborg.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