Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Gupta, Sourab" <sourab.gupta@intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>
Cc: "S, Deepak" <deepak.s@intel.com>,
	"intel-gfx@lists.freedesktop.org"
	<intel-gfx@lists.freedesktop.org>,
	"Goel, Akash" <akash.goel@intel.com>
Subject: Re: [PATCH 1/2] drm/i915: Replaced Blitter ring based flips with MMIO flips
Date: Wed, 28 May 2014 09:42:51 +0000	[thread overview]
Message-ID: <1401270219.9396.102.camel@sourabgu-desktop> (raw)
In-Reply-To: <20140528073014.GC18409@nuc-i3427.alporthouse.com>

On Wed, 2014-05-28 at 07:30 +0000, Chris Wilson wrote:
> On Wed, May 28, 2014 at 12:42:01PM +0530, sourab.gupta@intel.com wrote:
> > +static int intel_postpone_flip(struct drm_i915_gem_object *obj)
> > +{
> > +	int ret;
> > +
> > +	if (!obj->ring)
> > +		return 0;
> > +
> > +	if (i915_seqno_passed(obj->ring->get_seqno(obj->ring, true),
> > +				obj->last_write_seqno))
> > +		return 0;
> 
> obj->last_write_seqno could be 0 here. To be correct, test against
> obj->last_write_seqno == 0 instead of obj->ring == NULL first.
> 
> > +	ret = i915_gem_check_olr(obj->ring, obj->last_write_seqno);
> > +	if (ret)
> > +		return ret;
> > +
> > +	if (WARN_ON(!obj->ring->irq_get(obj->ring)))
> > +		return 0;
> > +
> > +	return 1;
> > +}
> > +
> 
> >  static int intel_default_queue_flip(struct drm_device *dev,
> >  				    struct drm_crtc *crtc,
> >  				    struct drm_framebuffer *fb,
> > @@ -11515,6 +11652,9 @@ static void intel_init_display(struct drm_device *dev)
> >  		break;
> >  	}
> >  
> > +	if (intel_use_mmio_flip(dev))
> > +		dev_priv->display.queue_flip = intel_queue_mmio_flip;
> 
> I'd still like to see this as a tristate, i.e. use_mmio_flip(dev) > 1
> here. E.g. we will want to use mmio flips for !BCS, but GPU flips when
> BCS is active.
> -Chris
> 
Hi Chris,
We can extend the module param to have tristate here, but since the
current design assigns the .queue_flip parameter at the init time, not
at the page flip time, this kind of usecase of having driver discretion
in terms of assigning CS vs MMIO flip can't be applied in this patch.

If required, we can have a subsequent patch to make a flip time decision
of MMIO vs CS flip based on module parameter.

Regards,
Sourab

  reply	other threads:[~2014-05-28  9:42 UTC|newest]

Thread overview: 67+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-09 11:26 [PATCH 0/2] Using MMIO based flips on VLV akash.goel
2014-01-09 11:26 ` [PATCH 1/2] drm/i915: Creating a new workqueue to handle MMIO flip work items akash.goel
2014-01-09 11:26 ` [PATCH 2/2] drm/i915/vlv: Replaced Blitter ring based flips with MMIO Flips for VLV akash.goel
2014-01-09 11:31   ` Chris Wilson
2014-01-13  9:47     ` Goel, Akash
2014-02-07 11:59       ` Goel, Akash
2014-02-07 14:47         ` Daniel Vetter
2014-02-07 17:17           ` Goel, Akash
     [not found]           ` <8BF5CF93467D8C498F250C96583BC09CC718E3@BGSMSX103.gar.corp.intel.com>
2014-03-07 13:17             ` Gupta, Sourab
2014-03-07 13:30               ` Ville Syrjälä
2014-03-13  7:21                 ` [PATCH] drm/i915: Replaced Blitter ring based flips with MMIO flips " sourab.gupta
2014-03-13  9:01                 ` [PATCH v2] " sourab.gupta
2014-03-17  4:33                   ` Gupta, Sourab
2014-03-21 17:10                   ` Gupta, Sourab
2014-03-21 18:15                   ` Damien Lespiau
2014-03-23  9:01                     ` [PATCH v3] " sourab.gupta
2014-03-26  7:49                       ` Gupta, Sourab
2014-04-03  8:40                         ` Gupta, Sourab
2014-04-07 11:19                           ` Gupta, Sourab
2014-05-09 11:59                       ` Ville Syrjälä
2014-05-09 13:28                         ` Ville Syrjälä
2014-05-09 17:18                         ` Ville Syrjälä
2014-05-15  6:17                           ` [PATCH v4] " sourab.gupta
2014-05-15 12:27                             ` Ville Syrjälä
2014-05-16 12:34                               ` Gupta, Sourab
2014-05-16 12:51                                 ` Ville Syrjälä
2014-05-19  9:19                                   ` Gupta, Sourab
2014-05-19 10:58                                   ` [PATCH v5] " sourab.gupta
2014-05-19 11:47                                     ` Ville Syrjälä
2014-05-19 12:29                                       ` Daniel Vetter
2014-05-19 13:06                                         ` Ville Syrjälä
2014-05-19 13:41                                           ` Daniel Vetter
2014-05-20 10:49                                             ` [PATCH 0/3] Replace Blitter ring based flips with MMIO flips sourab.gupta
2014-05-20 10:49                                               ` [PATCH v6 1/3] drm/i915: Replaced " sourab.gupta
2014-05-20 11:59                                                 ` Chris Wilson
2014-05-20 18:01                                                   ` Gupta, Sourab
2014-05-22 14:36                                                     ` [PATCH v2 0/3] Replace " sourab.gupta
2014-05-22 14:36                                                       ` [PATCH v7 1/3] drm/i915: Replaced " sourab.gupta
2014-05-27 12:52                                                         ` Ville Syrjälä
2014-05-27 13:09                                                           ` Daniel Vetter
2014-05-28  7:12                                                             ` [PATCH v3 0/2] Replace " sourab.gupta
2014-05-28  7:12                                                               ` [PATCH 1/2] drm/i915: Replaced " sourab.gupta
2014-05-28  7:30                                                                 ` Chris Wilson
2014-05-28  9:42                                                                   ` Gupta, Sourab [this message]
2014-05-28  7:31                                                                 ` Chris Wilson
2014-05-28  8:12                                                                   ` Ville Syrjälä
2014-05-28  7:12                                                               ` [PATCH 2/2] drm/i915: Default to mmio flips on VLV sourab.gupta
2014-05-28  9:56                                                                 ` Chris Wilson
2014-05-29  9:40                                                                   ` [PATCH v4 0/3] Replace Blitter ring based flips with MMIO flips sourab.gupta
2014-05-29  9:40                                                                     ` [PATCH v9 1/3] drm/i915: Replaced " sourab.gupta
2014-05-30 10:31                                                                       ` Chris Wilson
2014-05-29  9:40                                                                     ` [PATCH 2/3] drm/i915: Selection of MMIO vs CS flip at page flip time sourab.gupta
2014-05-29  9:40                                                                     ` [PATCH 3/3] drm/i915: Make module param for MMIO flip selection as tristate sourab.gupta
2014-05-30 10:49                                                                       ` Chris Wilson
2014-06-01 11:13                                                                         ` [PATCH v10] drm/i915: Replaced Blitter ring based flips with MMIO flips sourab.gupta
2014-06-02  6:56                                                                           ` Chris Wilson
2014-06-02 10:38                                                                             ` Gupta, Sourab
2014-06-02 10:56                                                                               ` Chris Wilson
2014-06-02 11:17                                                                                 ` [PATCH v11] " sourab.gupta
2014-06-17 14:14                                                                                   ` Daniel Vetter
2014-06-17 14:17                                                                                     ` Chris Wilson
2014-05-22 14:36                                                       ` [PATCH 2/3] drm/i915: Default to mmio flips on VLV sourab.gupta
2014-05-22 14:36                                                       ` [PATCH 3/3] drm/i915: Fix mmio page flip vs mmio set base race sourab.gupta
2014-05-26  8:51                                                       ` [PATCH v2 0/3] Replace Blitter ring based flips with MMIO flips Gupta, Sourab
2014-05-20 10:49                                               ` [PATCH 2/3] drm/i915: Default to mmio flips on VLV sourab.gupta
2014-05-20 10:49                                               ` [PATCH 3/3] drm/i915: Fix mmio page flip vs mmio set base race sourab.gupta
2014-01-09 11:29 ` [PATCH 0/2] Using MMIO based flips on VLV Chris Wilson

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=1401270219.9396.102.camel@sourabgu-desktop \
    --to=sourab.gupta@intel.com \
    --cc=akash.goel@intel.com \
    --cc=chris@chris-wilson.co.uk \
    --cc=deepak.s@intel.com \
    --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