From: Daniel Vetter Subject: Re: [PATCH 17/17] drm/i915: Add comments about units of latency values Date: Mon, 5 Aug 2013 18:41:55 +0200 Message-ID: <20130805163940.GP22035@phenom.ffwll.local> References: <1375363135-20618-1-git-send-email-ville.syrjala@linux.intel.com> <1375363135-20618-18-git-send-email-ville.syrjala@linux.intel.com> <20130802160931.GO5004@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: Received: from mail-wi0-f169.google.com (mail-wi0-f169.google.com [209.85.212.169]) by gabe.freedesktop.org (Postfix) with ESMTP id 0CC12E71AC for ; Mon, 5 Aug 2013 09:41:48 -0700 (PDT) Received: by mail-wi0-f169.google.com with SMTP id f14so1772413wiw.4 for ; Mon, 05 Aug 2013 09:41:48 -0700 (PDT) Content-Disposition: inline In-Reply-To: <20130802160931.GO5004@intel.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org Errors-To: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org To: Ville =?iso-8859-1?Q?Syrj=E4l=E4?= Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Fri, Aug 02, 2013 at 07:09:31PM +0300, Ville Syrj=E4l=E4 wrote: > On Fri, Aug 02, 2013 at 12:58:07PM -0300, Paulo Zanoni wrote: > > 2013/8/1 : > > > From: Ville Syrj=E4l=E4 > > > > > > All the ILK+ WM compute functions take the latency values in 0.1us > > > units. Add a few comments to remind people about that. > > > > > > Signed-off-by: Ville Syrj=E4l=E4 > > = > > Reviewed-by: Paulo Zanoni > > = > > (but I would have written Latency instead of latency :P ) > = > I was considering going for full blown kernel-doc, but since we don't > currently generate docs for i915, i just used the name of the argument > in question. We'll get there ;-) For kerneldoc I think we should first still plug some holes in drm core, but those get filled fast. Next up is properly documenting the userspace ioctl interface and related stuff. Then we can tackle real kerneldoc for important functions. Probably still a few years off ;-) I've (hopefully) merged all the remaining patches in this series with the exception of the fixup for the very first patch. Please resend that cute little bikeshed. Thanks for the patches&reivew. -Daniel > = > > > --- > > > drivers/gpu/drm/i915/intel_pm.c | 17 ++++++++++++++--- > > > 1 file changed, 14 insertions(+), 3 deletions(-) > > > > > > diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/i= ntel_pm.c > > > index 5fe8c4e..51f445f 100644 > > > --- a/drivers/gpu/drm/i915/intel_pm.c > > > +++ b/drivers/gpu/drm/i915/intel_pm.c > > > @@ -2108,6 +2108,7 @@ static uint32_t ilk_pipe_pixel_rate(struct drm_= device *dev, > > > return pixel_rate; > > > } > > > > > > +/* latency must be in 0.1us units. */ > > > static uint32_t ilk_wm_method1(uint32_t pixel_rate, uint8_t bytes_pe= r_pixel, > > > uint32_t latency) > > > { > > > @@ -2122,6 +2123,7 @@ static uint32_t ilk_wm_method1(uint32_t pixel_r= ate, uint8_t bytes_per_pixel, > > > return ret; > > > } > > > > > > +/* latency must be in 0.1us units. */ > > > static uint32_t ilk_wm_method2(uint32_t pixel_rate, uint32_t pipe_ht= otal, > > > uint32_t horiz_pixels, uint8_t bytes_p= er_pixel, > > > uint32_t latency) > > > @@ -2185,7 +2187,10 @@ enum hsw_data_buf_partitioning { > > > HSW_DATA_BUF_PART_5_6, > > > }; > > > > > > -/* For both WM_PIPE and WM_LP. */ > > > +/* > > > + * For both WM_PIPE and WM_LP. > > > + * mem_value must be in 0.1us units. > > > + */ > > > static uint32_t ilk_compute_pri_wm(struct hsw_pipe_wm_parameters *pa= rams, > > > uint32_t mem_value, > > > bool is_lp) > > > @@ -2212,7 +2217,10 @@ static uint32_t ilk_compute_pri_wm(struct hsw_= pipe_wm_parameters *params, > > > return min(method1, method2); > > > } > > > > > > -/* For both WM_PIPE and WM_LP. */ > > > +/* > > > + * For both WM_PIPE and WM_LP. > > > + * mem_value must be in 0.1us units. > > > + */ > > > static uint32_t ilk_compute_spr_wm(struct hsw_pipe_wm_parameters *pa= rams, > > > uint32_t mem_value) > > > { > > > @@ -2232,7 +2240,10 @@ static uint32_t ilk_compute_spr_wm(struct hsw_= pipe_wm_parameters *params, > > > return min(method1, method2); > > > } > > > > > > -/* For both WM_PIPE and WM_LP. */ > > > +/* > > > + * For both WM_PIPE and WM_LP. > > > + * mem_value must be in 0.1us units. > > > + */ > > > static uint32_t ilk_compute_cur_wm(struct hsw_pipe_wm_parameters *pa= rams, > > > uint32_t mem_value) > > > { > > > -- > > > 1.8.1.5 > > > > > > _______________________________________________ > > > Intel-gfx mailing list > > > Intel-gfx@lists.freedesktop.org > > > http://lists.freedesktop.org/mailman/listinfo/intel-gfx > > = > > = > > = > > -- = > > Paulo Zanoni > = > -- = > Ville Syrj=E4l=E4 > Intel OTC > _______________________________________________ > Intel-gfx mailing list > Intel-gfx@lists.freedesktop.org > http://lists.freedesktop.org/mailman/listinfo/intel-gfx -- = Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch