[Intel-gfx] [PATCH] drm: Provide a driver hook for drm_dev_release()

2016-12-08 Thread Chris Wilson
Some state is coupled into the device lifetime outside of the load/unload timeframe and requires teardown during final unreference from drm_dev_release(). For example, dmabufs hold both a device and module reference and may live longer than expected (i.e. the current pattern of the driver tearing d

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

2016-12-08 Thread Chris Wilson
On Wed, Dec 07, 2016 at 07:28:08PM +0200, ville.syrj...@linux.intel.com wrote: > 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ä Reviewe

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

2016-12-08 Thread Chris Wilson
On Wed, Dec 07, 2016 at 07:28:07PM +0200, ville.syrj...@linux.intel.com wrote: > From: Ville Syrjälä > > Replace the use of crtc->mode.h/vdisplay with the more appropriate > config->pipe_src_w/h. I'll ask the dumb question: wouldn't pipe_src be the fb dimensions? It doesn't seem obvious to be th

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

2016-12-08 Thread Chris Wilson
On Wed, Dec 07, 2016 at 07:28:09PM +0200, ville.syrj...@linux.intel.com wrote: > 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ä Ok, I've

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

2016-12-08 Thread Chris Wilson
On Wed, Dec 07, 2016 at 07:28:10PM +0200, ville.syrj...@linux.intel.com wrote: > 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ä Spot checking didn't reveal an

[Intel-gfx] ✓ Fi.CI.BAT: success for drm: Provide a driver hook for drm_dev_release()

2016-12-08 Thread Patchwork
== Series Details == Series: drm: Provide a driver hook for drm_dev_release() URL : https://patchwork.freedesktop.org/series/16538/ State : success == Summary == Series 16538v1 drm: Provide a driver hook for drm_dev_release() https://patchwork.freedesktop.org/api/1.0/series/16538/revisions/1/m

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

2016-12-08 Thread Chris Wilson
On Wed, Dec 07, 2016 at 07:28:11PM +0200, ville.syrj...@linux.intel.com wrote: > 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ä Minor stylistic differences aside (I would rearrange the code

[Intel-gfx] [GLK MIPI DSI V1 1/9] drm/i915/glk: Add new bit fields in MIPI CTRL register

2016-12-08 Thread Madhav Chauhan
From: Deepak M Signed-off-by: Deepak M Signed-off-by: Madhav Chauhan --- drivers/gpu/drm/i915/i915_reg.h | 15 +++ 1 file changed, 15 insertions(+) diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h index 90685d2..6bd68bf 100644 --- a/drivers/gpu/drm/i9

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

2016-12-08 Thread Madhav Chauhan
The patches in this list enable MIPI DSI video mode support for GLK platform. Tesed locally. Deepak M (7): drm/i915/glk: Add new bit fields in MIPI CTRL register drm/i915/glk: Program new MIPI DSI PHY registers for GLK drm/i915/glk: Add MIPIIO Enable/disable sequence drm/i915: Set the Z in

[Intel-gfx] [GLK MIPI DSI V1 6/9] drm/i915/glk: Program MIPI_CLOCK_CTRL only for BXT

2016-12-08 Thread Madhav Chauhan
From: Deepak M Register MIPI_CLOCK_CTRL is applicable only for BXT platform. Future platform have other registers to program the escape clock dividers. Signed-off-by: Deepak M Signed-off-by: Madhav Chauhan --- drivers/gpu/drm/i915/intel_dsi_pll.c | 25 +++-- 1 file changed

[Intel-gfx] [GLK MIPI DSI V1 8/9] drm/i915/glk: Program dphy param reg for GLK

2016-12-08 Thread Madhav Chauhan
For GEMINILAKE, dphy param reg values are programmed in terms of HS byte clock while for legacy platforms in terms of ddrclk Signed-off-by: Madhav Chauhan --- drivers/gpu/drm/i915/intel_dsi_panel_vbt.c | 33 +++--- 1 file changed, 26 insertions(+), 7 deletions(-) diff --

[Intel-gfx] [GLK MIPI DSI V1 2/9] drm/i915/glk: Program new MIPI DSI PHY registers for GLK

2016-12-08 Thread Madhav Chauhan
From: Deepak M Program the clk lane and tlpx time count registers to configure DSI PHY. Signed-off-by: Deepak M Signed-off-by: Madhav Chauhan --- drivers/gpu/drm/i915/i915_reg.h | 18 ++ drivers/gpu/drm/i915/intel_dsi.c | 10 ++ 2 files changed, 28 insertions(+) diff

[Intel-gfx] [GLK MIPI DSI V1 3/9] drm/i915/glk: Add MIPIIO Enable/disable sequence

2016-12-08 Thread Madhav Chauhan
From: Deepak M Signed-off-by: Deepak M Signed-off-by: Madhav Chauhan --- drivers/gpu/drm/i915/intel_dsi.c | 130 +++ 1 file changed, 130 insertions(+) diff --git a/drivers/gpu/drm/i915/intel_dsi.c b/drivers/gpu/drm/i915/intel_dsi.c index 34bbdc2..729fcc9 10

[Intel-gfx] [GLK MIPI DSI V1 7/9] drm/i915/glk: Program txesc clock divider for GLK

2016-12-08 Thread Madhav Chauhan
From: Deepak M Txesc clock divider is calculated and programmed for geminilake platform. Signed-off-by: Deepak M Signed-off-by: Madhav Chauhan --- drivers/gpu/drm/i915/i915_reg.h | 5 +++ drivers/gpu/drm/i915/intel_dsi_pll.c | 61 ++-- 2 files changed, 64

[Intel-gfx] [GLK MIPI DSI V1 5/9] drm/i915/glk: Add DSI PLL divider range for glk

2016-12-08 Thread Madhav Chauhan
From: Deepak M PLL divider range for GLK is different than that of BXT, hence adding the GLK range check in this patch. Signed-off-by: Deepak M Signed-off-by: Madhav Chauhan --- drivers/gpu/drm/i915/i915_reg.h | 4 drivers/gpu/drm/i915/intel_dsi_pll.c | 20 ++-- 2 f

[Intel-gfx] [GLK MIPI DSI V1 9/9] drm/915: Parsing the missed out DTD fields from the VBT

2016-12-08 Thread Madhav Chauhan
From: Vincente Tsou The upper bits of the vsync width, vsync offset and hsync width were not parsed form the VBT. Parse these fields in this patch. Signed-off-by: Madhav Chauhan Signed-off-by: Vincente Tsou --- drivers/gpu/drm/i915/intel_bios.c | 8 +--- drivers/gpu/drm/i915/intel_vbt

[Intel-gfx] [GLK MIPI DSI V1 4/9] drm/i915: Set the Z inversion overlap field

2016-12-08 Thread Madhav Chauhan
From: Deepak M Dual link Z-inversion overlap field is present in MIPI_CTRL register unlike the older platforms, hence setting the same in this patch. Signed-off-by: Deepak M Signed-off-by: Madhav Chauhan --- drivers/gpu/drm/i915/intel_dsi.c | 17 + 1 file changed, 13 insertion

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

2016-12-08 Thread Daniel Vetter
On Thu, Dec 08, 2016 at 12:05:48AM +0900, Michel Dänzer wrote: > 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 calle

Re: [Intel-gfx] [PATCH 1/2] drm/i915: split off Pineview desktop and mobile device info

2016-12-08 Thread Jani Nikula
On Thu, 08 Dec 2016, Jani Nikula wrote: > On Thu, 08 Dec 2016, Jani Nikula wrote: >> This lets us use IS_MOBILE() for distinguishing the desktop and mobile >> parts instead of duplicating PCI IDs in Pineview specific checks. > > This probably needs more thorough review of the !IS_MOBILE() paths i

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

2016-12-08 Thread Weng, Chuanbo
I'm interesting in how mesa set related cache ability. Take kmscube(https://github.com/robclark/kmscube.git) as an example, mesa and drm do similar things: gbm_surface_create to create gbm_surface eglCreateWindowSurface to create EGLSurface eglMakeCurrent to bind context to

[Intel-gfx] ✓ Fi.CI.BAT: success for GLK MIPI DSI VIDEO MODE PATCHES

2016-12-08 Thread Patchwork
== Series Details == Series: GLK MIPI DSI VIDEO MODE PATCHES URL : https://patchwork.freedesktop.org/series/16542/ State : success == Summary == Series 16542v1 GLK MIPI DSI VIDEO MODE PATCHES https://patchwork.freedesktop.org/api/1.0/series/16542/revisions/1/mbox/ fi-bdw-5557u total:247

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

2016-12-08 Thread Jani Nikula
From: Vidya Srinivas Currently the backlight controller is taken as 0. It needs to derive value from the VBT. Adding the necessary changes. v2 by Jani: - drop obsolete comments, drop redundant initialization (Bob) - merge debug logging into one Signed-off-by: Uma Shankar Signed-off-by: Vidya

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

2016-12-08 Thread Chris Wilson
On Wed, Dec 07, 2016 at 07:28:12PM +0200, ville.syrj...@linux.intel.com wrote: > 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 cl

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

2016-12-08 Thread Chris Wilson
On Wed, Dec 07, 2016 at 07:28:06PM +0200, ville.syrj...@linux.intel.com wrote: > 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

[Intel-gfx] [PATCH 0/3] Claw back the IS_ optimisation

2016-12-08 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Reorganise the IS_ code a bit inspired by the pre-processor code generation as used by Chris in the self test patches. This avoids some source code duplication and makes maintenance easier. In the last patch try to claw back the multiple IS_ optimisation, as the commit mess

[Intel-gfx] [PATCH 1/3] drm/i915: Introduct i915_platforms.h

2016-12-08 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Inspired by the same approach used by Chris Wilson in the self test patches. We add a separate header file containing the list of our platforms and then use the pre-processor to generate all other places which use that list. This avoids having to list them multiple times and

[Intel-gfx] [PATCH 2/3] drm/i915: Generate all IS_ macros

2016-12-08 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Instead of listing them individually we can generate them using the new i915_platforms.h header. Also convert them to a static inline function which interestingly makes the code smaller as well. Signed-off-by: Tvrtko Ursulin Cc: Chris Wilson Cc: Jani Nikula Cc: Joonas La

[Intel-gfx] [PATCH 3/3] drm/i915: Number the platform enum strategically

2016-12-08 Thread Tvrtko Ursulin
From: Tvrtko Ursulin If we use only power of two values for the platform enum values we can let the compiler optimize some common checks to a single conditional. For example code like this: if (IS_VALLEYVIEW(dev_priv) || IS_CHERRYVIEW(dev_priv)) Goes from this: 5c3c5: 8b 83 d

Re: [Intel-gfx] [PATCH 3/3] drm/i915: Number the platform enum strategically

2016-12-08 Thread Chris Wilson
On Thu, Dec 08, 2016 at 09:49:59AM +, Tvrtko Ursulin wrote: > From: Tvrtko Ursulin > > If we use only power of two values for the platform enum > values we can let the compiler optimize some common > checks to a single conditional. > > For example code like this: > > if (IS_VALLEYVIEW

Re: [Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: Shrink pipe config checker (rev2)

2016-12-08 Thread Tvrtko Ursulin
On 06/12/2016 11:15, Patchwork wrote: == Series Details == Series: drm/i915: Shrink pipe config checker (rev2) URL : https://patchwork.freedesktop.org/series/16359/ State : success == Summary == Series 16359v2 drm/i915: Shrink pipe config checker https://patchwork.freedesktop.org/api/1.0/se

[Intel-gfx] [PULL] drm-misc-next

2016-12-08 Thread Daniel Vetter
Hi Dave, Another pile of misc stuff, final one for 4.10. If there's some serious bugfix still I'll send you a pull for drm-misc-next-fixes (like we do with intel), otherwise this is it and next pull next year for 4.11. Most interesting bits are probably Chris' fb helper fixes against mst hotplug

[Intel-gfx] ✓ Fi.CI.BAT: success for FOR_UPSTREAM [VPG]: drm/i915: Parse panel BL controller from VBT (rev4)

2016-12-08 Thread Patchwork
== Series Details == Series: FOR_UPSTREAM [VPG]: drm/i915: Parse panel BL controller from VBT (rev4) URL : https://patchwork.freedesktop.org/series/16489/ State : success == Summary == Series 16489v4 FOR_UPSTREAM [VPG]: drm/i915: Parse panel BL controller from VBT https://patchwork.freedesktop

[Intel-gfx] [PATCH] drm: Update drm_device docs about embedding.

2016-12-08 Thread Daniel Vetter
It's supported now! Spotted while reviewing Chris' patch to add a release hook. Cc: Chris Wilson Signed-off-by: Daniel Vetter --- drivers/gpu/drm/drm_drv.c | 11 +++ 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c index

Re: [Intel-gfx] [PATCH] drm: Provide a driver hook for drm_dev_release()

2016-12-08 Thread Daniel Vetter
On Thu, Dec 08, 2016 at 08:18:40AM +, Chris Wilson wrote: > Some state is coupled into the device lifetime outside of the > load/unload timeframe and requires teardown during final unreference > from drm_dev_release(). For example, dmabufs hold both a device and > module reference and may live

Re: [Intel-gfx] [PATCH 1/3] drm/i915: Introduct i915_platforms.h

2016-12-08 Thread Jani Nikula
On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: > From: Tvrtko Ursulin > > Inspired by the same approach used by Chris Wilson in the self > test patches. > > We add a separate header file containing the list of our > platforms and then use the pre-processor to generate all > other places which use tha

Re: [Intel-gfx] [PATCH 2/3] drm/i915: Generate all IS_ macros

2016-12-08 Thread Jani Nikula
On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: > From: Tvrtko Ursulin > > Instead of listing them individually we can generate them > using the new i915_platforms.h header. > > Also convert them to a static inline function which > interestingly makes the code smaller as well. > > Signed-off-by: Tvrtk

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

2016-12-08 Thread Tvrtko Ursulin
On 07/12/2016 13:58, Chris Wilson wrote: 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

[Intel-gfx] [PATCH] drm/i915: Respect ring_mask and num_pipes when install IRQ

2016-12-08 Thread Wang Elaine
From: Elaine Wang Some platforms only have VCS ring in VDBox. To avoid accessing the non-existent rings or display registers, check the ring_mask and num_pipes in gen8 IRQ install and reset functions. Cc: Joonas Lahtinen Signed-off-by: Elaine Wang --- drivers/gpu/drm/i915/i915_irq.c | 22

Re: [Intel-gfx] [PATCH] drm: Update drm_device docs about embedding.

2016-12-08 Thread Chris Wilson
On Thu, Dec 08, 2016 at 11:28:47AM +0100, Daniel Vetter wrote: > It's supported now! Spotted while reviewing Chris' patch to add a > release hook. > > Cc: Chris Wilson > Signed-off-by: Daniel Vetter > --- > drivers/gpu/drm/drm_drv.c | 11 +++ > 1 file changed, 7 insertions(+), 4 deletio

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

2016-12-08 Thread Tvrtko Ursulin
On 07/12/2016 13:58, Chris Wilson wrote: 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 +++

Re: [Intel-gfx] [lkp] [PATCH] drm/i915: Fix intel_psr_init() kerneldoc

2016-12-08 Thread Ander Conselvan De Oliveira
On Tue, 2016-12-06 at 02:01 +0800, Ye Xiaolong wrote: > On 11/30, Ander Conselvan De Oliveira wrote: > > > > On Wed, 2016-11-30 at 09:29 +0800, kbuild test robot wrote: > > > > > > Hi Ander, > > > > > > [auto build test WARNING on drm-intel/for-linux-next] > > > [also build test WARNING on v4.9-

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

2016-12-08 Thread Chris Wilson
On Thu, Dec 08, 2016 at 10:47:52AM +, Tvrtko Ursulin wrote: > On 07/12/2016 13:58, Chris Wilson wrote: > >-return i915_driver_load(pdev, ent); > >+err = i915_driver_load(pdev, ent); > >+if (err) > >+return err; > >+ > >+err = i915_late_selftests(pdev); > >+if (er

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

2016-12-08 Thread Tvrtko Ursulin
On 07/12/2016 13:58, Chris Wilson wrote: 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 in

Re: [Intel-gfx] [PATCH] drm: Update drm_device docs about embedding.

2016-12-08 Thread Daniel Vetter
On Thu, Dec 08, 2016 at 10:50:48AM +, Chris Wilson wrote: > On Thu, Dec 08, 2016 at 11:28:47AM +0100, Daniel Vetter wrote: > > It's supported now! Spotted while reviewing Chris' patch to add a > > release hook. > > > > Cc: Chris Wilson > > Signed-off-by: Daniel Vetter > > --- > > drivers/gp

[Intel-gfx] ✓ Fi.CI.BAT: success for Claw back the IS_ optimisation

2016-12-08 Thread Patchwork
== Series Details == Series: Claw back the IS_ optimisation URL : https://patchwork.freedesktop.org/series/16544/ State : success == Summary == Series 16544v1 Claw back the IS_ optimisation https://patchwork.freedesktop.org/api/1.0/series/16544/revisions/1/mbox/ fi-bdw-5557u total:247 p

Re: [Intel-gfx] [RFC v2] drm: Enable dynamic debug for DRM_[DEV]_DEBUG*

2016-12-08 Thread Robert Bragg
On Thu, Dec 8, 2016 at 12:17 AM, Daniel Vetter wrote: > > On Wed, Dec 07, 2016 at 06:35:29PM +, Robert Bragg wrote: > > This is still missing corresponding documentation changes, and I haven't > > moved anything to drm_print.h yet, as suggested. > > > > Sending out with a few functional improv

Re: [Intel-gfx] [PATCH 1/2] drm/i915: Move uncore selfchecks to late selftest infrastructure

2016-12-08 Thread Tvrtko Ursulin
On 07/12/2016 18:52, Chris Wilson wrote: Now that the kselftest infrastructure exists, put it to use and add to it the existing consistency checks on the fw register lookup tables. Signed-off-by: Chris Wilson Cc: Tvrtko Ursulin --- drivers/gpu/drm/i915/i915_late_selftests.h | 1 + drivers/

Re: [Intel-gfx] [PATCH] drm: Update drm_device docs about embedding.

2016-12-08 Thread Chris Wilson
On Thu, Dec 08, 2016 at 12:53:07PM +0100, Daniel Vetter wrote: > On Thu, Dec 08, 2016 at 10:50:48AM +, Chris Wilson wrote: > > On Thu, Dec 08, 2016 at 11:28:47AM +0100, Daniel Vetter wrote: > > > It's supported now! Spotted while reviewing Chris' patch to add a > > > release hook. > > > > > >

Re: [Intel-gfx] [PATCH 2/2] drm/i915: Test all fw tables during mock selftests

2016-12-08 Thread Tvrtko Ursulin
On 07/12/2016 18:52, Chris Wilson wrote: In addition to just testing the fw table we load, during the initial mock testing we can test that all tables are valid (so the testing is not limited to just the platforms that load that particular table). Signed-off-by: Chris Wilson Cc: Tvrtko Ursulin

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: Use DRM_DEV_ERROR in i915_driver_load

2016-12-08 Thread Patchwork
== Series Details == Series: drm/i915: Use DRM_DEV_ERROR in i915_driver_load URL : https://patchwork.freedesktop.org/series/16441/ State : success == Summary == Series 16441v1 drm/i915: Use DRM_DEV_ERROR in i915_driver_load https://patchwork.freedesktop.org/api/1.0/series/16441/revisions/1/mbo

Re: [Intel-gfx] [PATCH 2/2] drm/i915: Test all fw tables during mock selftests

2016-12-08 Thread Chris Wilson
On Thu, Dec 08, 2016 at 12:14:10PM +, Tvrtko Ursulin wrote: > >-static int intel_fw_table_check(struct drm_i915_private *i915) > >+static int intel_fw_table_check(const struct intel_forcewake_range *ranges, > >+unsigned int num_ranges, > >+

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

2016-12-08 Thread Tvrtko Ursulin
On 08/12/2016 11:15, Chris Wilson wrote: On Thu, Dec 08, 2016 at 10:47:52AM +, Tvrtko Ursulin wrote: On 07/12/2016 13:58, Chris Wilson wrote: - return i915_driver_load(pdev, ent); + err = i915_driver_load(pdev, ent); + if (err) + return err; + + err =

Re: [Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: Use DRM_DEV_ERROR in i915_driver_load

2016-12-08 Thread Tvrtko Ursulin
On 08/12/2016 12:15, Patchwork wrote: == Series Details == Series: drm/i915: Use DRM_DEV_ERROR in i915_driver_load URL : https://patchwork.freedesktop.org/series/16441/ State : success == Summary == Series 16441v1 drm/i915: Use DRM_DEV_ERROR in i915_driver_load https://patchwork.freedesktop

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

2016-12-08 Thread Chris Wilson
On Thu, Dec 08, 2016 at 12:30:23PM +, Tvrtko Ursulin wrote: > But you agree on the point of validating that subtest do not return > positive error codes in order not to interfere with the behaviour > set by module parameters? Yup, checking that the tests don't return our magic values is a good

Re: [Intel-gfx] [PATCH] drm: Take ownership of the dmabuf->obj when exporting

2016-12-08 Thread Joonas Lahtinen
On ke, 2016-12-07 at 21:45 +, Chris Wilson wrote: > Currently the reference for the dmabuf->obj is incremented for the > dmabuf in drm_gem_prime_handle_to_fd() (at the high level userspace > interface), but is released in drm_gem_dmabuf_release() (the lowlevel > handler). Improve the symmetry o

Re: [Intel-gfx] [PATCH 2/2] drm/i915: Test all fw tables during mock selftests

2016-12-08 Thread Joonas Lahtinen
On ke, 2016-12-07 at 18:52 +, Chris Wilson wrote: > In addition to just testing the fw table we load, during the initial > mock testing we can test that all tables are valid (so the testing is > not limited to just the platforms that load that particular table). > > Signed-off-by: Chris Wilson

[Intel-gfx] [PATCH] drm/edid: Don't print an error if the checksum of a CEA block is wrong

2016-12-08 Thread Tomeu Vizoso
It's common to share screens within CI labs, and it's also common for KVM switches to alter the contents of the CEA block but leave the checksum outdated. So in this case, print a debug message instead of an error. References: https://bugs.freedesktop.org/show_bug.cgi?id=98228 Cc: Chris Wilson C

Re: [Intel-gfx] [PATCH 1/3] drm/i915: Introduct i915_platforms.h

2016-12-08 Thread Joonas Lahtinen
On to, 2016-12-08 at 12:41 +0200, Jani Nikula wrote: > > On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: > > > > From: Tvrtko Ursulin > > > > Inspired by the same approach used by Chris Wilson in the self > > test patches. > > > > We add a separate header file containing the list of our > > platfor

Re: [Intel-gfx] [RFC v2] drm: Enable dynamic debug for DRM_[DEV]_DEBUG*

2016-12-08 Thread Tvrtko Ursulin
Hi, On 07/12/2016 18:35, Robert Bragg wrote: This is still missing corresponding documentation changes, and I haven't moved anything to drm_print.h yet, as suggested. Sending out with a few functional improvements first to get agreement before documenting anything (changes summarised in v2: se

Re: [Intel-gfx] [PATCH 1/3] drm/i915: Introduct i915_platforms.h

2016-12-08 Thread Tvrtko Ursulin
On 08/12/2016 13:16, Joonas Lahtinen wrote: On to, 2016-12-08 at 12:41 +0200, Jani Nikula wrote: On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Inspired by the same approach used by Chris Wilson in the self test patches. We add a separate header file containing the list of

Re: [Intel-gfx] [PATCH 2/3] drm/i915: Generate all IS_ macros

2016-12-08 Thread Tvrtko Ursulin
On 08/12/2016 10:46, Jani Nikula wrote: On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Instead of listing them individually we can generate them using the new i915_platforms.h header. Also convert them to a static inline function which interestingly makes the code smaller a

Re: [Intel-gfx] [PATCH] drm/i915: Respect ring_mask and num_pipes when install IRQ

2016-12-08 Thread Joonas Lahtinen
On to, 2016-12-08 at 18:46 +0800, Wang Elaine wrote: > > From: Elaine Wang > > Some platforms only have VCS ring in VDBox. To avoid accessing the > non-existent rings or display registers, check the ring_mask > and num_pipes in gen8 IRQ install and reset functions. > > Cc: Joonas Lahtinen > Sig

Re: [Intel-gfx] [PATCH 2/3] drm/i915: Generate all IS_ macros

2016-12-08 Thread Jani Nikula
On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: > On 08/12/2016 10:46, Jani Nikula wrote: >> On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: >>> From: Tvrtko Ursulin >>> >>> Instead of listing them individually we can generate them >>> using the new i915_platforms.h header. >>> >>> Also convert them to a

[Intel-gfx] [PATCH v2] drm/i915: Number the platform enum strategically

2016-12-08 Thread Tvrtko Ursulin
From: Tvrtko Ursulin If we use only power of two values for the platform enum values we can let the compiler optimize some common checks to a single conditional. For example code like this: if (IS_VALLEYVIEW(dev_priv) || IS_CHERRYVIEW(dev_priv)) Goes from this: 5c3c5: 8b 83 d

Re: [Intel-gfx] [PATCH 2/3] drm/i915: Generate all IS_ macros

2016-12-08 Thread Jani Nikula
On Thu, 08 Dec 2016, Jani Nikula wrote: > On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: >> On 08/12/2016 10:46, Jani Nikula wrote: >>> On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Instead of listing them individually we can generate them using the new i915_pl

Re: [Intel-gfx] [PATCH 2/3] drm/i915: Generate all IS_ macros

2016-12-08 Thread Tvrtko Ursulin
On 08/12/2016 13:37, Jani Nikula wrote: On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: On 08/12/2016 10:46, Jani Nikula wrote: On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Instead of listing them individually we can generate them using the new i915_platforms.h header. Also

[Intel-gfx] [PATCH 2/6] drm/atomic: Unconditionally call prepare_fb.

2016-12-08 Thread Maarten Lankhorst
Atomic drivers may set properties like rotation on the same fb, which may require a call to prepare_fb even when framebuffer stays identical. Instead of handling all the special cases in the core, let the driver decide when prepare_fb and cleanup_fb are noops. Signed-off-by: Maarten Lankhorst --

[Intel-gfx] [PATCH 1/6] drm/atomic: Use active instead of enable in wait_for_vblanks.

2016-12-08 Thread Maarten Lankhorst
When DPMS was introduced to atomic, vblanks only worked when the crtc was enabled and active. wait_for_vblanks were not converted to check for crtc_state->active, which may cause an attempt for vblank_get to fail. This is probably harmless, but convert from enable to active anyway. Signed-off-by:

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

2016-12-08 Thread Maarten Lankhorst
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 cursor will still fall back so watermarks can be updated. Only moving and chang

[Intel-gfx] [PATCH 3/6] drm/atomic: Clean up wait_for_vblanks

2016-12-08 Thread Maarten Lankhorst
Stop relying on a per crtc_state last_vblank_count, we know in advance how many there can be. Also stop re-using new_crtc_state->enable, we can now simply set a bitmask with crtc_crtc_mask. --- drivers/gpu/drm/drm_atomic_helper.c | 29 +++-- include/drm/drm_crtc.h

[Intel-gfx] [PATCH 0/6] drm/atomic: Remove drm_atomic_helper_framebuffer_changed

2016-12-08 Thread Maarten Lankhorst
drm_atomic_helpers use framebuffer_changed to skip some vblank waits in case properties don't change. This may skip vblank waits also when properties like rotation are changed. Fix this by always waiting for vblank if planes are added to the state, and always calling prepare_fb even when fb stays t

[Intel-gfx] [PATCH 4/6] drm/atomic: Wait for vblank whenever a plane is added to state.

2016-12-08 Thread Maarten Lankhorst
The current api doesn't take into account that whenever properties like rotation or z-pos change we have to wait for vblank. To make sure that we wait correctly, err on the side of caution and wait whenever a plane is added to state. Signed-off-by: Maarten Lankhorst --- drivers/gpu/drm/drm_atomi

[Intel-gfx] [PATCH 5/6] drm/atomic: Remove drm_atomic_helper_framebuffer_changed.

2016-12-08 Thread Maarten Lankhorst
This function is now completely unused, zap it. Signed-off-by: Maarten Lankhorst --- drivers/gpu/drm/drm_atomic_helper.c | 35 --- include/drm/drm_atomic_helper.h | 3 --- 2 files changed, 38 deletions(-) diff --git a/drivers/gpu/drm/drm_atomic_helper.c b/d

Re: [Intel-gfx] [PATCH 2/3] drm/i915: Generate all IS_ macros

2016-12-08 Thread Jani Nikula
On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: > On 08/12/2016 13:37, Jani Nikula wrote: >> On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: >>> On 08/12/2016 10:46, Jani Nikula wrote: On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: > From: Tvrtko Ursulin > > Instead of listing them individua

Re: [Intel-gfx] [PATCH v6 1/2] drm/i915/gen9: Fix PCODE polling during CDCLK change notification

2016-12-08 Thread Chris Wilson
On Mon, Dec 05, 2016 at 06:27:37PM +0200, Imre Deak wrote: > commit 848496e5902833600f7992f4faa82dc1546051ba > Author: Ville Syrjälä > Date: Wed Jul 13 16:32:03 2016 +0300 > > drm/i915: Wait up to 3ms for the pcu to ack the cdclk change request on > SKL > > increased the timeout to match

Re: [Intel-gfx] [RFC v2] drm: Enable dynamic debug for DRM_[DEV]_DEBUG*

2016-12-08 Thread Daniel Vetter
On Thu, Dec 08, 2016 at 11:57:25AM +, Robert Bragg wrote: > On Thu, Dec 8, 2016 at 12:17 AM, Daniel Vetter wrote: > > > > On Wed, Dec 07, 2016 at 06:35:29PM +, Robert Bragg wrote: > > > This is still missing corresponding documentation changes, and I haven't > > > moved anything to drm_pri

Re: [Intel-gfx] [PATCH] drm: Take ownership of the dmabuf->obj when exporting

2016-12-08 Thread Daniel Vetter
On Thu, Dec 08, 2016 at 03:03:29PM +0200, Joonas Lahtinen wrote: > On ke, 2016-12-07 at 21:45 +, Chris Wilson wrote: > > Currently the reference for the dmabuf->obj is incremented for the > > dmabuf in drm_gem_prime_handle_to_fd() (at the high level userspace > > interface), but is released in

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

2016-12-08 Thread Matthew Auld
On 8 December 2016 at 13:45, 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 cursor will still

Re: [Intel-gfx] [PATCH 2/3] drm/i915: Generate all IS_ macros

2016-12-08 Thread Tvrtko Ursulin
On 08/12/2016 14:00, Jani Nikula wrote: On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: On 08/12/2016 13:37, Jani Nikula wrote: On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: On 08/12/2016 10:46, Jani Nikula wrote: On Thu, 08 Dec 2016, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Instead of listi

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: Respect ring_mask and num_pipes when install IRQ

2016-12-08 Thread Patchwork
== Series Details == Series: drm/i915: Respect ring_mask and num_pipes when install IRQ URL : https://patchwork.freedesktop.org/series/16547/ State : success == Summary == Series 16547v1 drm/i915: Respect ring_mask and num_pipes when install IRQ https://patchwork.freedesktop.org/api/1.0/series

Re: [Intel-gfx] [PATCH v6 1/2] drm/i915/gen9: Fix PCODE polling during CDCLK change notification

2016-12-08 Thread Imre Deak
On to, 2016-12-08 at 14:02 +, Chris Wilson wrote: > On Mon, Dec 05, 2016 at 06:27:37PM +0200, Imre Deak wrote: > > commit 848496e5902833600f7992f4faa82dc1546051ba > > Author: Ville Syrjälä > > Date:   Wed Jul 13 16:32:03 2016 +0300 > > > > drm/i915: Wait up to 3ms for the pcu to ack the c

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

2016-12-08 Thread kbuild test robot
Hi Ville, [auto build test WARNING on drm-intel/for-linux-next] [also build test WARNING on next-20161208] [cannot apply to v4.9-rc8] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/ville

Re: [Intel-gfx] [PATCH v6 1/2] drm/i915/gen9: Fix PCODE polling during CDCLK change notification

2016-12-08 Thread Chris Wilson
On Thu, Dec 08, 2016 at 04:18:50PM +0200, Imre Deak wrote: > Yep. Btw, I also pondered if we could just make this part of > wait_for(), but not sure if we want the corresponding code increase > (and for -stable we'd want a minimal diff). It's not required in other > cases, although it could speed u

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

2016-12-08 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] ✗ Fi.CI.BAT: warning for drm/edid: Don't print an error if the checksum of a CEA block is wrong

2016-12-08 Thread Patchwork
== Series Details == Series: drm/edid: Don't print an error if the checksum of a CEA block is wrong URL : https://patchwork.freedesktop.org/series/16556/ State : warning == Summary == Series 16556v1 drm/edid: Don't print an error if the checksum of a CEA block is wrong https://patchwork.freed

Re: [Intel-gfx] [PATCH v4 1/4] drm: Add a new connector atomic property for link status

2016-12-08 Thread Jani Nikula
On Tue, 06 Dec 2016, Manasi Navare wrote: > At the time userspace does setcrtc, we've already promised the mode > would work. The promise is based on the theoretical capabilities of > the link, but it's possible we can't reach this in practice. The DP > spec describes how the link should be reduce

[Intel-gfx] ✗ Fi.CI.BAT: warning for Claw back the IS_ optimisation (rev2)

2016-12-08 Thread Patchwork
== Series Details == Series: Claw back the IS_ optimisation (rev2) URL : https://patchwork.freedesktop.org/series/16544/ State : warning == Summary == Series 16544v2 Claw back the IS_ optimisation https://patchwork.freedesktop.org/api/1.0/series/16544/revisions/2/mbox/ Test drv_module_reload:

Re: [Intel-gfx] [PATCH v4 1/4] drm: Add a new connector atomic property for link status

2016-12-08 Thread Daniel Vetter
On Thu, Dec 08, 2016 at 05:05:54PM +0200, Jani Nikula wrote: > On Tue, 06 Dec 2016, Manasi Navare wrote: > > At the time userspace does setcrtc, we've already promised the mode > > would work. The promise is based on the theoretical capabilities of > > the link, but it's possible we can't reach th

Re: [Intel-gfx] [PATCH 4/8] drm/i915/huc: Add BXT HuC Loading Support

2016-12-08 Thread Jeff McGee
On Mon, Dec 05, 2016 at 12:42:11PM -0800, Srivatsa, Anusha wrote: > > > >-Original Message- > >From: Tvrtko Ursulin [mailto:tvrtko.ursu...@linux.intel.com] > >Sent: Thursday, December 1, 2016 5:11 AM > >To: Srivatsa, Anusha ; intel- > >g...@lists.freedesktop.org > >Subject: Re: [Intel-gfx

Re: [Intel-gfx] [PATCH 1/6] drm/atomic: Use active instead of enable in wait_for_vblanks.

2016-12-08 Thread Daniel Vetter
On Thu, Dec 08, 2016 at 02:45:24PM +0100, Maarten Lankhorst wrote: > When DPMS was introduced to atomic, vblanks only worked when the crtc > was enabled and active. wait_for_vblanks were not converted to check for > crtc_state->active, which may cause an attempt for vblank_get to fail. > > This is

Re: [Intel-gfx] [PATCH 3/6] drm/atomic: Clean up wait_for_vblanks

2016-12-08 Thread Daniel Vetter
On Thu, Dec 08, 2016 at 02:45:26PM +0100, Maarten Lankhorst wrote: > Stop relying on a per crtc_state last_vblank_count, we know in advance > how many there can be. Also stop re-using new_crtc_state->enable, > we can now simply set a bitmask with crtc_crtc_mask. > --- > drivers/gpu/drm/drm_atomic_

Re: [Intel-gfx] [PATCH 2/6] drm/atomic: Unconditionally call prepare_fb.

2016-12-08 Thread Daniel Vetter
On Thu, Dec 08, 2016 at 02:45:25PM +0100, Maarten Lankhorst wrote: > Atomic drivers may set properties like rotation on the same fb, which > may require a call to prepare_fb even when framebuffer stays identical. > > Instead of handling all the special cases in the core, let the driver > decide wh

Re: [Intel-gfx] [PATCH 4/6] drm/atomic: Wait for vblank whenever a plane is added to state.

2016-12-08 Thread Daniel Vetter
On Thu, Dec 08, 2016 at 02:45:27PM +0100, Maarten Lankhorst wrote: > The current api doesn't take into account that whenever properties like > rotation or z-pos change we have to wait for vblank. To make sure > that we wait correctly, err on the side of caution and wait whenever > a plane is added

Re: [Intel-gfx] ✗ Fi.CI.BAT: warning for drm/edid: Don't print an error if the checksum of a CEA block is wrong

2016-12-08 Thread Saarinen, Jani
> == Series Details == > > Series: drm/edid: Don't print an error if the checksum of a CEA block is wrong > URL : https://patchwork.freedesktop.org/series/16556/ > State : warning > > == Summary == > > Series 16556v1 drm/edid: Don't print an error if the checksum of a CEA block > is > wrong >

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/atomic: Remove drm_atomic_helper_framebuffer_changed

2016-12-08 Thread Patchwork
== Series Details == Series: drm/atomic: Remove drm_atomic_helper_framebuffer_changed URL : https://patchwork.freedesktop.org/series/16561/ State : success == Summary == Series 16561v1 drm/atomic: Remove drm_atomic_helper_framebuffer_changed https://patchwork.freedesktop.org/api/1.0/series/165

Re: [Intel-gfx] [PATCH] drm/i915/perf: More documentation hooked to i915.rst

2016-12-08 Thread Daniel Vetter
On Wed, Dec 07, 2016 at 09:40:33PM +, Robert Bragg wrote: > This adds a 'Perf' section to i915.rst with the following sub sections: > - Overview > - Comparison with Core Perf > - i915 Driver Entry Points > - i915 Perf Stream > - i915 Perf Observation Architecture Stream > - All i915 Perf Intern

Re: [Intel-gfx] [PATCH 1/2] drm/i915: split off Pineview desktop and mobile device info

2016-12-08 Thread Daniel Vetter
On Thu, Dec 08, 2016 at 11:11:50AM +0200, Jani Nikula wrote: > On Thu, 08 Dec 2016, Jani Nikula wrote: > > On Thu, 08 Dec 2016, Jani Nikula wrote: > >> This lets us use IS_MOBILE() for distinguishing the desktop and mobile > >> parts instead of duplicating PCI IDs in Pineview specific checks. > >

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

2016-12-08 Thread Ville Syrjälä
On Wed, Dec 07, 2016 at 07:51:21PM -0800, Manasi Navare wrote: > Ville, > You mentioned that this detect_done should be set to false also > in the resume case so in i915_display_resume where it calls > intel_hpd_init that eventually schedules the hpd_poll_init_work and > calls drm_helper_hpd_irq_ev

Re: [Intel-gfx] [PATCH v7 0/8] GEN-9 Arbitrated Bandwidth WM WA's & IPC

2016-12-08 Thread Daniel Vetter
On Wed, Dec 07, 2016 at 05:35:09PM -0200, Paulo Zanoni wrote: > Em Qui, 2016-12-01 às 21:19 +0530, Mahesh Kumar escreveu: > > This series implements following set of functionality > > Implement IPC WA's for Broxton/KBL > > Enable IPC in supported platforms > > Convert WM calculation to

Re: [Intel-gfx] [PATCH i-g-t] igt_kms: Remove support for drivers with <1 drm_plane

2016-12-08 Thread Daniel Vetter
On Wed, Dec 07, 2016 at 07:16:13PM -0500, Lyude wrote: > We've had support for universal planes since kernel version 3.15, so > there's not really a good reason to try supporting drivers that lack > plane support now. As well, the current has_universal_planes logic is > broken anyway as it makes th

  1   2   >