intel-gfx.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
From: "Zanoni, Paulo R" <paulo.r.zanoni@intel.com>
To: "daniel@ffwll.ch" <daniel@ffwll.ch>
Cc: "intel-gfx@lists.freedesktop.org" <intel-gfx@lists.freedesktop.org>
Subject: Re: [RFC xf86-video-intel] sna: Call dirtyfb for all non-tear-free cases
Date: Tue, 22 Mar 2016 21:35:36 +0000	[thread overview]
Message-ID: <1458682535.2189.23.camel@intel.com> (raw)
In-Reply-To: <20160322113109.GD28483@phenom.ffwll.local>

Em Ter, 2016-03-22 às 12:31 +0100, Daniel Vetter escreveu:
> On Mon, Mar 21, 2016 at 04:26:55PM -0300, Paulo Zanoni wrote:
> > 
> > The sna_mode_wants_tear_free() function tries to detect FBC and PSR
> > based on Kernel module parameters. Currently it fails to detect FBC
> > due to the default enable_fbc value being -1. While this can easily
> > be
> > fixed in the Kernel, I had a conversation with Daniel and he
> > expressed
> > unhappiness with that solution, claiming that yet another different
> > code path just for a feature that should be transparent is not a
> > good
> > way to go, and that we should do proper frontbuffer rendering.
> > 
> > So with this patch, we'll have the DDX issuing dirtyfb calls even
> > if
> > TearFree is not enabled, fixing FBC when i915.enable_fbc=-1.
> > 
> > This fixes a bug that happens on SKL with FBC enabled: if you run
> > lightdm, your login/password won't appear as you type on your
> > keyboard. You have to move the mouse over the input box for them to
> > be
> > displayed.
> > 
> > Cc: Chris Wilson <chris@chris-wilson.co.uk>
> > Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
> I thought we need this anyway to get the kernel to allow fbc, since
> SNA
> ends up mmap some of the drm_framebuffer. Even when they're not
> frontbuffers.

If we merge patch 2/4, we won't need this one since TearFree will be in
use, and it seems TearFree doesn't touch frontbuffers, so we'll always
get the flush calls during page flips.

> -Daniel
> 
> > 
> > ---
> >  src/sna/sna_driver.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/src/sna/sna_driver.c b/src/sna/sna_driver.c
> > index b245594..84e8e55 100644
> > --- a/src/sna/sna_driver.c
> > +++ b/src/sna/sna_driver.c
> > @@ -654,7 +654,7 @@ static Bool sna_pre_init(ScrnInfoPtr scrn, int
> > probe)
> >  	}
> >  	scrn->currentMode = scrn->modes;
> >  
> > -	if (!setup_tear_free(sna) &&
> > sna_mode_wants_tear_free(sna))
> > +	if (!setup_tear_free(sna))
> >  		sna->kgem.needs_dirtyfb = sna->kgem.has_dirtyfb;
> >  
> >  	xf86SetGamma(scrn, zeros);
> > -- 
> > 2.7.0
> > 
> > _______________________________________________
> > 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

  parent reply	other threads:[~2016-03-22 21:35 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-21 19:26 [PATCH 0/4] Enable FBC on SKL Paulo Zanoni
2016-03-21 19:26 ` [PATCH 1/4] drm/i915/fbc: update busy_bits even for GTT and flip flushes Paulo Zanoni
2016-03-22 11:13   ` Daniel Vetter
2016-03-22 21:33     ` Zanoni, Paulo R
2016-03-21 19:26 ` [RFC xf86-video-intel] sna: Call dirtyfb for all non-tear-free cases Paulo Zanoni
2016-03-22 11:31   ` Daniel Vetter
2016-03-22 11:36     ` Chris Wilson
2016-03-22 21:35     ` Zanoni, Paulo R [this message]
2016-03-23  8:50       ` Daniel Vetter
2016-03-23 13:16         ` Zanoni, Paulo R
2016-03-21 19:26 ` [PATCH 2/4] drm/i915/fbc: sanitize i915.enable_fbc during FBC init Paulo Zanoni
2016-03-21 19:26 ` [PATCH 3/4] drm/i915: opt-out CPU and WC mmaps from FBC Paulo Zanoni
2016-03-22  2:19   ` kbuild test robot
2016-03-22 10:28   ` Jani Nikula
2016-03-22 11:15     ` Daniel Vetter
2016-03-22 13:52       ` Jani Nikula
2016-03-22 11:29   ` Daniel Vetter
2016-03-22 21:48     ` Zanoni, Paulo R
2016-03-23  8:53       ` Daniel Vetter
2016-03-23 16:04         ` Vivi, Rodrigo
2016-03-21 19:26 ` [PATCH 4/4] drm/i915/fbc: enable FBC on SKL too Paulo Zanoni
2016-03-22 11:16   ` Daniel Vetter
2016-03-22 21:51     ` Zanoni, Paulo R
2016-03-23  8:55       ` Daniel Vetter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1458682535.2189.23.camel@intel.com \
    --to=paulo.r.zanoni@intel.com \
    --cc=daniel@ffwll.ch \
    --cc=intel-gfx@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).