[Mesa-dev] [PATCH 3/9] i915, i965: Silence unused parameter warnings in intel_mipmap_tree.h

Anuj Phogat anuj.phogat at gmail.com
Thu Sep 10 11:41:49 PDT 2015


On Wed, Sep 9, 2015 at 7:18 PM, Ian Romanick <idr at freedesktop.org> wrote:

> From: Ian Romanick <ian.d.romanick at intel.com>
>
> These only occurred in release builds, but they occurred in every file
> that included intel_mipmap_tree.h.  Lots of spam. :(
>
> intel_mipmap_tree.h: In function 'intel_miptree_check_level_layer':
> intel_mipmap_tree.h:595:59: warning: unused parameter 'mt'
> [-Wunused-parameter]
>  intel_miptree_check_level_layer(struct intel_mipmap_tree *mt,
>                                                            ^
> intel_mipmap_tree.h:596:42: warning: unused parameter 'level'
> [-Wunused-parameter]
>                                  uint32_t level,
>                                           ^
> intel_mipmap_tree.h:597:42: warning: unused parameter 'layer'
> [-Wunused-parameter]
>                                  uint32_t layer)
>                                           ^
>
> Signed-off-by: Ian Romanick <ian.d.romanick at intel.com>
> ---
>  src/mesa/drivers/dri/i915/intel_mipmap_tree.h | 4 ++++
>  src/mesa/drivers/dri/i965/intel_mipmap_tree.h | 4 ++++
>  2 files changed, 8 insertions(+)
>
> diff --git a/src/mesa/drivers/dri/i915/intel_mipmap_tree.h
> b/src/mesa/drivers/dri/i915/intel_mipmap_tree.h
> index 77b1f54..d711a29 100644
> --- a/src/mesa/drivers/dri/i915/intel_mipmap_tree.h
> +++ b/src/mesa/drivers/dri/i915/intel_mipmap_tree.h
> @@ -285,6 +285,10 @@ intel_miptree_check_level_layer(struct
> intel_mipmap_tree *mt,
>                                  uint32_t level,
>                                  uint32_t layer)
>  {
> +   (void) mt;
> +   (void) level;
> +   (void) layer;
> +
>     assert(level >= mt->first_level);
>     assert(level <= mt->last_level);
>     assert(layer < mt->level[level].depth);
> diff --git a/src/mesa/drivers/dri/i965/intel_mipmap_tree.h
> b/src/mesa/drivers/dri/i965/intel_mipmap_tree.h
> index 81e5f52..d91d4be 100644
> --- a/src/mesa/drivers/dri/i965/intel_mipmap_tree.h
> +++ b/src/mesa/drivers/dri/i965/intel_mipmap_tree.h
> @@ -596,6 +596,10 @@ intel_miptree_check_level_layer(struct
> intel_mipmap_tree *mt,
>                                  uint32_t level,
>                                  uint32_t layer)
>  {
> +   (void) mt;
> +   (void) level;
> +   (void) layer;
> +
>     assert(level >= mt->first_level);
>     assert(level <= mt->last_level);
>     assert(layer < mt->level[level].depth);
> --
> 2.1.0
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev


Same suggestion as on patch 1.

Reviewed-by: Anuj Phogat <anuj.phogat at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20150910/d31cf29a/attachment.html>


More information about the mesa-dev mailing list