Re: [Intel-gfx] [PATCH] drm/i915: Do not reset detect_done flag in intel_dp_detect

2016-12-07 Thread Jani Nikula
On Wed, 07 Dec 2016, Manasi Navare wrote: > The detect_done flag was introduced in the commit > 7d23e3c37bb3fc6952dc84007ee60cb533fd2d5c in order to avoid The preferred format to cite commits is: 7d23e3c37bb3 ("drm/i915: Cleaning up intel_dp_hpd_pulse") or commit 7d23e3c37bb3fc6952dc84007ee60c

Re: [Intel-gfx] [PATCH] dim: Try git-merge --ff-only before git-rebase -i when updating branches.

2016-12-07 Thread Jani Nikula
On Tue, 06 Dec 2016, Maarten Lankhorst wrote: > When a branch can be fast-forwarded, try it first before rebasing. > This will prevent a whole lot of editor windows opening with 'noop' > when running dim ub. > > Signed-off-by: Maarten Lankhorst > --- > dim | 4 +--- > 1 file changed, 1 insertio

Re: [Intel-gfx] [GLK MIPI DSI V1 0/9] GLK MIPI DSI VIDEO MODE PATCHES

2016-12-07 Thread Jani Nikula
On Wed, 07 Dec 2016, Madhav Chauhan wrote: > The patches in this list enable MIPI DSI video mode > support for GLK platform. Tesed locally. The patches never made it to the intel-gfx list. They got lost before reaching fdo servers: 11:39 daniels j4ni: ok, so we have never received an

Re: [Intel-gfx] [PATCH v3] drm/i915: replace platform flags with a platform enum

2016-12-07 Thread Joonas Lahtinen
On to, 2016-12-01 at 14:49 +0200, Jani Nikula wrote: > The platform flags in device info are (mostly) mutually > exclusive. Replace the flags with an enum. Add the platform enum also > for platforms that previously didn't have a flag, and give them codename > logging in dmesg. > > Pineview remains

Re: [Intel-gfx] [PATCH] tools/backlight_helper: #include "config.h"

2016-12-07 Thread Jani Nikula
On Wed, 07 Dec 2016, Mike Frysinger wrote: > From: Mike Gilbert > Uh, which project is this for...? The commit message could use a few words, and you'll need to add Signed-off-by. BR, Jani. > --- > tools/backlight_helper.c | 4 > 1 file changed, 4 insertions(+) > > diff --git a/tools/b

Re: [Intel-gfx] [PATCH i-g-t] lib: Use igt_assert_eq in CHECK_RETURN

2016-12-07 Thread Abdiel Janulgue
On 12/07/2016 08:36 AM, Tomeu Vizoso wrote: > So that debug logs contain the unexpected value. > > Signed-off-by: Tomeu Vizoso Reviewed-by: Abdiel Janulgue > --- > lib/igt_kms.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lib/igt_kms.c b/lib/igt_kms.c > index 9

[Intel-gfx] [PATCH] drm/i915: Reorder phys backing storage release

2016-12-07 Thread Chris Wilson
In commit a4f5ea64f0a8 ("drm/i915: Refactor object page API"), I reordered the object->pages teardown to be more friendly wrt to a separate obj->mm.lock. However, I overlooked the phys object and left it with a dangling use-after-free of its phys_handle. Move the allocation of the phys handle to ge

Re: [Intel-gfx] [PATCH v3] drm/i915: replace platform flags with a platform enum

2016-12-07 Thread Jani Nikula
On Wed, 07 Dec 2016, Joonas Lahtinen wrote: > On to, 2016-12-01 at 14:49 +0200, Jani Nikula wrote: >> The platform flags in device info are (mostly) mutually >> exclusive. Replace the flags with an enum. Add the platform enum also >> for platforms that previously didn't have a flag, and give them

[Intel-gfx] [PATCH v2] drm/i915: rename BROADWATER and CRESTLINE to I965G and I965GM, respectively

2016-12-07 Thread Jani Nikula
Add more consistency to our naming. Pineview remains the outlier. Keep using code names for gen5+. v2: rebased Reviewed-by: Joonas Lahtinen Signed-off-by: Jani Nikula --- drivers/gpu/drm/i915/i915_debugfs.c | 2 +- drivers/gpu/drm/i915/i915_drv.c | 2 +- drivers/gpu/drm/i915/i915

Re: [Intel-gfx] [PATCH 2/6] drm/i915: keep intel device info structs in gen based order

2016-12-07 Thread Joonas Lahtinen
On ke, 2016-11-30 at 17:43 +0200, Jani Nikula wrote: > Move G33 and Pineview higher up in the list. Add a couple of blank lines > for OCD while at it. > > Signed-off-by: Jani Nikula Reviewed-by: Joonas Lahtinen Regards, Joonas -- Joonas Lahtinen Open Source Technology Center Intel Corporation

Re: [Intel-gfx] [PATCH i-g-t v10 17/21] lib/sw_sync: Add igt_require_sw_sync to enable skipping on no sw_sync support

2016-12-07 Thread Petri Latvala
On Tue, Dec 06, 2016 at 09:52:09PM -0500, Robert Foss wrote: > Add igt_require_sw_sync to provide tests to skip if sw_sync support isn't > available on the host machine. > > Signed-off-by: Robert Foss > Reviewed-by: Tomeu Vizoso > --- > lib/sw_sync.c | 22 ++ > lib/sw_sync.h

Re: [Intel-gfx] [RFC i-g-t v3 5/5] Add support for hotplug testing with the Chamelium

2016-12-07 Thread Tomeu Vizoso
Hi Lyude, this looks very good. Some minor comments below. Regards, Tomeu On 1 December 2016 at 02:24, Lyude wrote: > For the purpose of testing things such as hotplugging and bad monitors, > the ChromeOS team ended up designing a neat little device known as the > Chamelium. More information o

Re: [Intel-gfx] Does display engine read contents from LLC of scanout buffer?

2016-12-07 Thread Weng, Chuanbo
Hi Ville, Thanks for your useful info. How about L3 cache? In my scenario, Beignet will use Read Write Data Port to write data (typed write) to bo. So the cache path is L3 -> LLC -> memory. So only leave LLC cache ability the same as PTEs is not enough. In order to make da

[Intel-gfx] [PATCH RFC i-g-t] igt: Add a dpms property test

2016-12-07 Thread Marta Lofstedt
This testcase will set the dpms drm property to DRM_MODE_DPMS_ON and DPMS_MODE_OFF and check that the property values was updated and that the new state corresponds to the crtc active property. Signed-off-by: Marta Lofstedt --- tests/Makefile.sources | 1 + tests/drm_dpms.c | 168 +++

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: Reorder phys backing storage release

2016-12-07 Thread Patchwork
== Series Details == Series: drm/i915: Reorder phys backing storage release URL : https://patchwork.freedesktop.org/series/16468/ State : success == Summary == Series 16468v1 drm/i915: Reorder phys backing storage release https://patchwork.freedesktop.org/api/1.0/series/16468/revisions/1/mbox/

Re: [Intel-gfx] [PATCH RFC i-g-t] igt: Add a dpms property test

2016-12-07 Thread Chris Wilson
On Wed, Dec 07, 2016 at 01:42:59PM +0200, Marta Lofstedt wrote: > This testcase will set the dpms drm property to > DRM_MODE_DPMS_ON and DPMS_MODE_OFF and check that the > property values was updated and that the new state corresponds > to the crtc active property. > > Signed-off-by: Marta Lofsted

Re: [Intel-gfx] [PATCH] drm/i915: Reorder phys backing storage release

2016-12-07 Thread Joonas Lahtinen
On ke, 2016-12-07 at 10:07 +, Chris Wilson wrote: > In commit a4f5ea64f0a8 ("drm/i915: Refactor object page API"), I > reordered the object->pages teardown to be more friendly wrt to a > separate obj->mm.lock. However, I overlooked the phys object and left it > with a dangling use-after-free of

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: introduce platform enum (rev3)

2016-12-07 Thread Patchwork
== Series Details == Series: drm/i915: introduce platform enum (rev3) URL : https://patchwork.freedesktop.org/series/16170/ State : success == Summary == Series 16170v3 drm/i915: introduce platform enum https://patchwork.freedesktop.org/api/1.0/series/16170/revisions/3/mbox/ fi-bdw-5557u

Re: [Intel-gfx] [PATCH] drm/i915: Reorder phys backing storage release

2016-12-07 Thread Chris Wilson
On Wed, Dec 07, 2016 at 02:10:34PM +0200, Joonas Lahtinen wrote: > On ke, 2016-12-07 at 10:07 +, Chris Wilson wrote: > > In commit a4f5ea64f0a8 ("drm/i915: Refactor object page API"), I > > reordered the object->pages teardown to be more friendly wrt to a > > separate obj->mm.lock. However, I o

[Intel-gfx] [PATCH] drm: Allow CAP_PRIME on !MODESET

2016-12-07 Thread Daniel Vetter
vgem (and our igt tests using vgem) need this. I suspect etnaviv will fare similarly. Fixes: d5264ed3823a ("drm: Return -ENOTSUPP when called for KMS cap with a non-KMS driver") Cc: Michel Dänzer Cc: Alex Deucher Cc: Chris Wilson Signed-off-by: Daniel Vetter Signed-off-by: Daniel Vetter ---

Re: [Intel-gfx] [PATCH] drm: Allow CAP_PRIME on !MODESET

2016-12-07 Thread Chris Wilson
On Wed, Dec 07, 2016 at 02:13:23PM +0100, Daniel Vetter wrote: > vgem (and our igt tests using vgem) need this. I suspect etnaviv will > fare similarly. > > Fixes: d5264ed3823a ("drm: Return -ENOTSUPP when called for KMS cap with a > non-KMS driver") > Cc: Michel Dänzer > Cc: Alex Deucher > Cc:

Re: [Intel-gfx] [PATCH v3] drm/i915: replace platform flags with a platform enum

2016-12-07 Thread Jani Nikula
On Wed, 07 Dec 2016, Jani Nikula wrote: > On Wed, 07 Dec 2016, Joonas Lahtinen wrote: >> On to, 2016-12-01 at 14:49 +0200, Jani Nikula wrote: >>> The platform flags in device info are (mostly) mutually >>> exclusive. Replace the flags with an enum. Add the platform enum also >>> for platforms tha

[Intel-gfx] [CI] drm/i915: Reorder phys backing storage release

2016-12-07 Thread Chris Wilson
In commit a4f5ea64f0a8 ("drm/i915: Refactor object page API"), I reordered the object->pages teardown to be more friendly wrt to a separate obj->mm.lock. However, I overlooked the phys object and left it with a dangling use-after-free of its phys_handle. Move the allocation of the phys handle to ge

[Intel-gfx] [PATCH] drm/i915: Catch non-existent registers in find_fw_domain

2016-12-07 Thread Joonas Lahtinen
Add WARN_ON to find_fw_domain to registers related to uninitialized hardware. Cc: Imre Deak Cc: Wang Elaine Cc: Chris Wilson Signed-off-by: Joonas Lahtinen --- drivers/gpu/drm/i915/intel_uncore.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/in

Re: [Intel-gfx] [PATCH] drm/i915: Respect ring_mask when initializing forcewake domains

2016-12-07 Thread Joonas Lahtinen
On ma, 2016-12-05 at 21:16 +0800, Wang Elaine wrote: > From: Elaine Wang > > Some platforms don't have render or blitter. So no need to call > render domain or blitter domain forcewake init function. > > Cc: Joonas Lahtinen > Signed-off-by: Elaine Wang I sent an additional patch to the mailin

Re: [Intel-gfx] [PATCH] drm/i915: Reorder phys backing storage release

2016-12-07 Thread Joonas Lahtinen
On ke, 2016-12-07 at 12:27 +, Chris Wilson wrote: > Since the > objects are either 4k or 16k and either 4k or 16k aligned (though only > 830 cursors are 16k aligned), the alignment falls out of the actual > buddy allocation for the contiguous pages. This should be enough information to add. M

[Intel-gfx] [PATCH 04/16] drm/i915: Add unit tests for the breadcrumb rbtree, completion

2016-12-07 Thread Chris Wilson
Second retroactive test, make sure that the waiters are removed from the global wait-tree when their seqno completes. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/intel_breadcrumbs.c | 110 +++ 1 file changed, 110 insertions(+) diff --git a/drivers/gpu/drm/i9

[Intel-gfx] [PATCH 02/16] kselftests: Exercise hw-independent mock tests for i915.ko

2016-12-07 Thread Chris Wilson
Although being a GPU driver most functionality of i915.ko depends upon real hardware, many of its internal interfaces can be "mocked" and so tested independently of any hardware. Expanding the test coverage is not only useful for i915.ko, but should provide some integration tests for core infrastru

[Intel-gfx] [RFC] Smattering of selftests

2016-12-07 Thread Chris Wilson
More changes to GEM are on the cards, so before touching it again, let's try and nail down how the internals are meant to work. The advantage of mock testing is that we can write a universal test independent of the hw (e.g. testing physical object creation) and we can inspect internal state which s

[Intel-gfx] [PATCH 07/16] drm/i915: Move intel_lrc_context_pin() to avoid the forward declaration

2016-12-07 Thread Chris Wilson
Just a simple move to avoid a forward declaration. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/intel_lrc.c | 132 +++ 1 file changed, 65 insertions(+), 67 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_lrc.c b/drivers/gpu/drm/i915/intel_lrc.c i

[Intel-gfx] [PATCH 03/16] drm/i915: Add unit tests for the breadcrumb rbtree, insert/remove

2016-12-07 Thread Chris Wilson
First retroactive test, make sure that the waiters are in global seqno order after random inserts and removals. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/i915_mock_selftests.h | 1 + drivers/gpu/drm/i915/intel_breadcrumbs.c | 205 + drivers/gpu/drm/i915

[Intel-gfx] [PATCH 10/16] drm/i915: Mark the shadow gvt context as closed

2016-12-07 Thread Chris Wilson
As the shadow gvt is not user accessible and does not have an associated vm, we can mark it as closed during its construction. This saves leaking the internal knowledge of i915_gem_context into gvt/. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/gvt/scheduler.c| 10 +- drivers

[Intel-gfx] [PATCH 15/16] drm/i915: Add a simple fence selftest to i915_gem_request

2016-12-07 Thread Chris Wilson
Do a quick selftest on in the interoperability of dma_fence_wait on a i915_gem_request. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/i915_gem_request.c | 51 + 1 file changed, 51 insertions(+) diff --git a/drivers/gpu/drm/i915/i915_gem_request.c b/driver

[Intel-gfx] [PATCH 09/16] drm/i915: Simplify releasing context reference

2016-12-07 Thread Chris Wilson
A few users only take the struct_mutex in order to release a reference to a context. We can expose a kref_put_mutex() wrapper in order to simplify these users, and optimise taking of the mutex to the final unref. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/i915_drv.h | 7 +++ driv

[Intel-gfx] [PATCH 01/16] drm/i915: Provide a hook for selftests

2016-12-07 Thread Chris Wilson
Some pieces of code are independent of hardware but are very tricky to exercise through the normal userspace ABI or via debugfs hooks. Being able to create mock unit tests and execute them through CI is vital. Start by adding a central point where we can execute unit tests and a parameter to enable

[Intel-gfx] [PATCH 05/16] drm/i915: Add unit tests for the breadcrumb rbtree, wakeups

2016-12-07 Thread Chris Wilson
Third retroactive test, make sure that the seqno waiters are woken. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/intel_breadcrumbs.c | 171 +++ 1 file changed, 171 insertions(+) diff --git a/drivers/gpu/drm/i915/intel_breadcrumbs.c b/drivers/gpu/drm/i915/int

[Intel-gfx] [PATCH 16/16] drm/i915: Add selftests for object allocation, phys

2016-12-07 Thread Chris Wilson
The phys object is a rarely used device (only very old machines require a chunk of physically contiguous pages for a few hardware interactions). As such, it is not exercised by CI and to combat that we want to add a test that exercises the phys object on all platforms. Signed-off-by: Chris Wilson

[Intel-gfx] [PATCH 12/16] drm/i915: Swap if(enable_execlists) in i915_gem_request_alloc for a vfunc

2016-12-07 Thread Chris Wilson
A fairly trivial move of a matching pair of routines (for preparing a request for construction) onto an engine vfunc. The ulterior motive is to be able to create a mock request implementation. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/i915_gem_request.c | 5 + drivers/gpu/drm/i915

[Intel-gfx] [PATCH 06/16] drm/i915: Add a reminder that i915_vma_move_to_active() requires struct_mutex

2016-12-07 Thread Chris Wilson
i915_vma_move_to_active() requires the struct_mutex for serialisation with retirement, so mark it up with lockdep_assert_held(). Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/i915/i915_gem_execbuffer

[Intel-gfx] [PATCH 11/16] drm/i915/execlists: Request the kernel context be pinned high

2016-12-07 Thread Chris Wilson
PIN_HIGH is an expensive operation (in comparison to allocating from the hole stack) unsuitable for frequent use (such as switching between contexts). However, the kernel context should be pinned just once for the lifetime of the driver, and here it is appropriate to keep it out of the mappable ran

[Intel-gfx] [PATCH 14/16] drm/i915: Add a simple request selftest for waiting

2016-12-07 Thread Chris Wilson
A trivial kselftest to submit a request and wait upon it. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/i915_gem_request.c | 48 + 1 file changed, 48 insertions(+) diff --git a/drivers/gpu/drm/i915/i915_gem_request.c b/drivers/gpu/drm/i915/i915_gem_reques

[Intel-gfx] [PATCH 08/16] drm/i915: Unify active context tracking between legacy/execlists/guc

2016-12-07 Thread Chris Wilson
The requests conversion introduced a nasty bug where we could generate a new request in the middle of constructing a request. The new request would be executed (and waited upon) before the current one, creating a minor havoc in the seqno accounting. (Prior to deferred seqno assignment, this would m

[Intel-gfx] [PATCH 13/16] drm/i915: Add selftests for i915_gem_request

2016-12-07 Thread Chris Wilson
Simple starting point for adding seltests for i915_gem_request, first mock a device (with engines and contexts) that allows us to construct and execute a request, along with waiting for the request to complete. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/i915_gem_request.c| 402

Re: [Intel-gfx] [PATCH] drm/i915: Catch non-existent registers in find_fw_domain

2016-12-07 Thread Chris Wilson
On Wed, Dec 07, 2016 at 03:49:39PM +0200, Joonas Lahtinen wrote: > Add WARN_ON to find_fw_domain to registers related to uninitialized > hardware. > > Cc: Imre Deak > Cc: Wang Elaine > Cc: Chris Wilson > Signed-off-by: Joonas Lahtinen > --- > drivers/gpu/drm/i915/intel_uncore.c | 7 ++- >

Re: [Intel-gfx] [RFC] Smattering of selftests

2016-12-07 Thread Chris Wilson
On Wed, Dec 07, 2016 at 01:58:17PM +, Chris Wilson wrote: > More changes to GEM are on the cards, so before touching it again, let's > try and nail down how the internals are meant to work. The advantage > of mock testing is that we can write a universal test independent of the > hw (e.g. testi

[Intel-gfx] [PATCH] FOR_UPSTREAM [VPG]: drm/i915: Parse panel BL controller from VBT

2016-12-07 Thread Vidya Srinivas
Currently the backlight controller is taken as 0. It needs to derive value from the VBT. Adding the necessary changes. Signed-off-by: Uma Shankar Signed-off-by: Vidya Srinivas --- drivers/gpu/drm/i915/i915_drv.h| 1 + drivers/gpu/drm/i915/intel_bios.c | 5 + drivers/gpu/drm/i915/intel_

Re: [Intel-gfx] [PATCH] drm/i915: Do not reset detect_done flag in intel_dp_detect

2016-12-07 Thread Ville Syrjälä
On Tue, Dec 06, 2016 at 04:43:51PM -0800, Manasi Navare wrote: > The detect_done flag was introduced in the commit > 7d23e3c37bb3fc6952dc84007ee60cb533fd2d5c in order to avoid > multiple detects on hotplug where intel_dp_long_pulse() > was called from HPD handler as well as in intel_dp_detect. > So

[Intel-gfx] [PATCH] drm/i915: make Pineview a platform of its own

2016-12-07 Thread Jani Nikula
Pineview deserves to use its own platform enum (which was already added, unused, previously). Cc: Ville Syrjälä Cc: Chris Wilson Cc: Joonas Lahtinen Signed-off-by: Jani Nikula --- The wrinkle here is that IS_G33() still has to match both G33 and Pineview. I'd prefer it if G33 *only* matched

Re: [Intel-gfx] [PATCH] drm/i915: Catch non-existent registers in find_fw_domain

2016-12-07 Thread Joonas Lahtinen
On ke, 2016-12-07 at 14:01 +, Chris Wilson wrote: > On Wed, Dec 07, 2016 at 03:49:39PM +0200, Joonas Lahtinen wrote: > > > > + WARN_ON(entry->domains & ~dev_priv->uncore.fw_domains); > > Ok, this is going to be hard to diagnose in the wild, how about > > WARN(entry->domains & ~fw_domains,

Re: [Intel-gfx] [PATCH 02/16] kselftests: Exercise hw-independent mock tests for i915.ko

2016-12-07 Thread Chris Wilson
On Wed, Dec 07, 2016 at 01:58:19PM +, Chris Wilson wrote: > Although being a GPU driver most functionality of i915.ko depends upon > real hardware, many of its internal interfaces can be "mocked" and so > tested independently of any hardware. Expanding the test coverage is not > only useful for

Re: [Intel-gfx] Does display engine read contents from LLC of scanout buffer?

2016-12-07 Thread Ville Syrjälä
On Wed, Dec 07, 2016 at 11:30:37AM +, Weng, Chuanbo wrote: > Hi Ville, > Thanks for your useful info. > How about L3 cache? In my scenario, Beignet will use Read Write Data > Port to write data (typed write) to bo. > So the cache path is L3 -> LLC -> memory. So only leave LLC cache

Re: [Intel-gfx] [PATCH] drm/i915: make Pineview a platform of its own

2016-12-07 Thread Ville Syrjälä
On Wed, Dec 07, 2016 at 04:06:48PM +0200, Jani Nikula wrote: > Pineview deserves to use its own platform enum (which was already added, > unused, previously). > > Cc: Ville Syrjälä > Cc: Chris Wilson > Cc: Joonas Lahtinen > Signed-off-by: Jani Nikula > > --- > > The wrinkle here is that IS_G

[Intel-gfx] [PATCH v2] drm/i915: Catch non-existent registers in find_fw_domain

2016-12-07 Thread Joonas Lahtinen
Add WARN_ON to find_fw_domain to registers related to uninitialized hardware. v2: - Print the uninitialized domains and register (Chris) Cc: Imre Deak Cc: Wang Elaine Cc: Chris Wilson Signed-off-by: Joonas Lahtinen --- drivers/gpu/drm/i915/intel_uncore.c | 9 - 1 file changed, 8 inse

[Intel-gfx] ✗ Fi.CI.BAT: failure for drm: Allow CAP_PRIME on !MODESET

2016-12-07 Thread Patchwork
== Series Details == Series: drm: Allow CAP_PRIME on !MODESET URL : https://patchwork.freedesktop.org/series/16479/ State : failure == Summary == CC drivers/acpi/acpica/utobject.o CC drivers/acpi/acpica/utownerid.o LD [M] drivers/ssb/ssb.o CC drivers/acpi/acpica/utprede

Re: [Intel-gfx] [PATCH v2] drm/i915: Catch non-existent registers in find_fw_domain

2016-12-07 Thread Chris Wilson
On Wed, Dec 07, 2016 at 04:22:39PM +0200, Joonas Lahtinen wrote: > Add WARN_ON to find_fw_domain to registers related to uninitialized > hardware. > > v2: > - Print the uninitialized domains and register (Chris) > > Cc: Imre Deak > Cc: Wang Elaine > Cc: Chris Wilson > Signed-off-by: Joonas Lah

[Intel-gfx] [PATCH] drm: Allow CAP_PRIME on !MODESET

2016-12-07 Thread Daniel Vetter
vgem (and our igt tests using vgem) need this. I suspect etnaviv will fare similarly. v2. Make it build. Oops. Fixes: d5264ed3823a ("drm: Return -ENOTSUPP when called for KMS cap with a non-KMS driver") Cc: Michel Dänzer Cc: Alex Deucher Cc: Chris Wilson Reviewed-by: Chris Wilson Signed-off-

[Intel-gfx] [PATCH] FOR_UPSTREAM [VPG]: drm/i915: Parse panel BL controller from VBT

2016-12-07 Thread Vidya Srinivas
Currently the backlight controller is taken as 0. It needs to derive value from the VBT. Adding the necessary changes. Signed-off-by: Uma Shankar Signed-off-by: Vidya Srinivas --- drivers/gpu/drm/i915/i915_drv.h| 1 + drivers/gpu/drm/i915/intel_bios.c | 5 + drivers/gpu/drm/i915/intel_

[Intel-gfx] [PATCH] drm/i915: Parse panel BL controller from VBT

2016-12-07 Thread Vidya Srinivas
Currently the backlight controller is taken as 0. It needs to derive value from the VBT. Adding the necessary changes. v2: Updated the commit header Signed-off-by: Uma Shankar Signed-off-by: Vidya Srinivas --- drivers/gpu/drm/i915/i915_drv.h| 1 + drivers/gpu/drm/i915/intel_bios.c | 5 +++

Re: [Intel-gfx] [PATCH i-g-t v2] tests/kms_plane_lowres: Plane visibility after atomic modesets

2016-12-07 Thread Daniel Stone
Hi Mika, Thanks for respinning! On 23 November 2016 at 11:49, Mika Kahola wrote: > +bool kmstest_plane_visible(void) > +{ > + char tmp[256]; > + FILE *fid; > + bool visible = false; > + struct kmstest_resolution resolution; > + const char *mode = "r"; > + int r

Re: [Intel-gfx] [PATCH] drm: Allow CAP_PRIME on !MODESET

2016-12-07 Thread Michel Dänzer
On 07/12/16 11:49 PM, Daniel Vetter wrote: > vgem (and our igt tests using vgem) need this. I suspect etnaviv will > fare similarly. > > v2. Make it build. Oops. > > Fixes: d5264ed3823a ("drm: Return -ENOTSUPP when called for KMS cap with a > non-KMS driver") > Cc: Michel Dänzer > Cc: Alex Deuc

Re: [Intel-gfx] [RFC PATCH] drm/i915: Add a cursor hack to allow converting legacy page flip to atomic.

2016-12-07 Thread Daniel Vetter
On Thu, Nov 24, 2016 at 04:35:35PM +0100, Maarten Lankhorst wrote: > Do something similar to vc4, only allow updating the cursor state > in-place through a fastpath when the watermarks are unaffected. This > will allow cursor movement to be smooth, but changing cursor size or > showing/hiding curso

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: Reorder phys backing storage release (rev2)

2016-12-07 Thread Patchwork
== Series Details == Series: drm/i915: Reorder phys backing storage release (rev2) URL : https://patchwork.freedesktop.org/series/16468/ State : success == Summary == Series 16468v2 drm/i915: Reorder phys backing storage release https://patchwork.freedesktop.org/api/1.0/series/16468/revisions/

Re: [Intel-gfx] [PATCH i-g-t v10 17/21] lib/sw_sync: Add igt_require_sw_sync to enable skipping on no sw_sync support

2016-12-07 Thread Robert Foss
On 2016-12-07 06:06 AM, Petri Latvala wrote: On Tue, Dec 06, 2016 at 09:52:09PM -0500, Robert Foss wrote: Add igt_require_sw_sync to provide tests to skip if sw_sync support isn't available on the host machine. Signed-off-by: Robert Foss Reviewed-by: Tomeu Vizoso --- lib/sw_sync.c | 22 +++

[Intel-gfx] [PATCH xf86-video-intel v2] tools/backlight_helper: #include "config.h"

2016-12-07 Thread Mike Frysinger
From: Mike Gilbert The file uses defines from config.h but never actually includes it. Signed-off-by: Mike Gilbert Signed-off-by: Mike Frysinger --- tools/backlight_helper.c | 4 1 file changed, 4 insertions(+) diff --git a/tools/backlight_helper.c b/tools/backlight_helper.c index a00f0

[Intel-gfx] ✓ Fi.CI.BAT: success for series starting with [01/16] drm/i915: Provide a hook for selftests

2016-12-07 Thread Patchwork
== Series Details == Series: series starting with [01/16] drm/i915: Provide a hook for selftests URL : https://patchwork.freedesktop.org/series/16488/ State : success == Summary == Series 16488v1 Series without cover letter https://patchwork.freedesktop.org/api/1.0/series/16488/revisions/1/mbo

Re: [Intel-gfx] [PATCH v2 11/15] drm/i915: Protect DSPARB registers with a spinlock

2016-12-07 Thread Ville Syrjälä
On Tue, Dec 06, 2016 at 09:26:22AM +0100, Maarten Lankhorst wrote: > Op 05-12-16 om 15:13 schreef ville.syrj...@linux.intel.com: > > From: Ville Syrjälä > > > > Each DSPARB register can house bits for two separate pipes, hence > > we must protect the registers during reprogramming so that parallel

Re: [Intel-gfx] [PATCH] drm/i915/perf: use DRM_DEBUG for userspace issues

2016-12-07 Thread Daniel Vetter
On Fri, Dec 02, 2016 at 12:18:44PM +, Robert Bragg wrote: > On Fri, Dec 2, 2016 at 8:35 AM, Daniel Vetter wrote: > > > On Thu, Dec 01, 2016 at 05:21:52PM +, Robert Bragg wrote: > > > Avoid using DRM_ERROR for conditions userspace can trigger with a bad > > > config when opening a stream o

[Intel-gfx] [PATCH] drm/i915: Consolidate checks for memcpy-from-wc support

2016-12-07 Thread Chris Wilson
In order to silence sparse: ../drivers/gpu/drm/i915/i915_gpu_error.c:200:39: warning: Using plain integer as NULL pointer add a helper to check whether we have sse4.1 and that the desired alignment is valid for acceleration. Reported-by: Ville Syrjälä Signed-off-by: Chris Wilson Cc: Ville Syr

Re: [Intel-gfx] [PATCH] drm/i915: Remove instructions to file a bug report.

2016-12-07 Thread Daniel Vetter
On Mon, Dec 05, 2016 at 04:55:47PM -0800, Matt Turner wrote: > On Sat, Dec 3, 2016 at 1:52 AM, Jani Nikula > wrote: > > On Sat, 03 Dec 2016, Matt Turner wrote: > >> From these instructions, users assume that /sys/class/drm/card0/error > >> contains all the information a developer needs to diagno

[Intel-gfx] [PATCH igt] intel-ci: Do module loads first + last

2016-12-07 Thread Chris Wilson
Do the module reload test first, so that it has the best chance of succeeding without outside influence (broken driver). And then do it last, so that it has the best chance of catching some missing finalisation (e.g. memleak) over the lifetime of the testing. Signed-off-by: Chris Wilson Cc: Petri

[Intel-gfx] ✗ Fi.CI.BAT: warning for drm/i915: make Pineview a platform of its own

2016-12-07 Thread Patchwork
== Series Details == Series: drm/i915: make Pineview a platform of its own URL : https://patchwork.freedesktop.org/series/16490/ State : warning == Summary == Series 16490v1 drm/i915: make Pineview a platform of its own https://patchwork.freedesktop.org/api/1.0/series/16490/revisions/1/mbox/

[Intel-gfx] [PATCH v2] dim: Try git-merge --ff-only before git-rebase -i when updating branches.

2016-12-07 Thread Maarten Lankhorst
Op 07-12-16 om 10:33 schreef Jani Nikula: > On Tue, 06 Dec 2016, Maarten Lankhorst > wrote: >> When a branch can be fast-forwarded, try it first before rebasing. >> This will prevent a whole lot of editor windows opening with 'noop' >> when running dim ub. >> >> Signed-off-by: Maarten Lankhorst

[Intel-gfx] [PATCH 00/11] drm/i915: Overlay fixes

2016-12-07 Thread ville . syrjala
From: Ville Syrjälä Fixes for some recentish regressions in the overlay support (kernel would oops as soon as you try to use the overlay), and I decided to dig up a few older cleanups and fixes I had lying around in my gen2 dungeon. Entire series (with Chris's phys obj fix) here: git://github.co

[Intel-gfx] [PATCH 02/11] drm/i915: Fix oopses in the overlay code due to i915_gem_active stuff

2016-12-07 Thread ville . syrjala
From: Ville Syrjälä The i915_gem_active stuff doesn't like a NULL ->retire hook, but the overlay code can set it to NULL. That obviously ends up oopsing. Fix it by setting the ->retire hook using init_request_active() so that it'll do the NULL->i915_gem_retire_noop conversion for us. Cc: Chris W

[Intel-gfx] [PATCH 03/11] drm/i915: Restore dev_priv->mm.interruptible for overlay

2016-12-07 Thread ville . syrjala
From: Ville Syrjälä We need an uninterruptible wait for the overlay off request during modeset. Restore the operation of dev_priv->mm.interruptible sufficiently for that. Toss in a WARN_ON() to make sure the request succeeds. Fixes: 7da844c5c6fc ("drm/i915: Move the special case wait-request ha

[Intel-gfx] [PATCH 06/11] drm/i915: Kill intel_panel_fitter_pipe()

2016-12-07 Thread ville . syrjala
From: Ville Syrjälä Check pipe config gmch_pfit.control instead of using intel_panel_fitter_pipe() to figure out if the pipe for the overlay is using the panel fitter. Signed-off-by: Ville Syrjälä --- drivers/gpu/drm/i915/intel_overlay.c | 29 + 1 file changed, 1 in

[Intel-gfx] [PATCH 05/11] drm/i915: Use pipe_src_w in overlay code

2016-12-07 Thread ville . syrjala
From: Ville Syrjälä Replace the use of crtc->mode.h/vdisplay with the more appropriate config->pipe_src_w/h. Signed-off-by: Ville Syrjälä --- drivers/gpu/drm/i915/intel_overlay.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_overl

[Intel-gfx] [PATCH 04/11] drm/i915: Fix the overlay frontbuffer tracking

2016-12-07 Thread ville . syrjala
From: Ville Syrjälä Do the overlay frontbuffer tracking properly so that it matches the state of the overlay on/off/continue requests. One slight problem is that intel_frontbuffer_flip_complete() may get delayed by an arbitrarily liong time due to the fact that the overlay code likes to bail out

[Intel-gfx] [PATCH 09/11] drm/i915: Use primary plane->state for overlay ckey setup

2016-12-07 Thread ville . syrjala
From: Ville Syrjälä Extract the primary plane pixel format via plane state when setting up the overlay colorkey. Signed-off-by: Ville Syrjälä --- drivers/gpu/drm/i915/intel_overlay.c | 33 + 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/drivers

[Intel-gfx] [PATCH 08/11] drm/i915: Reorganize overlay filter coeffs into a nicer form

2016-12-07 Thread ville . syrjala
From: Ville Syrjälä Use two-dimensional arrays and named initializers to make the overlay filter coefficient tables easier to parse for humans. Signed-off-by: Ville Syrjälä --- drivers/gpu/drm/i915/intel_overlay.c | 64 1 file changed, 36 insertions(+), 28

[Intel-gfx] [PATCH 10/11] drm/i915: Disable L2 cache clock gating on 830 when using the overlay

2016-12-07 Thread ville . syrjala
From: Ville Syrjälä BSpec says: "Overlay Clock Gating Must be Disabled: Overlay & L2 Cache clock gating must be disabled in order to prevent device hangs when turning off overlay.SW must turn off Ovrunit clock gating (6200h) and L2 Cache clock gating (C8h)." We only turned off the overlay clock

[Intel-gfx] [PATCH 07/11] drm/i915: Simplify SWIDTHSW calculation

2016-12-07 Thread ville . syrjala
From: Ville Syrjälä The formula in Bspec for computing the overlay SWIDTHSW is overly obfuscated. Simplify the formula to something that's easily parsed by humans. Signed-off-by: Ville Syrjälä --- drivers/gpu/drm/i915/intel_overlay.c | 24 +++- 1 file changed, 11 insertions

[Intel-gfx] [PATCH 11/11] drm/i915: Kill the 830 MI_OVERLAY_OFF workaround

2016-12-07 Thread ville . syrjala
From: Ville Syrjälä Now that we're disabling L2 clock gating MI_OVERLAY_OFF actually works on 830, so let's use it. Signed-off-by: Ville Syrjälä --- drivers/gpu/drm/i915/intel_overlay.c | 18 ++ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/drivers/gpu/drm/i915

[Intel-gfx] [PATCH 01/11] drm/i915: Fix oops in overlay due to frontbuffer trakcing

2016-12-07 Thread ville . syrjala
From: Ville Syrjälä The vma will be NULL if the overlay was previously off, so dereferencing it will oops. Check for NULL before doing that. Cc: Chris Wilson Cc: Joonas Lahtinen Fixes: 9b3b7841b86d ("drm/i915/overlay: Use VMA as the primary tracker for images") Signed-off-by: Ville Syrjälä -

Re: [Intel-gfx] [PATCH 03/11] drm/i915: Restore dev_priv->mm.interruptible for overlay

2016-12-07 Thread Chris Wilson
On Wed, Dec 07, 2016 at 07:28:05PM +0200, ville.syrj...@linux.intel.com wrote: > From: Ville Syrjälä > > We need an uninterruptible wait for the overlay off request during > modeset. Restore the operation of dev_priv->mm.interruptible > sufficiently for that. > > Toss in a WARN_ON() to make sure

Re: [Intel-gfx] [PATCH 02/11] drm/i915: Fix oopses in the overlay code due to i915_gem_active stuff

2016-12-07 Thread Chris Wilson
On Wed, Dec 07, 2016 at 07:28:04PM +0200, ville.syrj...@linux.intel.com wrote: > From: Ville Syrjälä > > The i915_gem_active stuff doesn't like a NULL ->retire hook, but > the overlay code can set it to NULL. That obviously ends up oopsing. > Fix it by setting the ->retire hook using init_request

Re: [Intel-gfx] [PATCH v2] drm/i915/dsi: Fix swapping of MIPI_SEQ_DEASSERT_RESET / MIPI_SEQ_ASSERT_RESET

2016-12-07 Thread Ville Syrjälä
On Fri, Dec 02, 2016 at 04:01:28PM +0100, Hans de Goede wrote: > Looking at the ADF code from the Android kernel sources for a > cherrytrail tablet I noticed that it is calling the > MIPI_SEQ_ASSERT_RESET sequence from the panel prepare hook. > > Until commit b1cb1bd29189 ("drm/i915/dsi: update re

Re: [Intel-gfx] [RFC 0/5] DRM logging tidy

2016-12-07 Thread Robert Bragg
On Tue, Dec 6, 2016 at 6:57 PM, Tvrtko Ursulin wrote: > From: Tvrtko Ursulin > > I wasn't here at the beginnings of DRM so I might have gotten this wrong, > however the existance of DRM_NAME suggested to me that the intention was to > allow individual drivers to override it and get appropriate p

Re: [Intel-gfx] [PATCH] drm/i915: Parse panel BL controller from VBT

2016-12-07 Thread Bob Paauwe
I currently have this same patch in my tree (well with the two changes below) and have been testing it so with the changes. Reviewed-by: Bob Paauwe Tested-by: Bob Paauwe On Wed, 7 Dec 2016 20:32:18 +0530 Vidya Srinivas wrote: > Currently the backlight controller is taken as 0. It needs to de

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: Catch non-existent registers in find_fw_domain (rev2)

2016-12-07 Thread Patchwork
== Series Details == Series: drm/i915: Catch non-existent registers in find_fw_domain (rev2) URL : https://patchwork.freedesktop.org/series/16487/ State : success == Summary == Series 16487v2 drm/i915: Catch non-existent registers in find_fw_domain https://patchwork.freedesktop.org/api/1.0/ser

Re: [Intel-gfx] [PATCH 02/18] drm/i915/dsi: Fix chv_exec_gpio disabling the GPIOs it is setting

2016-12-07 Thread Ville Syrjälä
On Thu, Dec 01, 2016 at 09:29:09PM +0100, Hans de Goede wrote: > Set the CHV_GPIO_GPIOEN bit when updating GPIOs from chv_exec_gpio. > > Fixes: a0a6d4ffd2ad ("drm/i915/dsi: add support for gpio elements on CHV") > Cc: sta...@vger.kernel.org > Cc: Jani Nikula > Cc: Ville Syrjälä > Signed-off-by:

Re: [Intel-gfx] [PATCH 01/11] drm/i915: Fix oops in overlay due to frontbuffer trakcing

2016-12-07 Thread Chris Wilson
On Wed, Dec 07, 2016 at 07:28:03PM +0200, ville.syrj...@linux.intel.com wrote: > From: Ville Syrjälä > > The vma will be NULL if the overlay was previously off, so > dereferencing it will oops. Check for NULL before doing that. > > Cc: Chris Wilson > Cc: Joonas Lahtinen > Fixes: 9b3b7841b86d (

Re: [Intel-gfx] [PATCH 03/11] drm/i915: Restore dev_priv->mm.interruptible for overlay

2016-12-07 Thread Ville Syrjälä
On Wed, Dec 07, 2016 at 05:41:39PM +, Chris Wilson wrote: > On Wed, Dec 07, 2016 at 07:28:05PM +0200, ville.syrj...@linux.intel.com wrote: > > From: Ville Syrjälä > > > > We need an uninterruptible wait for the overlay off request during > > modeset. Restore the operation of dev_priv->mm.inte

[Intel-gfx] [PATCH] drm/i915: Fix oopses in the overlay code due to i915_gem_active stuff

2016-12-07 Thread Chris Wilson
From: Ville Syrjälä The i915_gem_active stuff doesn't like a NULL ->retire hook, but the overlay code can set it to NULL. That obviously ends up oopsing. Fix it by introducing a new helper to assign the retirement callback that will switch out the NULL function pointer with i915_gem_retire_noop.

Re: [Intel-gfx] [PATCH 02/11] drm/i915: Fix oopses in the overlay code due to i915_gem_active stuff

2016-12-07 Thread Ville Syrjälä
On Wed, Dec 07, 2016 at 05:44:15PM +, Chris Wilson wrote: > On Wed, Dec 07, 2016 at 07:28:04PM +0200, ville.syrj...@linux.intel.com wrote: > > From: Ville Syrjälä > > > > The i915_gem_active stuff doesn't like a NULL ->retire hook, but > > the overlay code can set it to NULL. That obviously e

Re: [Intel-gfx] [PATCH v2] dim: Try git-merge --ff-only before git-rebase -i when updating branches.

2016-12-07 Thread Jani Nikula
On Wed, 07 Dec 2016, Maarten Lankhorst wrote: > Op 07-12-16 om 10:33 schreef Jani Nikula: >> On Tue, 06 Dec 2016, Maarten Lankhorst >> wrote: >>> When a branch can be fast-forwarded, try it first before rebasing. >>> This will prevent a whole lot of editor windows opening with 'noop' >>> when r

Re: [Intel-gfx] [PATCH] drm/i915: Fix oopses in the overlay code due to i915_gem_active stuff

2016-12-07 Thread Ville Syrjälä
On Wed, Dec 07, 2016 at 05:56:47PM +, Chris Wilson wrote: > From: Ville Syrjälä > > The i915_gem_active stuff doesn't like a NULL ->retire hook, but > the overlay code can set it to NULL. That obviously ends up oopsing. > Fix it by introducing a new helper to assign the retirement callback >

Re: [Intel-gfx] [PATCH v2] drm/i915: Catch non-existent registers in find_fw_domain

2016-12-07 Thread Tvrtko Ursulin
On 07/12/2016 14:22, Joonas Lahtinen wrote: Add WARN_ON to find_fw_domain to registers related to uninitialized hardware. v2: - Print the uninitialized domains and register (Chris) Cc: Imre Deak Cc: Wang Elaine Cc: Chris Wilson Signed-off-by: Joonas Lahtinen --- drivers/gpu/drm/i915/intel

Re: [Intel-gfx] [PATCH] drm/i915: Fix oopses in the overlay code due to i915_gem_active stuff

2016-12-07 Thread Chris Wilson
On Wed, Dec 07, 2016 at 08:11:33PM +0200, Ville Syrjälä wrote: > On Wed, Dec 07, 2016 at 05:56:47PM +, Chris Wilson wrote: > > From: Ville Syrjälä > > > > The i915_gem_active stuff doesn't like a NULL ->retire hook, but > > the overlay code can set it to NULL. That obviously ends up oopsing.

Re: [Intel-gfx] [PATCH 03/11] drm/i915: Restore dev_priv->mm.interruptible for overlay

2016-12-07 Thread Chris Wilson
On Wed, Dec 07, 2016 at 07:51:16PM +0200, Ville Syrjälä wrote: > On Wed, Dec 07, 2016 at 05:41:39PM +, Chris Wilson wrote: > > Or we can push this wait to where it can interrupt, such as > > prepare_planes_fb. > > (For intel_atomic_commit_tail, intel_crtc_disable_noatomic() should always > > b

  1   2   >