From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ville =?iso-8859-1?Q?Syrj=E4l=E4?= Subject: Re: [PATCH 1/2] drm/i915: Use anonymous union/struct to save space taken by latency values Date: Wed, 10 Sep 2014 20:33:28 +0300 Message-ID: <20140910173328.GA4193@intel.com> References: <1409921592-23754-1-git-send-email-damien.lespiau@intel.com> <1409921592-23754-2-git-send-email-damien.lespiau@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by gabe.freedesktop.org (Postfix) with ESMTP id 946226E3DE for ; Wed, 10 Sep 2014 10:33:35 -0700 (PDT) Content-Disposition: inline In-Reply-To: <1409921592-23754-2-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@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Fri, Sep 05, 2014 at 01:53:11PM +0100, Damien Lespiau wrote: > Suggested-by: Ville Syrj=E4l=E4 > Signed-off-by: Damien Lespiau I think I'll punt on reviewing this for now. I need to go through the other skl wm stuff first, and then I probaly need to stare at the result a bit before I can think about unification. > --- > drivers/gpu/drm/i915/i915_drv.h | 38 +++++++++++++++++++++--------------= --- > 1 file changed, 21 insertions(+), 17 deletions(-) > = > diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_= drv.h > index 0baf7f3..8471d12 100644 > --- a/drivers/gpu/drm/i915/i915_drv.h > +++ b/drivers/gpu/drm/i915/i915_drv.h > @@ -1730,23 +1730,27 @@ struct drm_i915_private { > struct vlv_s0ix_state vlv_s0ix_state; > = > struct { > - /* > - * Raw watermark latency values: > - * in 0.1us units for WM0, > - * in 0.5us units for WM1+. > - */ > - /* primary */ > - uint16_t pri_latency[5]; > - /* sprite */ > - uint16_t spr_latency[5]; > - /* cursor */ > - uint16_t cur_latency[5]; > - /* > - * Raw watermark memory latency values > - * for SKL for all 8 levels > - * in 1us units. > - */ > - uint16_t skl_latency[8]; > + union { > + /* > + * Raw watermark latency values: > + * in 0.1us units for WM0, > + * in 0.5us units for WM1+. > + */ > + struct { > + /* primary */ > + uint16_t pri_latency[5]; > + /* sprite */ > + uint16_t spr_latency[5]; > + /* cursor */ > + uint16_t cur_latency[5]; > + }; > + > + /* > + * Raw watermark memory latency values for SKL for all > + * 8 levels. In 1us units. > + */ > + uint16_t skl_latency[8]; > + }; > = > /* > * The skl_wm_values structure is a bit too big for stack > -- = > 1.8.3.1 -- = Ville Syrj=E4l=E4 Intel OTC