From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rodrigo Vivi Subject: Re: [PATCH 41/89] drm/i915/skl: Introduce intel_num_planes() Date: Wed, 17 Sep 2014 15:13:31 -0700 Message-ID: References: <1409830075-11139-1-git-send-email-damien.lespiau@intel.com> <1409830075-11139-42-git-send-email-damien.lespiau@intel.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1251662111==" Return-path: Received: from mail-wg0-f48.google.com (mail-wg0-f48.google.com [74.125.82.48]) by gabe.freedesktop.org (Postfix) with ESMTP id 984F36E022 for ; Wed, 17 Sep 2014 15:13:32 -0700 (PDT) Received: by mail-wg0-f48.google.com with SMTP id m15so6498wgh.7 for ; Wed, 17 Sep 2014 15:13:31 -0700 (PDT) In-Reply-To: <1409830075-11139-42-git-send-email-damien.lespiau@intel.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" To: Damien Lespiau Cc: intel-gfx List-Id: intel-gfx@lists.freedesktop.org --===============1251662111== Content-Type: multipart/alternative; boundary=f46d043c7f04a554ea05034a2d5e --f46d043c7f04a554ea05034a2d5e Content-Type: text/plain; charset=UTF-8 Reviewed-by: Rodrigo Vivi On Thu, Sep 4, 2014 at 4:27 AM, Damien Lespiau wrote: > It can be handy to get the number of planes for this pipe, ie including > the primary plane to loop over them. Introduce a little function to do > so. > > Signed-off-by: Damien Lespiau > --- > drivers/gpu/drm/i915/intel_drv.h | 8 ++++++++ > 1 file changed, 8 insertions(+) > > diff --git a/drivers/gpu/drm/i915/intel_drv.h > b/drivers/gpu/drm/i915/intel_drv.h > index d727d20..3239e58 100644 > --- a/drivers/gpu/drm/i915/intel_drv.h > +++ b/drivers/gpu/drm/i915/intel_drv.h > @@ -721,6 +721,14 @@ hdmi_to_dig_port(struct intel_hdmi *intel_hdmi) > return container_of(intel_hdmi, struct intel_digital_port, hdmi); > } > > +/* > + * Returns the number of planes for this pipe, ie the number of sprites + > 1 > + * (primary plane). This doesn't count the cursor plane then. > + */ > +static inline unsigned int intel_num_planes(struct intel_crtc *crtc) > +{ > + return INTEL_INFO(crtc->base.dev)->num_sprites[crtc->pipe] + 1; > +} > > /* i915_irq.c */ > bool intel_set_cpu_fifo_underrun_reporting(struct drm_device *dev, > -- > 1.8.3.1 > > _______________________________________________ > Intel-gfx mailing list > Intel-gfx@lists.freedesktop.org > http://lists.freedesktop.org/mailman/listinfo/intel-gfx > -- Rodrigo Vivi Blog: http://blog.vivi.eng.br --f46d043c7f04a554ea05034a2d5e Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>

On Thu, Sep 4, 2014 at 4:27 AM, Damien Les= piau <damien.lespiau@intel.com> wrote:
It can be handy to get the number of planes for this pi= pe, ie including
the primary plane to loop over them. Introduce a little function to do
so.

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
---
=C2=A0drivers/gpu/drm/i915/intel_drv.h | 8 ++++++++
=C2=A01 file changed, 8 insertions(+)

diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_= drv.h
index d727d20..3239e58 100644
--- a/drivers/gpu/drm/i915/intel_drv.h
+++ b/drivers/gpu/drm/i915/intel_drv.h
@@ -721,6 +721,14 @@ hdmi_to_dig_port(struct intel_hdmi *intel_hdmi)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 return container_of(intel_hdmi, struct intel_di= gital_port, hdmi);
=C2=A0}

+/*
+ * Returns the number of planes for this pipe, ie the number of sprites + = 1
+ * (primary plane). This doesn't count the cursor plane then.
+ */
+static inline unsigned int intel_num_planes(struct intel_crtc *crtc)
+{
+=C2=A0 =C2=A0 =C2=A0 =C2=A0return INTEL_INFO(crtc->base.dev)->num_sp= rites[crtc->pipe] + 1;
+}

=C2=A0/* i915_irq.c */
=C2=A0bool intel_set_cpu_fifo_underrun_reporting(struct drm_device *dev, --
1.8.3.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesk= top.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx



--
Rodrigo Vivi
=C2=A0
--f46d043c7f04a554ea05034a2d5e-- --===============1251662111== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/intel-gfx --===============1251662111==--