diff options
author | Thomas Zimmermann <tzimmermann@suse.de> | 2019-12-03 09:38:17 +0100 |
---|---|---|
committer | Thomas Zimmermann <tzimmermann@suse.de> | 2020-01-06 13:46:03 +0100 |
commit | 987073278624738573a845c85c4b0db6faaf7be0 (patch) | |
tree | 841437d191bcba6491fb4a5cf90e7d118b2d3a2e /drivers/gpu/drm/mgag200 | |
parent | 3e10d2ffd245f996c36f87b0a8027a719e6135c3 (diff) | |
download | linux-987073278624738573a845c85c4b0db6faaf7be0.tar.bz2 |
drm/vram: Support scanline alignment for dumb buffers
Adding the pitch alignment as an argument to
drm_gem_vram_fill_create_dumb() allows to align scanlines to certain
offsets. A value of 0 disables scanline pitches.
v3:
* only do power-of-2 test if pitch_align given; fails otherwise
* mgag200: call drm_gem_vram_fill_create_dumb() with pitch_align
v2:
* split of patch from related hibmc changes
* test if scanline pitch is power of 2
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Acked-by: Sam Ravnborg <sam@ravnborg.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20191203083819.6643-4-tzimmermann@suse.de
Diffstat (limited to 'drivers/gpu/drm/mgag200')
-rw-r--r-- | drivers/gpu/drm/mgag200/mgag200_drv.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/mgag200/mgag200_drv.c b/drivers/gpu/drm/mgag200/mgag200_drv.c index 9f4f5f071add..3473e9e9a20d 100644 --- a/drivers/gpu/drm/mgag200/mgag200_drv.c +++ b/drivers/gpu/drm/mgag200/mgag200_drv.c @@ -121,7 +121,7 @@ int mgag200_driver_dumb_create(struct drm_file *file, pg_align = PFN_UP(mdev->mc.vram_size); return drm_gem_vram_fill_create_dumb(file, dev, &dev->vram_mm->bdev, - pg_align, false, args); + pg_align, 0, false, args); } static struct drm_driver driver = { |