From patchwork Tue Jan 5 12:49:33 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Niehusmann X-Patchwork-Id: 7954951 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 93825BEEE5 for ; Tue, 5 Jan 2016 13:17:19 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id B289E202BE for ; Tue, 5 Jan 2016 13:17:18 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 53C93202B8 for ; Tue, 5 Jan 2016 13:17:17 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id CE00D6E546; Tue, 5 Jan 2016 05:17:16 -0800 (PST) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org X-Greylist: delayed 1659 seconds by postgrey-1.34 at gabe; Tue, 05 Jan 2016 05:17:16 PST Received: from mail1.gondor.com (mail.gondor.com [78.47.100.206]) by gabe.freedesktop.org (Postfix) with ESMTPS id 04C7C6E546 for ; Tue, 5 Jan 2016 05:17:16 -0800 (PST) Received: from [10.12.0.40] (helo=localhost) by mail1.gondor.com with esmtp (Exim 4.84) (envelope-from ) id 1aGR3O-0005Pp-19; Tue, 05 Jan 2016 13:49:34 +0100 Date: Tue, 5 Jan 2016 13:49:33 +0100 From: Jan Niehusmann To: Matt Roper Message-ID: <20160105124932.GA3628@x61s.reliablesolutions.de> References: <1443135200-9870-1-git-send-email-matthew.d.roper@intel.com> <1443135200-9870-3-git-send-email-matthew.d.roper@intel.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1443135200-9870-3-git-send-email-matthew.d.roper@intel.com> User-Agent: Mutt/1.5.23 (2014-03-12) Cc: intel-gfx@lists.freedesktop.org Subject: [Intel-gfx] Flicker caused by "drm/i915: Eliminate usage of plane_wm_parameters from ILK-style WM code (v2)" X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Hi, On Thu, Sep 24, 2015 at 03:53:07PM -0700, Matt Roper wrote: > Just pull the info out of the plane state structure rather than staging > it in an additional structure. > > v2: Add 'visible' condition to sprites_scaled so that we don't limit the > WM level when the sprite isn't enabled. (Ville) It looks like this patch - specifically the visible condition in ilk_compute_cur_wm - causes screen flicker when moving the cursor from one screen to another one in a multi-screen setup. My hardware is a Thinkpad x201s (http://www.thinkwiki.org/wiki/Category:X201s) 00:02.0 VGA compatible controller [0300]: Intel Corporation Core Processor Integrated Graphics Controller [8086:0046] (rev 02), CPU is an i7-620LM. The screen flickering is the one the coursor is leaving. In most cases, parts of the screen just blank for a very short moment. In some rare cases, the screen even stays blanked until I move the cursor back to that screen. No stability issues were observed, this seems to be a purely cosmetic issue. I bisected the issue to 43d59eda1f69631c267e06ab6b94ed3c14f1f6d1. As I knew the flickering was cursor-related, I tried the following minimal patch, which actually fixed the symptom, when applied to 4.4-rc8: I have no idea at all if this is actually fixing anything or if it's just hiding the real bug. All I can say is that the flickering doesn't occur any longer. Jan diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c index f091ad1..1ef0c54 100644 --- a/drivers/gpu/drm/i915/intel_pm.c +++ b/drivers/gpu/drm/i915/intel_pm.c @@ -1791,7 +1791,7 @@ static uint32_t ilk_compute_cur_wm(const struct intel_crtc_state *cstate, { int bpp = pstate->base.fb ? pstate->base.fb->bits_per_pixel / 8 : 0; - if (!cstate->base.active || !pstate->visible) + if (!cstate->base.active) return 0; return ilk_wm_method2(ilk_pipe_pixel_rate(cstate),