[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <bc824d69-7afc-6acb-7251-57dbe6d4c3f1@linux.intel.com>
Date: Thu, 18 Apr 2019 07:54:16 -0500
From: Pierre-Louis Bossart <pierre-louis.bossart@...ux.intel.com>
To: Yue Haibing <yuehaibing@...wei.com>,
liam.r.girdwood@...ux.intel.com, yang.jie@...ux.intel.com,
broonie@...nel.org, perex@...ex.cz, tiwai@...e.com
Cc: linux-kernel@...r.kernel.org, alsa-devel@...a-project.org
Subject: Re: [alsa-devel] [PATCH v2 -next] ASoC: Intel: Haswell: Remove set
but not used variable 'stage_type'
On 4/17/19 9:48 PM, Yue Haibing wrote:
> From: YueHaibing <yuehaibing@...wei.com>
>
> Fixes gcc '-Wunused-but-set-variable' warning:
>
> sound/soc/intel/haswell/sst-haswell-ipc.c: In function 'hsw_stream_message':
> sound/soc/intel/haswell/sst-haswell-ipc.c:669:29: warning: variable 'stage_type' set but not used [-Wunused-but-set-variable]
>
> It is never used since introduction in
> commit ba57f68235cf ("ASoC: Intel: create haswell folder and move haswell platform files in")
>
> Signed-off-by: YueHaibing <yuehaibing@...wei.com>
Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@...ux.intel.com>
Thanks!
> ---
> v2: also remove the variable declaration and the static inline mst_get_stage_type
> ---
> sound/soc/intel/haswell/sst-haswell-ipc.c | 8 +-------
> 1 file changed, 1 insertion(+), 7 deletions(-)
>
> diff --git a/sound/soc/intel/haswell/sst-haswell-ipc.c b/sound/soc/intel/haswell/sst-haswell-ipc.c
> index 31fcdf12..74acf9c 100644
> --- a/sound/soc/intel/haswell/sst-haswell-ipc.c
> +++ b/sound/soc/intel/haswell/sst-haswell-ipc.c
> @@ -345,11 +345,6 @@ static inline u32 msg_get_stream_type(u32 msg)
> return (msg & IPC_STR_TYPE_MASK) >> IPC_STR_TYPE_SHIFT;
> }
>
> -static inline u32 msg_get_stage_type(u32 msg)
> -{
> - return (msg & IPC_STG_TYPE_MASK) >> IPC_STG_TYPE_SHIFT;
> -}
> -
> static inline u32 msg_get_stream_id(u32 msg)
> {
> return (msg & IPC_STR_ID_MASK) >> IPC_STR_ID_SHIFT;
> @@ -666,13 +661,12 @@ static int hsw_module_message(struct sst_hsw *hsw, u32 header)
>
> static int hsw_stream_message(struct sst_hsw *hsw, u32 header)
> {
> - u32 stream_msg, stream_id, stage_type;
> + u32 stream_msg, stream_id;
> struct sst_hsw_stream *stream;
> int handled = 0;
>
> stream_msg = msg_get_stream_type(header);
> stream_id = msg_get_stream_id(header);
> - stage_type = msg_get_stage_type(header);
>
> stream = get_stream_by_id(hsw, stream_id);
> if (stream == NULL)
>
Powered by blists - more mailing lists