[PATCH 12/12] drm/cirrus: advertise DRIVER_ATOMIC

2017-09-08 Thread Varad Gautam
From: Varad Gautam allow userspace to use atomic ioctls. we now pass the following tests when running with cirrus.bpp=32: igt/kms_atomic_transition: plane-all-transition plane-use-after-nonblocking-unbind plane-all-modeset-transition plane-toggle-modeset-transition 1x

[PATCH 11/12] drm/cirrus: implement atomic hardware cursor support

2017-09-08 Thread Varad Gautam
From: Varad Gautam This enables cursor plane on cirrus. It only supports ARGB 8-bit cursors from userspace, and downconverts them to 1-bit black and white with masking, which is all cirrus hardware can support. Only cursors with size 32x32 or 64x64 will work. initial non-atomic version

[PATCH 09/12] drm/cirrus: send vblank on crtc atomic_flush

2017-09-08 Thread Varad Gautam
From: Varad Gautam the hardware does not provide interrupts on vblank, so we just send a fake vblank event on atomic_flush. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_mode.c | 18 ++ 1 file changed, 18 insertions(+) diff --git a/drivers/gpu/drm/cirrus

[PATCH 10/12] drm/cirrus: use atomic handlers for plane and crtc

2017-09-08 Thread Varad Gautam
From: Varad Gautam move from transition helpers to actual atomic handlers. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_mode.c | 30 +++--- 1 file changed, 3 insertions(+), 27 deletions(-) diff --git a/drivers/gpu/drm/cirrus/cirrus_mode.c b/drivers

[PATCH 08/12] drm/cirrus: use atomic transition helpers for plane and crtc

2017-09-08 Thread Varad Gautam
From: Varad Gautam split the driver to fit into atomic semantics, and switch to using the atomic transition layer helpers for legacy modesetting. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_drv.h | 1 + drivers/gpu/drm/cirrus/cirrus_main.c | 3 + drivers/gpu/drm/cirrus

[PATCH 07/12] drm/cirrus: use universal plane interfaces for primary plane

2017-09-08 Thread Varad Gautam
From: Varad Gautam cirrus exposes one legacy primary plane tied to the crtc. convert this to use the universal planes interface in preparation for atomic. v2: avoid early plane cleanup to fix faulty error handling. (krisman) Signed-off-by: Varad Gautam Reviewed-by: Gabriel Krisman Bertazi

[PATCH 01/12] drm/cirrus: split out bo unpinning from cirrus_bo_push_sysram

2017-09-08 Thread Varad Gautam
From: Varad Gautam add a cirrus_bo_unpin call, and move bo_{reserve,unreserve} operations to bo_{pin,unpin} to ensure correct pinning/unpinning and simplify the call sequence. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_drv.h | 1 + drivers/gpu/drm/cirrus/cirrus_mode.c

[PATCH 03/12] drm/cirrus: do not disable outputs on fbdev init for atomic.

2017-09-08 Thread Varad Gautam
From: Varad Gautam drm_helper_disable_unused_functions should not be called by atomic drivers, so disable it for later patches. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_fbdev.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/gpu/drm/cirrus/cirrus_fbdev.c b

[PATCH 06/12] drm/cirrus: implement PRIME export for cirrus

2017-09-08 Thread Varad Gautam
From: Zach Reizner This patch implements PRIME export, but not import for cirrus. initially reviewed at: https://chromium-review.googlesource.com/229688 https://chromium-review.googlesource.com/339057 Signed-off-by: Zach Reizner Signed-off-by: Stphane Marchesin Signed-off-by: Varad Gautam

[PATCH 05/12] drm/cirrus: hardcode vram size

2017-09-08 Thread Varad Gautam
From: Zach Reizner There is no reliable way of detecting actual VRAM size, which is important in the case of cirrus because cursor data is always stored in the last 16K of VRAM. Because qemu effectivaly hardcodes 4MB but reports 32MB, we hardcode 4MB in the cirrus driver to ensure the cursor work

[PATCH 04/12] drm/cirrus: initialize start and size fields

2017-09-08 Thread Varad Gautam
From: Dominik Behr initialize start and size fields in fb info so user space drivers like fbdev can map the memory cherry-pick from 3.14 to 3.18 kernel to let VMtest pass dmesg now shows proper size and fb start initially reviewed for chromiumos at: https://chromium-review.googlesource.com/167

[PATCH 02/12] drm/cirrus: add drm_read to cirrus_driver_fops

2017-09-08 Thread Varad Gautam
From: Varad Gautam allow reading the drm file from userspace. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_drv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/cirrus/cirrus_drv.c b/drivers/gpu/drm/cirrus/cirrus_drv.c index 69c4e352dd78..452059780ddc

[PATCH 00/12] atomic modesetting for cirrus v2

2017-09-08 Thread Varad Gautam
): drm/cirrus: initialize start and size fields Varad Gautam (9): drm/cirrus: split out bo unpinning from cirrus_bo_push_sysram drm/cirrus: add drm_read to cirrus_driver_fops drm/cirrus: do not disable outputs on fbdev init for atomic. drm/cirrus: use universal plane interfaces for primary

Re: [PATCH 01/14] drm/cirrus: split out bo unpinning from cirrus_bo_push_sysram

2017-09-05 Thread Varad Gautam
Hi Gabriel, On Mon, Sep 4, 2017 at 4:11 PM, Gabriel Krisman Bertazi wrote: > Varad Gautam writes: > > >> int cirrus_bo_push_sysram(struct cirrus_bo *bo) >> { >> int i, ret; >> - if (!bo->pin_count) { >> + >> + ret

Re: [PATCH 06/14] drm/cirrus: Use 32bpp by default

2017-08-23 Thread Varad Gautam
Hi Matthew, On Sat, Aug 19, 2017 at 2:02 PM, Matthew Garrett wrote: > On Fri, Aug 18, 2017 at 09:19:11PM +0530, Varad Gautam wrote: >> From: Stéphane Marchesin >> >> initially reviewed for ChromiumOS at: >> https://chromium-review.googlesource.com/339093 >>

Re: [PATCH 02/14] drm/cirrus: unregister connector on destroy

2017-08-18 Thread Varad Gautam
properly b) hot-unplug. Doesn't apply to cirrus." [1] http://www.mail-archive.com/dri-devel@lists.freedesktop.org/msg191644.html Thanks, Varad On Fri, Aug 18, 2017 at 9:19 PM, Varad Gautam wrote: > From: Varad Gautam > > add missing unregister call on connector destroy. >

[PATCH 13/14] drm/cirrus: implement atomic hardware cursor support

2017-08-18 Thread Varad Gautam
From: Varad Gautam This enables cursor plane on cirrus. It only supports ARGB 8-bit cursors from userspace, and downconverts them to 1-bit black and white with masking, which is all cirrus hardware can support. Only cursors with size 32x32 or 64x64 will work. initial non-atomic version

[PATCH 14/14] drm/cirrus: advertise DRIVER_ATOMIC

2017-08-18 Thread Varad Gautam
From: Varad Gautam allow userspace to use atomic ioctls. we now pass the following tests: igt/kms_atomic_transition: plane-all-transition plane-use-after-nonblocking-unbind plane-all-modeset-transition plane-toggle-modeset-transition 1x-modeset-transitions 1x-modeset

[PATCH 11/14] drm/cirrus: send vblank on crtc atomic_flush

2017-08-18 Thread Varad Gautam
From: Varad Gautam the hardware does not provide interrupts on vblank, so we just send a fake vblank event on atomic_flush. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_mode.c | 18 ++ 1 file changed, 18 insertions(+) diff --git a/drivers/gpu/drm/cirrus

[PATCH 12/14] drm/cirrus: use atomic handlers for plane and crtc

2017-08-18 Thread Varad Gautam
From: Varad Gautam move from transition helpers to actual atomic handlers. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_mode.c | 31 --- 1 file changed, 4 insertions(+), 27 deletions(-) diff --git a/drivers/gpu/drm/cirrus/cirrus_mode.c b/drivers

[PATCH 10/14] drm/cirrus: use atomic transition helpers for plane and crtc

2017-08-18 Thread Varad Gautam
From: Varad Gautam split the driver to fit into atomic semantics, and switch to using the atomic transition layer helpers for legacy modesetting. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_drv.h | 1 + drivers/gpu/drm/cirrus/cirrus_main.c | 3 + drivers/gpu/drm/cirrus

[PATCH 09/14] drm/cirrus: use universal plane interfaces for primary plane

2017-08-18 Thread Varad Gautam
From: Varad Gautam cirrus exposes one legacy primary plane tied to the crtc. convert this to use the universal planes interface in preparation for atomic. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_mode.c | 44 ++-- 1 file changed, 42

[PATCH 08/14] drm/cirrus: implement PRIME export for cirrus

2017-08-18 Thread Varad Gautam
From: Zach Reizner This patch implements PRIME export, but not import for cirrus. initially reviewed at: https://chromium-review.googlesource.com/229688 https://chromium-review.googlesource.com/339057 Signed-off-by: Zach Reizner Signed-off-by: Stphane Marchesin Signed-off-by: Varad Gautam

[PATCH 06/14] drm/cirrus: Use 32bpp by default

2017-08-18 Thread Varad Gautam
From: Stéphane Marchesin initially reviewed for ChromiumOS at: https://chromium-review.googlesource.com/339093 Signed-off-by: Stéphane Marchesin --- drivers/gpu/drm/cirrus/cirrus_drv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/cirrus/cirrus_drv.c b

[PATCH 07/14] drm/cirrus: hardcode vram size

2017-08-18 Thread Varad Gautam
From: Zach Reizner There is no reliable way of detecting actual VRAM size, which is important in the case of cirrus because cursor data is always stored in the last 16K of VRAM. Because qemu effectivaly hardcodes 4MB but reports 32MB, we hardcode 4MB in the cirrus driver to ensure the cursor work

[PATCH 05/14] drm/cirrus: initialize start and size fields

2017-08-18 Thread Varad Gautam
From: Dominik Behr initialize start and size fields in fb info so user space drivers like fbdev can map the memory cherry-pick from 3.14 to 3.18 kernel to let VMtest pass dmesg now shows proper size and fb start initially reviewed for chromiumos at: https://chromium-review.googlesource.com/167

[PATCH 03/14] drm/cirrus: add drm_read to cirrus_driver_fops

2017-08-18 Thread Varad Gautam
From: Varad Gautam allow reading the drm file from userspace. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_drv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/cirrus/cirrus_drv.c b/drivers/gpu/drm/cirrus/cirrus_drv.c index d893ea21a359..bae34f5c2c02

[PATCH 04/14] drm/cirrus: do not disable outputs on fbdev init for atomic.

2017-08-18 Thread Varad Gautam
From: Varad Gautam drm_helper_disable_unused_functions should not be called by atomic drivers, so disable it for later patches. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_fbdev.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/gpu/drm/cirrus/cirrus_fbdev.c b

[PATCH 02/14] drm/cirrus: unregister connector on destroy

2017-08-18 Thread Varad Gautam
From: Varad Gautam add missing unregister call on connector destroy. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_mode.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/cirrus/cirrus_mode.c b/drivers/gpu/drm/cirrus/cirrus_mode.c index 21d75e7e4abc

[PATCH 00/14] atomic modesetting for cirrus

2017-08-18 Thread Varad Gautam
GD-54xx TRM, 1996! It boasts 'optimized PCI burst write, which supports PCI writes to the frame buffer at greater than 55 Mbytes per second.' Dominik Behr (1): drm/cirrus: initialize start and size fields Stéphane Marchesin (1): drm/cirrus: Use 32bpp by default Varad Gautam (10):

[PATCH 01/14] drm/cirrus: split out bo unpinning from cirrus_bo_push_sysram

2017-08-18 Thread Varad Gautam
From: Varad Gautam add a cirrus_bo_unpin call, and move bo_{reserve,unreserve} operations to bo_{pin,unpin} to ensure correct pinning/unpinning and simplify the call sequence. Signed-off-by: Varad Gautam --- drivers/gpu/drm/cirrus/cirrus_drv.h | 1 + drivers/gpu/drm/cirrus/cirrus_mode.c

[PATCH] drm/vc4: improve throughput by pipelining binning and rendering jobs

2016-03-06 Thread Varad Gautam
Hi Eric, On Sat, Mar 5, 2016 at 7:17 AM, Eric Anholt wrote: > Varad Gautam writes: > >> The hardware provides us with separate threads for binning and >> rendering, and the existing model waits for them both to complete >> before submitting the next job. >&

[PATCH] drm/vc4: improve throughput by pipelining binning and rendering jobs

2016-02-17 Thread Varad Gautam
to anholt for suggesting this. Signed-off-by: Varad Gautam --- drivers/gpu/drm/vc4/vc4_drv.h | 37 +++ drivers/gpu/drm/vc4/vc4_gem.c | 108 ++ drivers/gpu/drm/vc4/vc4_irq.c | 58 +++ 3 files changed, 156 insertions(+), 47