Re: [Intel-gfx] [PATCH] drm/i915: mdelay(10) considered harmful

2015-12-16 Thread Daniel Vetter
On Mon, Dec 14, 2015 at 02:07:23PM +0530, Jindal, Sonika wrote: > %s/cpy/cpu > > Reviewed-by: Sonika Jindal Queued for -next, thanks for the review. -Daniel > > On 12/12/2015 12:14 AM, Daniel Vetter wrote: > >I missed this myself when reviewing > > > >commit 237ed86c693d8a8e4db476976aeb30df4de

Re: [Intel-gfx] [PATCH] drm/i915: Allow userspace to request no-error-capture upon GPU hangs

2015-12-16 Thread Daniel Vetter
On Fri, Dec 11, 2015 at 10:18:35PM +, Chris Wilson wrote: > igt likes to inject GPU hangs into its command streams. However, as we > expect these hangs, we don't actually want them recorded in the dmesg > output or stored in the i915_error_state (usually). To accomodate this > allow userspace t

Re: [Intel-gfx] [PATCH 07/10] drm/i915: Allow 27 bytes child_dev for VBT <109

2015-12-16 Thread Jani Nikula
On Mon, 14 Dec 2015, ville.syrj...@linux.intel.com wrote: > From: Ville Syrjälä > > My 85x has VBT version 108 which has a child dev size of 27 bytes. > Let's allow that without printing an error. > > We still want to reject the actual parsin since for that we need > the child device size to be at

Re: [Intel-gfx] [PATCH 08/10] drm/i915: Expect child dev size of 22 bytes for VBT < 106

2015-12-16 Thread Jani Nikula
On Mon, 14 Dec 2015, ville.syrj...@linux.intel.com wrote: > From: Ville Syrjälä > > My 830 has VBT version 105 with child device size of 22 bytes. > Let's assume that's correct and adjust our expectations. > > Signed-off-by: Ville Syrjälä Let's see what blows up... Acked-by: Jani Nikula > -

Re: [Intel-gfx] [PATCH igt 3/9] igt/drv_hangman: Inject a true hang

2015-12-16 Thread Daniel Vetter
On Sat, Dec 12, 2015 at 08:02:49PM +, Chris Wilson wrote: > Wean drv_hangman off the atrocious stop_rings and use a real GPU hang > instead. > > Signed-off-by: Chris Wilson Doesn't this kill pre-gen6? Or at least anything where we don't have proper hang recovery ... Lack of that is why I've

Re: [Intel-gfx] [PATCH 1/1] drm/i915: Enable HAS_RUNTIME_PM for BXT

2015-12-16 Thread Daniel Vetter
On Sun, Dec 13, 2015 at 08:37:04PM +0530, Sagar Arun Kamble wrote: > From: Sagar Kamble > > With BXT, now all platforms from GEN6 to GEN9 support Runtime PM except IVB. > > Cc: Paulo Zanoni > Cc: Imre Deak > Change-Id: I700bf5092d6462b64499d876efeaea9dfa540380 > Signed-off-by: A.Sunil Kamath

Re: [Intel-gfx] [maintainer-tools PATCH] drm-intel: embed wavedrom engine and skin into the web page

2015-12-16 Thread Jani Nikula
On Tue, 08 Dec 2015, Jani Nikula wrote: > The wavedrom timeline will be missing from html pages served over https > due to "mixed active content" blocking [1], because the wavedrom engine > and skin are only available over http. Embed the engine and skin into > the resulting html to avoid the prob

Re: [Intel-gfx] [PATCH i-g-t v3] gem_flink_race/prime_self_import: Improve test reliability

2015-12-16 Thread Daniel Vetter
On Mon, Dec 14, 2015 at 09:59:17AM +, Derek Morton wrote: > gem_flink_race and prime_self_import have subtests which read the > number of open gem objects from debugfs to determine if objects have > leaked during the test. However the test can fail sporadically if > the number of gem objects ch

Re: [Intel-gfx] [PATCH 04/32] drm/i915: Hide the atomic_read(reset_counter) behind a helper

2015-12-16 Thread Daniel Vetter
On Fri, Dec 11, 2015 at 11:33:00AM +, Chris Wilson wrote: > This is principally a little bit of syntatic sugar to hide the > atomic_read()s throughout the code to retrieve the current reset_counter. > It also provides the other utility functions to check the reset state on the > already read re

Re: [Intel-gfx] [PATCH 05/32] drm/i915: Simplify checking of GPU reset_counter in display pageflips

2015-12-16 Thread Daniel Vetter
On Fri, Dec 11, 2015 at 11:33:01AM +, Chris Wilson wrote: > If we, when we store the reset_counter for the operation, we ensure that > it is not in a wedged or in the middle of a reset, we can then assert that > if any reset occurs the reset_counter must change. Later we can just > compare the

Re: [Intel-gfx] [PATCH 04/32] drm/i915: Hide the atomic_read(reset_counter) behind a helper

2015-12-16 Thread Daniel Vetter
Hit send too early ;-) On Fri, Dec 11, 2015 at 11:33:00AM +, Chris Wilson wrote: > @@ -4133,7 +4133,7 @@ i915_gem_ring_throttle(struct drm_device *dev, struct > drm_file *file) > > target = request; > } > - reset_counter = atomic_read(&dev_priv->gpu_error.reset_count

Re: [Intel-gfx] [PATCH 06/32] drm/i915: Tighten reset_counter for reset status

2015-12-16 Thread Daniel Vetter
On Fri, Dec 11, 2015 at 11:33:02AM +, Chris Wilson wrote: > In the reset_counter, we use two bits to track a GPU hang and reset. The > low bit is a "reset-in-progress" flag that we set to signal when we need > to break waiters in order for the recovery task to grab the mutex. As > soon as the r

Re: [Intel-gfx] [PATCH 04/32] drm/i915: Hide the atomic_read(reset_counter) behind a helper

2015-12-16 Thread Daniel Vetter
On Wed, Dec 16, 2015 at 10:33:32AM +0100, Daniel Vetter wrote: > Hit send too early ;-) > > On Fri, Dec 11, 2015 at 11:33:00AM +, Chris Wilson wrote: > > @@ -4133,7 +4133,7 @@ i915_gem_ring_throttle(struct drm_device *dev, struct > > drm_file *file) > > > > target = request; > >

Re: [Intel-gfx] [PATCH 11/11] drm/i915/opregion: handle VBT sizes bigger than 6 KB

2015-12-16 Thread Jani Nikula
On Tue, 15 Dec 2015, Ville Syrjälä wrote: > On Mon, Dec 14, 2015 at 04:34:34PM +0200, Ville Syrjälä wrote: >> On Mon, Dec 14, 2015 at 04:19:50PM +0200, Ville Syrjälä wrote: >> > On Mon, Dec 14, 2015 at 12:50:55PM +0200, Jani Nikula wrote: >> > Either I'm blind or you didn't actually add rvda/rvds

Re: [Intel-gfx] [PATCH 07/32] drm/i915: Store the reset counter when constructing a request

2015-12-16 Thread Daniel Vetter
On Fri, Dec 11, 2015 at 11:33:03AM +, Chris Wilson wrote: > As the request is only valid during the same global reset epoch, we can > record the current reset_counter when constructing the request and reuse > it when waiting upon that request in future. This removes a very hairy > atomic check

Re: [Intel-gfx] [PATCH 08/32] drm/i915: Simplify reset_counter handling during atomic modesetting

2015-12-16 Thread Daniel Vetter
On Fri, Dec 11, 2015 at 11:33:04AM +, Chris Wilson wrote: > Now that the reset_counter is stored on the request, we can rearrange > the code to handle reading the counter versus waiting during the atomic > modesetting for readibility (by deleting the hairiest of codes). > > Signed-off-by: Chri

Re: [Intel-gfx] [PATCH 09/32] drm/i915: Prevent leaking of -EIO from i915_wait_request()

2015-12-16 Thread Daniel Vetter
On Fri, Dec 11, 2015 at 11:33:05AM +, Chris Wilson wrote: > Reporting -EIO from i915_wait_request() has proven very troublematic > over the years, with numerous hard-to-reproduce bugs cropping up in the > corner case of where a reset occurs and the code wasn't expecting such > an error. > > If

Re: [Intel-gfx] [PATCH 10/32] drm/i915: Suppress error message when GPU resets are disabled

2015-12-16 Thread Daniel Vetter
On Fri, Dec 11, 2015 at 11:33:06AM +, Chris Wilson wrote: > If we do not have lowlevel support for reseting the GPU, or if the user > has explicitly disabled reseting the device, the failure is expected. > Since it is an expected failure, we should be using a lower priority > message than *ERRO

Re: [Intel-gfx] [PATCH] drm/i915: Allow userspace to request no-error-capture upon GPU hangs

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 09:54:47AM +0100, Daniel Vetter wrote: > On Fri, Dec 11, 2015 at 10:18:35PM +, Chris Wilson wrote: > > igt likes to inject GPU hangs into its command streams. However, as we > > expect these hangs, we don't actually want them recorded in the dmesg > > output or stored in

Re: [Intel-gfx] [PATCH 10/32] drm/i915: Suppress error message when GPU resets are disabled

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 10:53:16AM +0100, Daniel Vetter wrote: > On Fri, Dec 11, 2015 at 11:33:06AM +, Chris Wilson wrote: > > If we do not have lowlevel support for reseting the GPU, or if the user > > has explicitly disabled reseting the device, the failure is expected. > > Since it is an exp

Re: [Intel-gfx] [PATCH] drm/i915: Allow userspace to request no-error-capture upon GPU hangs

2015-12-16 Thread Daniel Vetter
On Wed, Dec 16, 2015 at 10:00:44AM +, Chris Wilson wrote: > On Wed, Dec 16, 2015 at 09:54:47AM +0100, Daniel Vetter wrote: > > On Fri, Dec 11, 2015 at 10:18:35PM +, Chris Wilson wrote: > > > igt likes to inject GPU hangs into its command streams. However, as we > > > expect these hangs, we

Re: [Intel-gfx] [PATCH 3/4] drm/i915: Do not acquire crtc state to check clock during modeset, v3.

2015-12-16 Thread Maarten Lankhorst
Op 15-12-15 om 11:22 schreef Mika Kahola: > On Tue, 2015-11-24 at 11:29 +0100, Maarten Lankhorst wrote: >> Parallel modesets are still not allowed, but this will allow updating >> a different crtc during a modeset if the clock is not changed. >> >> Additionally when all pipes are DPMS off the cdclk

Re: [Intel-gfx] [PATCH] drm/i915: Force clean compilation with -Werror

2015-12-16 Thread Daniel Vetter
On Mon, Dec 14, 2015 at 02:03:33PM +, Chris Wilson wrote: > Our driver compiles clean (nowadays thanks to 0day) but for me, at least, > it would be beneficial if the compiler threw an error rather than a > warning when it found a piece of suspect code. (I use this to > compile-check patch serie

Re: [Intel-gfx] [PATCH 07/32] drm/i915: Store the reset counter when constructing a request

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 10:44:19AM +0100, Daniel Vetter wrote: > On Fri, Dec 11, 2015 at 11:33:03AM +, Chris Wilson wrote: > > As the request is only valid during the same global reset epoch, we can > > record the current reset_counter when constructing the request and reuse > > it when waiting

Re: [Intel-gfx] [PATCH 03/10] drm/i915: Write out crc frame counts in hex

2015-12-16 Thread Daniel Vetter
On Mon, Dec 14, 2015 at 06:23:42PM +0200, ville.syrj...@linux.intel.com wrote: > From: Ville Syrjälä > > The crc code assumes that the printed frame counter value takes > exactly 8 characters. The counter is a 32bit value, so to fit > it into 8 characters we need to print it in hex, in decimal it

Re: [Intel-gfx] [PATCH 04/10] drm/i915: Wait for pipe to start before sampling vblank timestamps on gen2

2015-12-16 Thread Daniel Vetter
On Mon, Dec 14, 2015 at 06:23:43PM +0200, ville.syrj...@linux.intel.com wrote: > From: Ville Syrjälä > > We use the vblank timestamps to generate the vblank frame counter value > on gen2. That means we need the pipe scanout position to be accurate > when we call drm_crtc_vblank_on(), otherwise th

Re: [Intel-gfx] [PATCH 04/32] drm/i915: Hide the atomic_read(reset_counter) behind a helper

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 10:33:32AM +0100, Daniel Vetter wrote: > Hit send too early ;-) > > On Fri, Dec 11, 2015 at 11:33:00AM +, Chris Wilson wrote: > > @@ -4133,7 +4133,7 @@ i915_gem_ring_throttle(struct drm_device *dev, struct > > drm_file *file) > > > > target = request; > >

Re: [Intel-gfx] [PATCH 05/10] drm/i915: Use drm_vblank_count() on gen2 for crc frame count

2015-12-16 Thread Daniel Vetter
On Mon, Dec 14, 2015 at 06:23:44PM +0200, ville.syrj...@linux.intel.com wrote: > From: Ville Syrjälä > > Gen2 doesn't have a hardware frame counter, so let's use the sw > counter value instead. > > Testcase: igt/kms_pipe_crc_basic/read-crc-pipe-?-frame-sequence > Signed-off-by: Ville Syrjälä I

Re: [Intel-gfx] [PATCH 06/10] drm/i915: Enable vblank_disable_immediate on gen2

2015-12-16 Thread Daniel Vetter
On Mon, Dec 14, 2015 at 06:23:45PM +0200, ville.syrj...@linux.intel.com wrote: > From: Ville Syrjälä > > Since > commit 4dfd648 ("drm: Use vblank timestamps to guesstimate how many vblanks > were missed") > the vblank code can cook up a frame counter value based on > the vblank timestamps (as lo

Re: [Intel-gfx] [PATCH 09/10] drm/i915: Reject < 8 byte batches on 830/845

2015-12-16 Thread Daniel Vetter
On Mon, Dec 14, 2015 at 06:23:48PM +0200, ville.syrj...@linux.intel.com wrote: > From: Ville Syrjälä > > We use MI_BATCH_BUFFER on 830/845, which means we need to know > the batch length. If the user passes a bad batch length (< 8) > the results is most likely a GPU hang. Rejct such batches. > >

Re: [Intel-gfx] [PATCH igt 3/9] igt/drv_hangman: Inject a true hang

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 10:02:27AM +0100, Daniel Vetter wrote: > On Sat, Dec 12, 2015 at 08:02:49PM +, Chris Wilson wrote: > > Wean drv_hangman off the atrocious stop_rings and use a real GPU hang > > instead. > > > > Signed-off-by: Chris Wilson > > Doesn't this kill pre-gen6? Or at least an

Re: [Intel-gfx] [PATCH 06/10] drm/i915: Enable vblank_disable_immediate on gen2

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 11:31:31AM +0100, Daniel Vetter wrote: > On Mon, Dec 14, 2015 at 06:23:45PM +0200, ville.syrj...@linux.intel.com wrote: > > From: Ville Syrjälä > > > > Since > > commit 4dfd648 ("drm: Use vblank timestamps to guesstimate how many vblanks > > were missed") > > the vblank c

Re: [Intel-gfx] [PATCH] drm/i915: edp resume/On time optimization.

2015-12-16 Thread Kumar, Shobhit
On 12/16/2015 03:46 AM, abhay.ku...@intel.com wrote: From: Abhay Kumar Make resume codepath not to wait for panel_power_cycle_delay(t11_t12) if this time is already spent in suspend/poweron time. Signed-off-by: Abhay Kumar --- drivers/gpu/drm/i915/intel_ddi.c | 3 +++ drivers/gpu/drm/i915

Re: [Intel-gfx] [PATCH 1/6] drm/i915: Get runtime pm ref on i915_drop_caches_set

2015-12-16 Thread Daniel Vetter
On Tue, Dec 15, 2015 at 01:36:07PM +0200, Mika Kuoppala wrote: > Chris Wilson writes: > > > On Mon, Dec 14, 2015 at 07:14:23PM +0200, Mika Kuoppala wrote: > >> When we drop caches, this debugfs entry does hardware access later in > >> the chain, when fences are updated, so it needs a runtime pm r

Re: [Intel-gfx] [PATCH 09/10] drm/i915: Reject < 8 byte batches on 830/845

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 11:36:31AM +0100, Daniel Vetter wrote: > On Mon, Dec 14, 2015 at 06:23:48PM +0200, ville.syrj...@linux.intel.com wrote: > > From: Ville Syrjälä > > > > We use MI_BATCH_BUFFER on 830/845, which means we need to know > > the batch length. If the user passes a bad batch lengt

Re: [Intel-gfx] [PATCH 01/10] drm/i915: clarify comment about mandatory RPM put/get during driver load/unload

2015-12-16 Thread Joonas Lahtinen
Hi, On ti, 2015-12-15 at 20:10 +0200, Imre Deak wrote: > Signed-off-by: Imre Deak Reviewed-by: Joonas Lahtinen > --- > drivers/gpu/drm/i915/intel_runtime_pm.c | 15 +-- > 1 file changed, 13 insertions(+), 2 deletions(-) > > diff --git a/drivers/gpu/drm/i915/intel_runtime_pm.c > b

Re: [Intel-gfx] [PATCH i-g-t 4/7] tests/gem_mmap_gtt: Make the small-bo tiling tests work on old platforms

2015-12-16 Thread Daniel Vetter
On Tue, Dec 15, 2015 at 12:30:54PM +, Chris Wilson wrote: > On Tue, Dec 15, 2015 at 02:01:24PM +0200, Ville Syrjälä wrote: > > On Tue, Dec 15, 2015 at 01:29:59PM +0200, Ville Syrjälä wrote: > > > On Tue, Dec 15, 2015 at 11:16:52AM +, Chris Wilson wrote: > > > > On Tue, Dec 15, 2015 at 12:57

[Intel-gfx] [PATCH] drm/i915: prefer for_each_intel_* macros for iteration

2015-12-16 Thread Jani Nikula
Use the for_each_intel_* macros for iterating intel_encoder, intel_connector, and intel_crtc. No functional changes. Signed-off-by: Jani Nikula --- drivers/gpu/drm/i915/i915_drv.c | 11 --- drivers/gpu/drm/i915/intel_display.c | 10 +++--- drivers/gpu/drm/i915/intel_dp.c

Re: [Intel-gfx] [PATCH i-g-t 6/7] tests/kms_flip: Increase TEST_TS_CONT max seq difference to 150

2015-12-16 Thread Daniel Vetter
On Mon, Dec 14, 2015 at 10:15:55PM +0200, ville.syrj...@linux.intel.com wrote: > From: Ville Syrjälä > > During suspend tests we can exceed the current 100 frame difference > in sequence numbers. Bump the limit to 150 frames. > > Signed-off-by: Ville Syrjälä I'd bump a lot more tbh, or maybe c

Re: [Intel-gfx] [PATCH 09/10] drm/i915: Reject < 8 byte batches on 830/845

2015-12-16 Thread Daniel Vetter
On Wed, Dec 16, 2015 at 10:43:54AM +, Chris Wilson wrote: > On Wed, Dec 16, 2015 at 11:36:31AM +0100, Daniel Vetter wrote: > > On Mon, Dec 14, 2015 at 06:23:48PM +0200, ville.syrj...@linux.intel.com > > wrote: > > > From: Ville Syrjälä > > > > > > We use MI_BATCH_BUFFER on 830/845, which mea

Re: [Intel-gfx] [PATCH v5] drm/i915: Pin the ifbdev for the info->system_base GGTT mmapping

2015-12-16 Thread Daniel Vetter
On Sun, Dec 06, 2015 at 09:33:20PM +0100, Lukas Wunner wrote: > Hi Chris, > > On Fri, Dec 04, 2015 at 04:05:26PM +, Chris Wilson wrote: > > A long time ago (before 3.14) we relied on a permanent pinning of the > > ifbdev to lock the fb in place inside the GGTT. However, the > > introduction of

Re: [Intel-gfx] [PATCH 03/10] drm/i915: refactor RPM disabling due to RC6 being disabled

2015-12-16 Thread Joonas Lahtinen
On ti, 2015-12-15 at 20:10 +0200, Imre Deak wrote: > We can make the RPM dependency on RC6 explciit in the code by taking > an > actual RPM reference, instead of avoiding to drop the initial one. > This > will also enable us to remove the HAS_RUNTIME_PM special casing from > more places in the next

Re: [Intel-gfx] [PATCH] drm/i915: edp resume/On time optimization.

2015-12-16 Thread Ville Syrjälä
On Tue, Dec 15, 2015 at 02:16:38PM -0800, abhay.ku...@intel.com wrote: > From: Abhay Kumar > > Make resume codepath not to wait for panel_power_cycle_delay(t11_t12) > if this time is already spent in suspend/poweron time. > > Signed-off-by: Abhay Kumar > --- > drivers/gpu/drm/i915/intel_ddi.c

Re: [Intel-gfx] [PATCH 04/10] drm/i915: remove HAS_RUNTIME_PM check from RPM get/put/assert helpers

2015-12-16 Thread Joonas Lahtinen
On ti, 2015-12-15 at 20:10 +0200, Imre Deak wrote: > We don't really need to check this flag in the get/put/assert > helpers, > as on platforms without RPM support we won't ever enable RPM. That > means > pm.suspend will be always false and the assert will be always true. > > Do this to simplify t

Re: [Intel-gfx] [RFC 2/7] drm/i915: move VBT based TV presence check to intel_bios.c

2015-12-16 Thread Daniel Vetter
On Tue, Dec 15, 2015 at 05:33:33PM +0200, Jani Nikula wrote: > Signed-off-by: Jani Nikula > --- > drivers/gpu/drm/i915/i915_drv.h | 1 + > drivers/gpu/drm/i915/intel_bios.c | 38 ++ > drivers/gpu/drm/i915/intel_tv.c | 43 > +---

Re: [Intel-gfx] [PATCH 08/10] drm/i915: check that we hold an RPM wakelock ref before we put it

2015-12-16 Thread Joonas Lahtinen
On ti, 2015-12-15 at 20:10 +0200, Imre Deak wrote: > v2-v3: > - unchanged > v4: > - keep the corresponding check in the get helper (Chris) This is put helper you patched, so I think the above message is incorrect. Regards, Joonas > > Signed-off-by: Imre Deak > --- > drivers/gpu/drm/i915/intel

[Intel-gfx] [PATCH 1/2] drm/i915: Call encoder hotplug for init and resume cases

2015-12-16 Thread Sonika Jindal
Call the encoders, call the hot_plug if it is registered. This is required for connected boot and resume cases to generate fake hpd resulting in reading of edid. Removing the initial sdvo hot_plug call too so that it will be called just once from this loop. v2: Schedule a work function to call hot

[Intel-gfx] [PATCH 2/2] drm/i915: Add hot_plug hook for hdmi encoder

2015-12-16 Thread Sonika Jindal
From: Shashank Sharma This patch adds a separate probe function for HDMI EDID read over DDC channel. This function has been registered as a .hot_plug handler for HDMI encoder. The current implementation of hdmi_detect() function re-sets the cached HDMI edid (in connector->detect_edid) in every d

Re: [Intel-gfx] [PATCH 03/10] drm/i915: refactor RPM disabling due to RC6 being disabled

2015-12-16 Thread Joonas Lahtinen
On ke, 2015-12-16 at 12:54 +0200, Joonas Lahtinen wrote: > On ti, 2015-12-15 at 20:10 +0200, Imre Deak wrote: > > We can make the RPM dependency on RC6 explciit in the code by Typo, s/explciit/explicit/ > > taking > > an > > actual RPM reference, instead of avoiding to drop the initial one. > >

Re: [Intel-gfx] [RFC 7/7] drm/i915/bios: hide away VBT specific things in a private bios header

2015-12-16 Thread Daniel Vetter
On Tue, Dec 15, 2015 at 05:33:38PM +0200, Jani Nikula wrote: > We've been accumulating code across the driver that depends on the VBT > specific structures and defines. The VBT is an uncontrollable > beast. Encourage encapsulation of the VBT data by hiding the structures > and defines in a private

Re: [Intel-gfx] [PATCH 1/6] drm/i915: Get runtime pm ref on i915_drop_caches_set

2015-12-16 Thread Imre Deak
On ke, 2015-12-16 at 11:42 +0100, Daniel Vetter wrote: > On Tue, Dec 15, 2015 at 01:36:07PM +0200, Mika Kuoppala wrote: > > Chris Wilson writes: > > > > > On Mon, Dec 14, 2015 at 07:14:23PM +0200, Mika Kuoppala wrote: > > > > When we drop caches, this debugfs entry does hardware access > > > > la

Re: [Intel-gfx] [PATCH 09/32] drm/i915: Prevent leaking of -EIO from i915_wait_request()

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 10:52:06AM +0100, Daniel Vetter wrote: > On Fri, Dec 11, 2015 at 11:33:05AM +, Chris Wilson wrote: > > diff --git a/drivers/gpu/drm/i915/intel_display.c > > b/drivers/gpu/drm/i915/intel_display.c > > index d7bbd015de35..875bdf814d73 100644 > > --- a/drivers/gpu/drm/i915

Re: [Intel-gfx] [PATCH 09/10] drm/i915: add support for checking RPM atomic sections

2015-12-16 Thread Joonas Lahtinen
On ti, 2015-12-15 at 20:10 +0200, Imre Deak wrote: > In some cases we want to check whether we hold an RPM wakelock > reference > for the whole duration of a sequence. To achieve this add a new RPM > atomic sequence > counter that we increment any time the wakelock refcount drops to > zero. > Check

Re: [Intel-gfx] [PATCH 03/10] drm/i915: Write out crc frame counts in hex

2015-12-16 Thread Ville Syrjälä
On Wed, Dec 16, 2015 at 11:23:54AM +0100, Daniel Vetter wrote: > On Mon, Dec 14, 2015 at 06:23:42PM +0200, ville.syrj...@linux.intel.com wrote: > > From: Ville Syrjälä > > > > The crc code assumes that the printed frame counter value takes > > exactly 8 characters. The counter is a 32bit value, s

Re: [Intel-gfx] [PATCH 08/10] drm/i915: check that we hold an RPM wakelock ref before we put it

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 01:00:38PM +0200, Joonas Lahtinen wrote: > On ti, 2015-12-15 at 20:10 +0200, Imre Deak wrote: > > v2-v3: > > - unchanged > > v4: > > - keep the corresponding check in the get helper (Chris) > > This is put helper you patched, so I think the above message is > incorrect. It

Re: [Intel-gfx] [PATCH 03/10] drm/i915: Write out crc frame counts in hex

2015-12-16 Thread Daniel Vetter
On Wed, Dec 16, 2015 at 12:58:33PM +0200, Ville Syrjälä wrote: > On Wed, Dec 16, 2015 at 11:23:54AM +0100, Daniel Vetter wrote: > > On Mon, Dec 14, 2015 at 06:23:42PM +0200, ville.syrj...@linux.intel.com > > wrote: > > > From: Ville Syrjälä > > > > > > The crc code assumes that the printed frame

Re: [Intel-gfx] [PATCH i-g-t 4/7] tests/gem_mmap_gtt: Make the small-bo tiling tests work on old platforms

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 11:46:50AM +0100, Daniel Vetter wrote: > On Tue, Dec 15, 2015 at 12:30:54PM +, Chris Wilson wrote: > > On Tue, Dec 15, 2015 at 02:01:24PM +0200, Ville Syrjälä wrote: > > > On Tue, Dec 15, 2015 at 01:29:59PM +0200, Ville Syrjälä wrote: > > > > On Tue, Dec 15, 2015 at 11:1

Re: [Intel-gfx] [PATCH 02/10] drm/i915: disable power well support on platforms without runtime PM support

2015-12-16 Thread Daniel Vetter
On Tue, Dec 15, 2015 at 10:57:31PM +0200, Ville Syrjälä wrote: > On Tue, Dec 15, 2015 at 08:10:30PM +0200, Imre Deak wrote: > > All platforms with power well support have runtime PM support, so > > simplify things by explicitly disabling power well support on platforms > > without runtime PM suppor

Re: [Intel-gfx] [PATCH 09/10] drm/i915: add support for checking RPM atomic sections

2015-12-16 Thread Daniel Vetter
On Tue, Dec 15, 2015 at 08:10:37PM +0200, Imre Deak wrote: > In some cases we want to check whether we hold an RPM wakelock reference > for the whole duration of a sequence. To achieve this add a new RPM atomic > sequence > counter that we increment any time the wakelock refcount drops to zero. >

Re: [Intel-gfx] [PATCH] drm/i915: prefer for_each_intel_* macros for iteration

2015-12-16 Thread Daniel Vetter
On Wed, Dec 16, 2015 at 12:48:16PM +0200, Jani Nikula wrote: > Use the for_each_intel_* macros for iterating intel_encoder, > intel_connector, and intel_crtc. No functional changes. > > Signed-off-by: Jani Nikula Trusting that gcc will scream at you if you fumbled types: Reviewed-by: Daniel Vet

[Intel-gfx] [PATCH 0/2] DPCD Backlight Control

2015-12-16 Thread Yetunde Adebisi
These patches add support for Backlight Control using DPCD registers on eDP displays. Yetunde Adebisi (2): drm/dp: Add definition for Display Control DPCD Registers capability size drm/i915: Add Backlight Control using DPCD for eDP connectors (v4) drivers/gpu/drm/i915/Makefile

[Intel-gfx] [PATCH 2/2] drm/i915: Add Backlight Control using DPCD for eDP connectors (v4)

2015-12-16 Thread Yetunde Adebisi
This patch adds support for eDP backlight control using DPCD registers to backlight hooks in intel_panel. It checks for backlight control over AUX channel capability and sets up function pointers to get and set the backlight brightness level if supported. v2: Moved backlight functions from intel_

[Intel-gfx] [PATCH 1/2] drm/dp: Add definition for Display Control DPCD Registers capability size

2015-12-16 Thread Yetunde Adebisi
This is used when reading Display Control capability Registers on the sink device. cc: Jani Nikula Signed-off-by: Yetunde Adebisi --- include/drm/drm_dp_helper.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/drm/drm_dp_helper.h b/include/drm/drm_dp_helper.h index 1252108..92d9a52

Re: [Intel-gfx] [PATCH 05/10] drm/i915: add assert_rpm_wakelock_held helper

2015-12-16 Thread Chris Wilson
On Tue, Dec 15, 2015 at 08:10:33PM +0200, Imre Deak wrote: > As a preparation for follow-up patches add a new helper that checks > whether we hold an RPM reference, since this is what we want most of > the cases. Atm this helper will only check for the HW suspended state, a > follow-up patch will d

[Intel-gfx] [PATCH v3] drm/i915: Disable fast link training if DP config changes

2015-12-16 Thread Mika Kahola
Disable DP fast link training if DP link configuration changes. If one of the DP link parameters i.e. link bandwidth, lane count, rate selection, port clock or bpp changes the link training does no longer apply the previously computed voltage swing and pre-emphasis values. Instead, the link trainin

[Intel-gfx] [PATCH] drm/i915: Force clean compilation with -Werror

2015-12-16 Thread Chris Wilson
Our driver compiles clean (nowadays thanks to 0day) but for me, at least, it would be beneficial if the compiler threw an error rather than a warning when it found a piece of suspect code. (I use this to compile-check patch series and want to break on the first compiler error in order to fix the pa

Re: [Intel-gfx] [PATCH 9/9] drm/i915: Fail the execbuff using stolen objects as batchbuffers

2015-12-16 Thread Chris Wilson
On Tue, Dec 15, 2015 at 05:50:36PM +, Dave Gordon wrote: > On 15/12/15 14:54, Chris Wilson wrote: > >On Tue, Dec 15, 2015 at 02:41:47PM +, Dave Gordon wrote: > >>On 14/12/15 05:46, ankitprasad.r.sha...@intel.com wrote: > >>>From: Ankitprasad Sharma > >>> > >>>Using stolen backed objects as

Re: [Intel-gfx] [PATCH] drm/i915: prefer for_each_intel_* macros for iteration

2015-12-16 Thread Jani Nikula
On Wed, 16 Dec 2015, Daniel Vetter wrote: > On Wed, Dec 16, 2015 at 12:48:16PM +0200, Jani Nikula wrote: >> Use the for_each_intel_* macros for iterating intel_encoder, >> intel_connector, and intel_crtc. No functional changes. >> >> Signed-off-by: Jani Nikula > > Trusting that gcc will scream a

Re: [Intel-gfx] [PATCH v3] drm/i915: Disable fast link training if DP config changes

2015-12-16 Thread Ville Syrjälä
On Wed, Dec 16, 2015 at 02:26:58PM +0200, Mika Kahola wrote: > Disable DP fast link training if DP link configuration > changes. If one of the DP link parameters i.e. link > bandwidth, lane count, rate selection, port clock or bpp > changes the link training does no longer apply the > previously co

Re: [Intel-gfx] [PATCH 3/4] drm/i915: Do not acquire crtc state to check clock during modeset, v3.

2015-12-16 Thread Mika Kahola
On Tue, 2015-12-15 at 10:26 +, Chris Wilson wrote: > On Tue, Dec 15, 2015 at 12:22:40PM +0200, Mika Kahola wrote: > > On Tue, 2015-11-24 at 11:29 +0100, Maarten Lankhorst wrote: > > > diff --git a/drivers/gpu/drm/i915/intel_display.c > > > b/drivers/gpu/drm/i915/intel_display.c > > > index 3c4

Re: [Intel-gfx] [PATCH 08/10] drm/i915: check that we hold an RPM wakelock ref before we put it

2015-12-16 Thread Imre Deak
On ke, 2015-12-16 at 11:07 +, Chris Wilson wrote: > On Wed, Dec 16, 2015 at 01:00:38PM +0200, Joonas Lahtinen wrote: > > On ti, 2015-12-15 at 20:10 +0200, Imre Deak wrote: > > > v2-v3: > > > - unchanged > > > v4: > > > - keep the corresponding check in the get helper (Chris) > > > > This is pu

Re: [Intel-gfx] [PATCH 05/10] drm/i915: Use drm_vblank_count() on gen2 for crc frame count

2015-12-16 Thread Ville Syrjälä
On Wed, Dec 16, 2015 at 11:30:19AM +0100, Daniel Vetter wrote: > On Mon, Dec 14, 2015 at 06:23:44PM +0200, ville.syrj...@linux.intel.com wrote: > > From: Ville Syrjälä > > > > Gen2 doesn't have a hardware frame counter, so let's use the sw > > counter value instead. > > > > Testcase: igt/kms_pip

Re: [Intel-gfx] [PATCH 09/32] drm/i915: Prevent leaking of -EIO from i915_wait_request()

2015-12-16 Thread Daniel Vetter
On Wed, Dec 16, 2015 at 11:06:20AM +, Chris Wilson wrote: > On Wed, Dec 16, 2015 at 10:52:06AM +0100, Daniel Vetter wrote: > > On Fri, Dec 11, 2015 at 11:33:05AM +, Chris Wilson wrote: > > > diff --git a/drivers/gpu/drm/i915/intel_display.c > > > b/drivers/gpu/drm/i915/intel_display.c > >

Re: [Intel-gfx] [PATCH 05/10] drm/i915: add assert_rpm_wakelock_held helper

2015-12-16 Thread Imre Deak
On ke, 2015-12-16 at 12:11 +, Chris Wilson wrote: > On Tue, Dec 15, 2015 at 08:10:33PM +0200, Imre Deak wrote: > > As a preparation for follow-up patches add a new helper that checks > > whether we hold an RPM reference, since this is what we want most > > of > > the cases. Atm this helper will

Re: [Intel-gfx] [PATCH 05/10] drm/i915: add assert_rpm_wakelock_held helper

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 02:54:43PM +0200, Imre Deak wrote: > On ke, 2015-12-16 at 12:11 +, Chris Wilson wrote: > > On Tue, Dec 15, 2015 at 08:10:33PM +0200, Imre Deak wrote: > > > +static inline void > > > +assert_rpm_device_not_suspended(struct drm_i915_private *dev_priv) > > > +{ > > > + WARN

Re: [Intel-gfx] [PATCH v3] drm/i915: Disable fast link training if DP config changes

2015-12-16 Thread Mika Kahola
On Wed, 2015-12-16 at 14:41 +0200, Ville Syrjälä wrote: > On Wed, Dec 16, 2015 at 02:26:58PM +0200, Mika Kahola wrote: > > Disable DP fast link training if DP link configuration > > changes. If one of the DP link parameters i.e. link > > bandwidth, lane count, rate selection, port clock or bpp > >

[Intel-gfx] [PATCH 2/4] drm/i915/bios: fix format string of the VBT signature logging

2015-12-16 Thread Jani Nikula
Specify the maximum number of letters to print from the potentially unterminated buffer, not the minimum. While at it, use sizeof instead of a magic number. Signed-off-by: Jani Nikula --- drivers/gpu/drm/i915/intel_bios.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dr

[Intel-gfx] [PATCH 3/4] drm/i915/bios: prefer using dev_priv over dev pointer

2015-12-16 Thread Jani Nikula
dev_priv is the new black. Or something. Signed-off-by: Jani Nikula --- drivers/gpu/drm/i915/i915_dma.c | 2 +- drivers/gpu/drm/i915/i915_drv.h | 2 +- drivers/gpu/drm/i915/intel_bios.c | 22 +- 3 files changed, 11 insertions(+), 15 deletions(-) diff --git a/drivers/gp

[Intel-gfx] [PATCH 1/4] drm/i915: move drmP.h include to i915_drv.h

2015-12-16 Thread Jani Nikula
The intel_bios.h header doesn't even need it, but other headers included from i915_drv.h do. Let's untangle the mess a bit. Signed-off-by: Jani Nikula --- drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/intel_bios.h | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --gi

[Intel-gfx] [PATCH 4/4] drm/i915/bios: reduce indent in parse_general_features

2015-12-16 Thread Jani Nikula
Slightly cleaner with early exit. Signed-off-by: Jani Nikula --- drivers/gpu/drm/i915/intel_bios.c | 39 --- 1 file changed, 20 insertions(+), 19 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_bios.c b/drivers/gpu/drm/i915/intel_bios.c index 25edfc062f

Re: [Intel-gfx] [PATCH igt 3/9] igt/drv_hangman: Inject a true hang

2015-12-16 Thread Ville Syrjälä
On Wed, Dec 16, 2015 at 10:37:55AM +, Chris Wilson wrote: > On Wed, Dec 16, 2015 at 10:02:27AM +0100, Daniel Vetter wrote: > > On Sat, Dec 12, 2015 at 08:02:49PM +, Chris Wilson wrote: > > > Wean drv_hangman off the atrocious stop_rings and use a real GPU hang > > > instead. > > > > > > Si

Re: [Intel-gfx] [PATCH 02/10] drm/i915: disable power well support on platforms without runtime PM support

2015-12-16 Thread Imre Deak
On ke, 2015-12-16 at 12:12 +0100, Daniel Vetter wrote: > On Tue, Dec 15, 2015 at 10:57:31PM +0200, Ville Syrjälä wrote: > > On Tue, Dec 15, 2015 at 08:10:30PM +0200, Imre Deak wrote: > > > All platforms with power well support have runtime PM support, so > > > simplify things by explicitly disablin

Re: [Intel-gfx] [PATCH 05/10] drm/i915: add assert_rpm_wakelock_held helper

2015-12-16 Thread Joonas Lahtinen
On ke, 2015-12-16 at 13:02 +, Chris Wilson wrote: > On Wed, Dec 16, 2015 at 02:54:43PM +0200, Imre Deak wrote: > > On ke, 2015-12-16 at 12:11 +, Chris Wilson wrote: > > > On Tue, Dec 15, 2015 at 08:10:33PM +0200, Imre Deak wrote: > > > > +static inline void > > > > +assert_rpm_device_not_su

Re: [Intel-gfx] [PATCH 05/10] drm/i915: add assert_rpm_wakelock_held helper

2015-12-16 Thread Imre Deak
On ke, 2015-12-16 at 15:39 +0200, Joonas Lahtinen wrote: > On ke, 2015-12-16 at 13:02 +, Chris Wilson wrote: > > On Wed, Dec 16, 2015 at 02:54:43PM +0200, Imre Deak wrote: > > > On ke, 2015-12-16 at 12:11 +, Chris Wilson wrote: > > > > On Tue, Dec 15, 2015 at 08:10:33PM +0200, Imre Deak wro

Re: [Intel-gfx] [PATCH 1/2] drm/i915: Call encoder hotplug for init and resume cases

2015-12-16 Thread Daniel Vetter
On Wed, Dec 16, 2015 at 04:18:05PM +0530, Sonika Jindal wrote: > Call the encoders, call the hot_plug if it is registered. > This is required for connected boot and resume cases to generate > fake hpd resulting in reading of edid. > Removing the initial sdvo hot_plug call too so that it will be cal

Re: [Intel-gfx] [PATCH 1/2] tests/gem_eio: New ABI - no EIO even from wait_ioctl

2015-12-16 Thread Chris Wilson
On Thu, Nov 26, 2015 at 12:34:34PM +0100, Daniel Vetter wrote: > So there's 3 competing proposals for what wait_ioctl should do wrt > -EIO: > > - return -EIO when the gpu is wedged. Not terribly useful for > userspace since it might race with a hang and then there's no > guarantee that a subse

[Intel-gfx] [PATCH 4.1/10] drm/i915: get a permanent RPM reference on platforms w/o RPM support

2015-12-16 Thread Imre Deak
Currently we get a permanent RPM reference if the platform doesn't support RPM, but this is implicit via the dependency of the power well functionality on RPM the RPM support, see sanitize_disable_power_well_option(). Make things more explicit by taking an RPM reference only for the purpose of keep

Re: [Intel-gfx] [PATCH v3] drm/i915: Disable fast link training if DP config changes

2015-12-16 Thread Daniel Vetter
On Wed, Dec 16, 2015 at 03:04:47PM +0200, Mika Kahola wrote: > On Wed, 2015-12-16 at 14:41 +0200, Ville Syrjälä wrote: > > On Wed, Dec 16, 2015 at 02:26:58PM +0200, Mika Kahola wrote: > > > Disable DP fast link training if DP link configuration > > > changes. If one of the DP link parameters i.e. l

Re: [Intel-gfx] [PATCH igt 3/9] igt/drv_hangman: Inject a true hang

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 03:12:57PM +0200, Ville Syrjälä wrote: > On Wed, Dec 16, 2015 at 10:37:55AM +, Chris Wilson wrote: > > On Wed, Dec 16, 2015 at 10:02:27AM +0100, Daniel Vetter wrote: > > > On Sat, Dec 12, 2015 at 08:02:49PM +, Chris Wilson wrote: > > > > Wean drv_hangman off the atro

[Intel-gfx] [PATCH v2 4.1/10] drm/i915: get a permanent RPM reference on platforms w/o RPM support

2015-12-16 Thread Imre Deak
Currently we get a permanent RPM reference if the platform doesn't support RPM, but this is implicit via the dependency of the power well functionality on RPM the RPM support, see sanitize_disable_power_well_option(). Make things more explicit by taking an RPM reference only for the purpose of keep

Re: [Intel-gfx] [PATCH v3] drm/i915: Disable fast link training if DP config changes

2015-12-16 Thread Ville Syrjälä
On Wed, Dec 16, 2015 at 02:49:51PM +0100, Daniel Vetter wrote: > On Wed, Dec 16, 2015 at 03:04:47PM +0200, Mika Kahola wrote: > > On Wed, 2015-12-16 at 14:41 +0200, Ville Syrjälä wrote: > > > On Wed, Dec 16, 2015 at 02:26:58PM +0200, Mika Kahola wrote: > > > > Disable DP fast link training if DP li

Re: [Intel-gfx] [PATCH igt 3/9] igt/drv_hangman: Inject a true hang

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 01:51:46PM +, Chris Wilson wrote: > On Wed, Dec 16, 2015 at 03:12:57PM +0200, Ville Syrjälä wrote: > > On Wed, Dec 16, 2015 at 10:37:55AM +, Chris Wilson wrote: > > > On Wed, Dec 16, 2015 at 10:02:27AM +0100, Daniel Vetter wrote: > > > > On Sat, Dec 12, 2015 at 08:02

Re: [Intel-gfx] [PATCH 1/4] drm/i915: move drmP.h include to i915_drv.h

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 03:04:18PM +0200, Jani Nikula wrote: > The intel_bios.h header doesn't even need it, but other headers included > from i915_drv.h do. Let's untangle the mess a bit. > > Signed-off-by: Jani Nikula Since we dereference struct drm_device inside i915_drv.h, we need this, and

Re: [Intel-gfx] [PATCH 2/4] drm/i915/bios: fix format string of the VBT signature logging

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 03:04:19PM +0200, Jani Nikula wrote: > Specify the maximum number of letters to print from the potentially > unterminated buffer, not the minimum. While at it, use sizeof instead of > a magic number. > > Signed-off-by: Jani Nikula Wow that's a widely underused feature, on

Re: [Intel-gfx] [PATCH 3/4] drm/i915/bios: prefer using dev_priv over dev pointer

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 03:04:20PM +0200, Jani Nikula wrote: > dev_priv is the new black. Or something. > > Signed-off-by: Jani Nikula Reviewed-by: Chris Wilson -Chris -- Chris Wilson, Intel Open Source Technology Centre ___ Intel-gfx mailing list In

Re: [Intel-gfx] [PATCH 4/4] drm/i915/bios: reduce indent in parse_general_features

2015-12-16 Thread Chris Wilson
On Wed, Dec 16, 2015 at 03:04:21PM +0200, Jani Nikula wrote: > Slightly cleaner with early exit. > > Signed-off-by: Jani Nikula Reviewed-by: Chris Wilson -Chris -- Chris Wilson, Intel Open Source Technology Centre ___ Intel-gfx mailing list Intel-gfx

Re: [Intel-gfx] [PATCH 05/10] drm/i915: Use drm_vblank_count() on gen2 for crc frame count

2015-12-16 Thread Daniel Vetter
On Wed, Dec 16, 2015 at 02:51:20PM +0200, Ville Syrjälä wrote: > On Wed, Dec 16, 2015 at 11:30:19AM +0100, Daniel Vetter wrote: > > On Mon, Dec 14, 2015 at 06:23:44PM +0200, ville.syrj...@linux.intel.com > > wrote: > > > From: Ville Syrjälä > > > > > > Gen2 doesn't have a hardware frame counter,

Re: [Intel-gfx] [PATCH v8 15/25] drm/i915: CHV: Pipe level degamma correction

2015-12-16 Thread Lionel Landwerlin
I gave a try to this patch on Braswell. A couple of comments below. On 03/12/15 11:36, Shashank Sharma wrote: CHV/BSW supports Degamma color correction, which linearizes all the non-linear color values. This will be applied before Color Transformation. This patch does the following: 1. Attach d

Re: [Intel-gfx] [PATCH 2/4] drm/i915/bios: fix format string of the VBT signature logging

2015-12-16 Thread Jani Nikula
On Wed, 16 Dec 2015, Chris Wilson wrote: > On Wed, Dec 16, 2015 at 03:04:19PM +0200, Jani Nikula wrote: >> Specify the maximum number of letters to print from the potentially >> unterminated buffer, not the minimum. While at it, use sizeof instead of >> a magic number. >> >> Signed-off-by: Jani N

[Intel-gfx] [PATCH] drm/i915: Fix AVI/HDMI/SPD infoframes on HSW+

2015-12-16 Thread ville . syrjala
From: Ville Syrjälä I broke AVI/HDMI/SPD infoframes on HSW+ with the register type safety changes. We were supposed to check that the infoframe data register is valid before writing the infoframe data, but the check ended up inverted, and so in practice we never wrote or enabled these infoframes.

  1   2   >