* [PATCH] drm/i915/gen9: Give one extra block per line for SKL plane WM calculations @ 2016-08-04 21:08 Matt Roper 2016-08-04 23:36 ` Lyude 0 siblings, 1 reply; 7+ messages in thread From: Matt Roper @ 2016-08-04 21:08 UTC (permalink / raw) To: intel-gfx The bspec was updated a couple weeks ago to add an extra block per line to plane watermark calculations for linear pixel formats. Bspec update 115327 description: "Gen9+ - Updated the plane blocks per line calculation for linear cases. Adds +1 for all linear cases to handle the non-block aligned stride cases." Cc: Lyude <cpaul@redhat.com> Signed-off-by: Matt Roper <matthew.d.roper@intel.com> --- drivers/gpu/drm/i915/intel_pm.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c index 4317cdf..6bd352a 100644 --- a/drivers/gpu/drm/i915/intel_pm.c +++ b/drivers/gpu/drm/i915/intel_pm.c @@ -3352,6 +3352,8 @@ static uint32_t skl_wm_method2(uint32_t pixel_rate, uint32_t pipe_htotal, plane_bytes_per_line *= 4; plane_blocks_per_line = DIV_ROUND_UP(plane_bytes_per_line, 512); plane_blocks_per_line /= 4; + } else if (tiling == DRM_FORMAT_MOD_NONE) { + plane_blocks_per_line = DIV_ROUND_UP(plane_bytes_per_line, 512) + 1; } else { plane_blocks_per_line = DIV_ROUND_UP(plane_bytes_per_line, 512); } -- 2.1.4 _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] drm/i915/gen9: Give one extra block per line for SKL plane WM calculations 2016-08-04 21:08 [PATCH] drm/i915/gen9: Give one extra block per line for SKL plane WM calculations Matt Roper @ 2016-08-04 23:36 ` Lyude 2016-08-04 23:51 ` Matt Roper 0 siblings, 1 reply; 7+ messages in thread From: Lyude @ 2016-08-04 23:36 UTC (permalink / raw) To: Matt Roper, intel-gfx Reviewed-by: Lyude <cpaul@redhat.com> On Thu, 2016-08-04 at 14:08 -0700, Matt Roper wrote: > The bspec was updated a couple weeks ago to add an extra block per > line > to plane watermark calculations for linear pixel formats. > > Bspec update 115327 description: > "Gen9+ - Updated the plane blocks per line calculation for linear > cases. Adds +1 for all linear cases to handle the non-block aligned > stride cases." > > Cc: Lyude <cpaul@redhat.com> > Signed-off-by: Matt Roper <matthew.d.roper@intel.com> > --- > drivers/gpu/drm/i915/intel_pm.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/drivers/gpu/drm/i915/intel_pm.c > b/drivers/gpu/drm/i915/intel_pm.c > index 4317cdf..6bd352a 100644 > --- a/drivers/gpu/drm/i915/intel_pm.c > +++ b/drivers/gpu/drm/i915/intel_pm.c > @@ -3352,6 +3352,8 @@ static uint32_t skl_wm_method2(uint32_t > pixel_rate, uint32_t pipe_htotal, > plane_bytes_per_line *= 4; > plane_blocks_per_line = > DIV_ROUND_UP(plane_bytes_per_line, 512); > plane_blocks_per_line /= 4; > + } else if (tiling == DRM_FORMAT_MOD_NONE) { > + plane_blocks_per_line = > DIV_ROUND_UP(plane_bytes_per_line, 512) + 1; > } else { > plane_blocks_per_line = > DIV_ROUND_UP(plane_bytes_per_line, 512); > } -- Cheers, Lyude _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] drm/i915/gen9: Give one extra block per line for SKL plane WM calculations 2016-08-04 23:36 ` Lyude @ 2016-08-04 23:51 ` Matt Roper 2016-08-08 18:25 ` Zanoni, Paulo R 0 siblings, 1 reply; 7+ messages in thread From: Matt Roper @ 2016-08-04 23:51 UTC (permalink / raw) To: Lyude; +Cc: intel-gfx On Thu, Aug 04, 2016 at 07:36:15PM -0400, Lyude wrote: > Reviewed-by: Lyude <cpaul@redhat.com> Merged to dinq. Thanks for the quick review. Matt > > On Thu, 2016-08-04 at 14:08 -0700, Matt Roper wrote: > > The bspec was updated a couple weeks ago to add an extra block per > > line > > to plane watermark calculations for linear pixel formats. > > > > Bspec update 115327 description: > > "Gen9+ - Updated the plane blocks per line calculation for linear > > cases. Adds +1 for all linear cases to handle the non-block aligned > > stride cases." > > > > Cc: Lyude <cpaul@redhat.com> > > Signed-off-by: Matt Roper <matthew.d.roper@intel.com> > > --- > > drivers/gpu/drm/i915/intel_pm.c | 2 ++ > > 1 file changed, 2 insertions(+) > > > > diff --git a/drivers/gpu/drm/i915/intel_pm.c > > b/drivers/gpu/drm/i915/intel_pm.c > > index 4317cdf..6bd352a 100644 > > --- a/drivers/gpu/drm/i915/intel_pm.c > > +++ b/drivers/gpu/drm/i915/intel_pm.c > > @@ -3352,6 +3352,8 @@ static uint32_t skl_wm_method2(uint32_t > > pixel_rate, uint32_t pipe_htotal, > > plane_bytes_per_line *= 4; > > plane_blocks_per_line = > > DIV_ROUND_UP(plane_bytes_per_line, 512); > > plane_blocks_per_line /= 4; > > + } else if (tiling == DRM_FORMAT_MOD_NONE) { > > + plane_blocks_per_line = > > DIV_ROUND_UP(plane_bytes_per_line, 512) + 1; > > } else { > > plane_blocks_per_line = > > DIV_ROUND_UP(plane_bytes_per_line, 512); > > } > -- > Cheers, > Lyude -- Matt Roper Graphics Software Engineer IoTG Platform Enabling & Development Intel Corporation (916) 356-2795 _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] drm/i915/gen9: Give one extra block per line for SKL plane WM calculations 2016-08-04 23:51 ` Matt Roper @ 2016-08-08 18:25 ` Zanoni, Paulo R 2016-08-08 18:35 ` Chris Wilson 2016-08-08 18:36 ` Zanoni, Paulo R 0 siblings, 2 replies; 7+ messages in thread From: Zanoni, Paulo R @ 2016-08-08 18:25 UTC (permalink / raw) To: Roper, Matthew D, cpaul; +Cc: intel-gfx Em Qui, 2016-08-04 às 16:51 -0700, Matt Roper escreveu: > On Thu, Aug 04, 2016 at 07:36:15PM -0400, Lyude wrote: > > > > Reviewed-by: Lyude <cpaul@redhat.com> > > Merged to dinq. Thanks for the quick review. Regression? This patch makes my SKL machine fail any modesets. I now boot to a blinking screen where X keeps trying to start and fails. Xorg.0.log gives me: [ 273.512] (EE) modeset(0): failed to set mode: Invalid argument On the dmesg side, these are the more suspicious messages: [ 273.583659] [drm:skl_compute_plane_wm] Requested display configuration exceeds system watermark limitations [ 273.583663] [drm:skl_compute_plane_wm] Plane 1.0: blocks required = 4/0, lines required = 1/31 I tried applying Lyude's series to nightly to see if it fixes something, but it looks like patch 2 doesn't apply. > > > Matt > > > > > > > On Thu, 2016-08-04 at 14:08 -0700, Matt Roper wrote: > > > > > > The bspec was updated a couple weeks ago to add an extra block > > > per > > > line > > > to plane watermark calculations for linear pixel formats. > > > > > > Bspec update 115327 description: > > > "Gen9+ - Updated the plane blocks per line calculation for > > > linear > > > cases. Adds +1 for all linear cases to handle the non-block > > > aligned > > > stride cases." > > > > > > Cc: Lyude <cpaul@redhat.com> > > > Signed-off-by: Matt Roper <matthew.d.roper@intel.com> > > > --- > > > drivers/gpu/drm/i915/intel_pm.c | 2 ++ > > > 1 file changed, 2 insertions(+) > > > > > > diff --git a/drivers/gpu/drm/i915/intel_pm.c > > > b/drivers/gpu/drm/i915/intel_pm.c > > > index 4317cdf..6bd352a 100644 > > > --- a/drivers/gpu/drm/i915/intel_pm.c > > > +++ b/drivers/gpu/drm/i915/intel_pm.c > > > @@ -3352,6 +3352,8 @@ static uint32_t skl_wm_method2(uint32_t > > > pixel_rate, uint32_t pipe_htotal, > > > plane_bytes_per_line *= 4; > > > plane_blocks_per_line = > > > DIV_ROUND_UP(plane_bytes_per_line, 512); > > > plane_blocks_per_line /= 4; > > > + } else if (tiling == DRM_FORMAT_MOD_NONE) { > > > + plane_blocks_per_line = > > > DIV_ROUND_UP(plane_bytes_per_line, 512) + 1; > > > } else { > > > plane_blocks_per_line = > > > DIV_ROUND_UP(plane_bytes_per_line, 512); > > > } > > -- > > Cheers, > > Lyude > _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] drm/i915/gen9: Give one extra block per line for SKL plane WM calculations 2016-08-08 18:25 ` Zanoni, Paulo R @ 2016-08-08 18:35 ` Chris Wilson 2016-08-08 19:00 ` Zanoni, Paulo R 2016-08-08 18:36 ` Zanoni, Paulo R 1 sibling, 1 reply; 7+ messages in thread From: Chris Wilson @ 2016-08-08 18:35 UTC (permalink / raw) To: Zanoni, Paulo R; +Cc: intel-gfx On Mon, Aug 08, 2016 at 06:25:49PM +0000, Zanoni, Paulo R wrote: > Em Qui, 2016-08-04 às 16:51 -0700, Matt Roper escreveu: > > On Thu, Aug 04, 2016 at 07:36:15PM -0400, Lyude wrote: > > > > > > Reviewed-by: Lyude <cpaul@redhat.com> > > > > Merged to dinq. Thanks for the quick review. > > Regression? This patch makes my SKL machine fail any modesets. I now > boot to a blinking screen where X keeps trying to start and fails. -intel has been fixing up failed multi-CRTC modesets since seemingly forever on skl, that fail due to WM being exceeded. And why would modesetting even be trying to use a non-tiled framebuffer? -Chris -- Chris Wilson, Intel Open Source Technology Centre _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] drm/i915/gen9: Give one extra block per line for SKL plane WM calculations 2016-08-08 18:35 ` Chris Wilson @ 2016-08-08 19:00 ` Zanoni, Paulo R 0 siblings, 0 replies; 7+ messages in thread From: Zanoni, Paulo R @ 2016-08-08 19:00 UTC (permalink / raw) To: chris; +Cc: intel-gfx Em Seg, 2016-08-08 às 19:35 +0100, Chris Wilson escreveu: > On Mon, Aug 08, 2016 at 06:25:49PM +0000, Zanoni, Paulo R wrote: > > > > Em Qui, 2016-08-04 às 16:51 -0700, Matt Roper escreveu: > > > > > > On Thu, Aug 04, 2016 at 07:36:15PM -0400, Lyude wrote: > > > > > > > > > > > > Reviewed-by: Lyude <cpaul@redhat.com> > > > > > > Merged to dinq. Thanks for the quick review. > > > > Regression? This patch makes my SKL machine fail any modesets. I > > now > > boot to a blinking screen where X keeps trying to start and fails. > > -intel has been fixing up failed multi-CRTC modesets since seemingly > forever on skl, that fail due to WM being exceeded. And why would > modesetting even be trying to use a non-tiled framebuffer? I'm just using my distro's default driver, and Debian uses modesetting now. I did switch to xf86-video-intel and I found something interesting: the machine boots correctly, but then if I stop+restart lightdm, I get a black screen. The difference here is that X doesn't abort, it tries to keep working despite the black screen: [ 46.483] (EE) intel(0): failed to set mode: Invalid argument [22] [ 46.485] (II) intel(0): EDID vendor "SDC", prod id 16970 [ 46.485] (II) intel(0): Printing DDC gathered Modelines: [ 46.485] (II) intel(0): Modeline "3200x1800"x0.0 361.31 3200 3248 3280 3316 1800 1802 1807 1816 -hsync -vsync (109.0 kHz eP) [ 46.485] (II) intel(0): Modeline "3200x1800"x0.0 361.31 3200 3248 3280 3680 1800 1802 1807 2045 -hsync -vsync (98.2 kHz e) [ 46.794] (--) intel(0): HDMI max TMDS frequency 225000KHz [ 46.969] (EE) intel(0): failed to set mode: Invalid argument [22] And dmesg has the same message as when using xf86-video-modesetting: [ 46.928018] [drm:skl_compute_plane_wm] Requested display configuration exceeds system watermark limitations [ 46.928021] [drm:skl_compute_plane_wm] Plane 1.0: blocks required = 4/0, lines required = 1/31 Notice that this is the distro's driver version: 2:2.99.917+git20160706-1 So it looks like switching back to xf86-video-intel won't be a perfect fix. Anyway, while using the DDX to work around Kernel bugs may have some benefits, it's probably best to try to push for an appropriate Kernel fix, especially now that xf86-video-modesetting is gaining some market share... > -Chris > _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] drm/i915/gen9: Give one extra block per line for SKL plane WM calculations 2016-08-08 18:25 ` Zanoni, Paulo R 2016-08-08 18:35 ` Chris Wilson @ 2016-08-08 18:36 ` Zanoni, Paulo R 1 sibling, 0 replies; 7+ messages in thread From: Zanoni, Paulo R @ 2016-08-08 18:36 UTC (permalink / raw) To: Roper, Matthew D, cpaul; +Cc: intel-gfx Em Seg, 2016-08-08 às 18:25 +0000, Zanoni, Paulo R escreveu: > Em Qui, 2016-08-04 às 16:51 -0700, Matt Roper escreveu: > > > > On Thu, Aug 04, 2016 at 07:36:15PM -0400, Lyude wrote: > > > > > > > > > Reviewed-by: Lyude <cpaul@redhat.com> > > > > Merged to dinq. Thanks for the quick review. > > Regression? This patch makes my SKL machine fail any modesets. I now > boot to a blinking screen where X keeps trying to start and fails. > > Xorg.0.log gives me: > [ 273.512] (EE) modeset(0): failed to set mode: Invalid argument > > > On the dmesg side, these are the more suspicious messages: > > [ 273.583659] [drm:skl_compute_plane_wm] Requested display > configuration exceeds system watermark limitations > [ 273.583663] [drm:skl_compute_plane_wm] Plane 1.0: blocks required > = > 4/0, lines required = 1/31 > > > I tried applying Lyude's series to nightly to see if it fixes > something, but it looks like patch 2 doesn't apply. The patches do apply, I was confused by the email threading and mixed patch 6 v9 with patch 2. Lyude's series fix the regression :). > > > > > > > > > Matt > > > > > > > > > > > > > > On Thu, 2016-08-04 at 14:08 -0700, Matt Roper wrote: > > > > > > > > > > > > The bspec was updated a couple weeks ago to add an extra block > > > > per > > > > line > > > > to plane watermark calculations for linear pixel formats. > > > > > > > > Bspec update 115327 description: > > > > "Gen9+ - Updated the plane blocks per line calculation for > > > > linear > > > > cases. Adds +1 for all linear cases to handle the non-block > > > > aligned > > > > stride cases." > > > > > > > > Cc: Lyude <cpaul@redhat.com> > > > > Signed-off-by: Matt Roper <matthew.d.roper@intel.com> > > > > --- > > > > drivers/gpu/drm/i915/intel_pm.c | 2 ++ > > > > 1 file changed, 2 insertions(+) > > > > > > > > diff --git a/drivers/gpu/drm/i915/intel_pm.c > > > > b/drivers/gpu/drm/i915/intel_pm.c > > > > index 4317cdf..6bd352a 100644 > > > > --- a/drivers/gpu/drm/i915/intel_pm.c > > > > +++ b/drivers/gpu/drm/i915/intel_pm.c > > > > @@ -3352,6 +3352,8 @@ static uint32_t skl_wm_method2(uint32_t > > > > pixel_rate, uint32_t pipe_htotal, > > > > plane_bytes_per_line *= 4; > > > > plane_blocks_per_line = > > > > DIV_ROUND_UP(plane_bytes_per_line, 512); > > > > plane_blocks_per_line /= 4; > > > > + } else if (tiling == DRM_FORMAT_MOD_NONE) { > > > > + plane_blocks_per_line = > > > > DIV_ROUND_UP(plane_bytes_per_line, 512) + 1; > > > > } else { > > > > plane_blocks_per_line = > > > > DIV_ROUND_UP(plane_bytes_per_line, 512); > > > > } > > > -- > > > Cheers, > > > Lyude > > > _______________________________________________ > Intel-gfx mailing list > Intel-gfx@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/intel-gfx _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2016-08-08 19:00 UTC | newest] Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2016-08-04 21:08 [PATCH] drm/i915/gen9: Give one extra block per line for SKL plane WM calculations Matt Roper 2016-08-04 23:36 ` Lyude 2016-08-04 23:51 ` Matt Roper 2016-08-08 18:25 ` Zanoni, Paulo R 2016-08-08 18:35 ` Chris Wilson 2016-08-08 19:00 ` Zanoni, Paulo R 2016-08-08 18:36 ` Zanoni, Paulo R
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.