alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2
@ 2020-07-07 19:16 Pierre-Louis Bossart
  2020-07-07 19:16 ` [PATCH v3 01/10] ASoC: qcom: q6asm: fix kernel-doc Pierre-Louis Bossart
                   ` (11 more replies)
  0 siblings, 12 replies; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-07 19:16 UTC (permalink / raw)
  To: alsa-devel; +Cc: tiwai, broonie, Lee Jones, Pierre-Louis Bossart

Both Lee Jones and I submitted separate series, this is the second
part of the merged result, for which no feedback was provided.

I picked Lee's patches for rt5659 and ak4458 and added the pxa and
ux500 that I didn't fix. The rest is largely identical between our
respective series, with the exception of the sunxi which I documented
and Lee removed. I don't have any specific preference and will go with
the flow on this.

Lee Jones (4):
  ASoC: pxa: pxa-ssp: Demote seemingly unintentional kerneldoc header
  ASoC: ux500: ux500_msp_i2s: Remove unused variables 'reg_val_DR' and
    'reg_val_TSTDR'
  ASoC: codecs: rt5659: Remove many unused const variables
  ASoC: codecs: ak4458: Remove set but never checked variable 'ret'

Pierre-Louis Bossart (6):
  ASoC: qcom: q6asm: fix kernel-doc
  ASoC: sunxi: sun4i-i2s: fix kernel-doc
  ASoC: sunxi: sun4i-spdif: fix kernel-doc
  ASoC: sti: uniperif: fix 'defined by not used' warning
  ASoC: codecs: rt5631: fix kernel-doc
  ASoC: codecs: tlv320aic26: fix kernel-doc warning

 sound/soc/codecs/ak4458.c       |  6 +++---
 sound/soc/codecs/rt5631.c       |  8 +++++--
 sound/soc/codecs/rt5659.c       | 37 ---------------------------------
 sound/soc/codecs/tlv320aic26.c  |  2 +-
 sound/soc/pxa/pxa-ssp.c         |  2 +-
 sound/soc/qcom/qdsp6/q6asm.c    |  2 +-
 sound/soc/sti/uniperif.h        |  2 +-
 sound/soc/sunxi/sun4i-i2s.c     | 10 ++++++++-
 sound/soc/sunxi/sun4i-spdif.c   |  2 +-
 sound/soc/ux500/ux500_msp_i2s.c |  8 +++----
 10 files changed, 27 insertions(+), 52 deletions(-)

-- 
2.25.1


^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH v3 01/10] ASoC: qcom: q6asm: fix kernel-doc
  2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
@ 2020-07-07 19:16 ` Pierre-Louis Bossart
  2020-07-07 19:16 ` [PATCH v3 02/10] ASoC: sunxi: sun4i-i2s: " Pierre-Louis Bossart
                   ` (10 subsequent siblings)
  11 siblings, 0 replies; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-07 19:16 UTC (permalink / raw)
  To: alsa-devel
  Cc: Banajit Goswami, Kees Cook, tiwai, open list, Patrick Lai,
	Takashi Iwai, Pierre-Louis Bossart, Liam Girdwood, Weitao Hou,
	Vinod Koul, broonie, Srinivas Kandagatla, Lee Jones

Fix W=1 warning - missing parameter description

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
 sound/soc/qcom/qdsp6/q6asm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/qcom/qdsp6/q6asm.c b/sound/soc/qcom/qdsp6/q6asm.c
index ae4b2cabdf2d..d67b23a5f397 100644
--- a/sound/soc/qcom/qdsp6/q6asm.c
+++ b/sound/soc/qcom/qdsp6/q6asm.c
@@ -912,9 +912,9 @@ static int q6asm_ac_send_cmd_sync(struct audio_client *ac, struct apr_pkt *pkt)
 
 /**
  * q6asm_open_write() - Open audio client for writing
- *
  * @ac: audio client pointer
  * @format: audio sample format
+ * @codec_profile: compressed format profile
  * @bits_per_sample: bits per sample
  *
  * Return: Will be an negative value on error or zero on success
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v3 02/10] ASoC: sunxi: sun4i-i2s: fix kernel-doc
  2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
  2020-07-07 19:16 ` [PATCH v3 01/10] ASoC: qcom: q6asm: fix kernel-doc Pierre-Louis Bossart
@ 2020-07-07 19:16 ` Pierre-Louis Bossart
  2020-07-08  8:11   ` Maxime Ripard
  2020-07-07 19:16 ` [PATCH v3 03/10] ASoC: sunxi: sun4i-spdif: " Pierre-Louis Bossart
                   ` (9 subsequent siblings)
  11 siblings, 1 reply; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-07 19:16 UTC (permalink / raw)
  To: alsa-devel
  Cc: Liam Girdwood, tiwai, open list, Takashi Iwai,
	Pierre-Louis Bossart, Maxime Ripard, Marcus Cooper, Chen-Yu Tsai,
	broonie, Lee Jones,
	moderated list:ARM/Allwinner sunXi SoC support

Fix W=1 warnings - missing fields in description

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
 sound/soc/sunxi/sun4i-i2s.c | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/sound/soc/sunxi/sun4i-i2s.c b/sound/soc/sunxi/sun4i-i2s.c
index d0a8d5810c0a..f23ff29e7c1d 100644
--- a/sound/soc/sunxi/sun4i-i2s.c
+++ b/sound/soc/sunxi/sun4i-i2s.c
@@ -128,13 +128,21 @@ struct sun4i_i2s;
 
 /**
  * struct sun4i_i2s_quirks - Differences between SoC variants.
- *
  * @has_reset: SoC needs reset deasserted.
  * @reg_offset_txdata: offset of the tx fifo.
  * @sun4i_i2s_regmap: regmap config to use.
  * @field_clkdiv_mclk_en: regmap field to enable mclk output.
  * @field_fmt_wss: regmap field to set word select size.
  * @field_fmt_sr: regmap field to set sample resolution.
+ * @bclk_dividers: bit clock dividers array
+ * @num_bclk_dividers: number of bit clock dividers
+ * @mclk_dividers: mclk dividers array
+ * @num_mclk_dividers: number of mclk dividers
+ * @get_bclk_parent_rate: callback to get bclk parent rate
+ * @get_sr: callback to get sample resolution
+ * @get_wss: callback to get word select size
+ * @set_chan_cfg: callback to set channel configuration
+ * @set_fmt: callback to set format
  */
 struct sun4i_i2s_quirks {
 	bool				has_reset;
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v3 03/10] ASoC: sunxi: sun4i-spdif: fix kernel-doc
  2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
  2020-07-07 19:16 ` [PATCH v3 01/10] ASoC: qcom: q6asm: fix kernel-doc Pierre-Louis Bossart
  2020-07-07 19:16 ` [PATCH v3 02/10] ASoC: sunxi: sun4i-i2s: " Pierre-Louis Bossart
@ 2020-07-07 19:16 ` Pierre-Louis Bossart
  2020-07-08  8:12   ` Maxime Ripard
  2020-07-07 19:16 ` [PATCH v3 04/10] ASoC: pxa: pxa-ssp: Demote seemingly unintentional kerneldoc header Pierre-Louis Bossart
                   ` (8 subsequent siblings)
  11 siblings, 1 reply; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-07 19:16 UTC (permalink / raw)
  To: alsa-devel
  Cc: Rafael J. Wysocki, Kuninori Morimoto, Liam Girdwood, tiwai,
	open list, Masahiro Yamada, Takashi Iwai, Pierre-Louis Bossart,
	Maxime Ripard, Bartosz Golaszewski, Chen-Yu Tsai, broonie,
	Lee Jones, moderated list:ARM/Allwinner sunXi SoC support

Fix W=1 warning - typo in field description

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
 sound/soc/sunxi/sun4i-spdif.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/sunxi/sun4i-spdif.c b/sound/soc/sunxi/sun4i-spdif.c
index 86779a99df75..326dd45e39da 100644
--- a/sound/soc/sunxi/sun4i-spdif.c
+++ b/sound/soc/sunxi/sun4i-spdif.c
@@ -167,7 +167,7 @@
 /**
  * struct sun4i_spdif_quirks - Differences between SoC variants.
  *
- * @reg_dac_tx_data: TX FIFO offset for DMA config.
+ * @reg_dac_txdata: TX FIFO offset for DMA config.
  * @has_reset: SoC needs reset deasserted.
  * @val_fctl_ftx: TX FIFO flush bitmask.
  */
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v3 04/10] ASoC: pxa: pxa-ssp: Demote seemingly unintentional kerneldoc header
  2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
                   ` (2 preceding siblings ...)
  2020-07-07 19:16 ` [PATCH v3 03/10] ASoC: sunxi: sun4i-spdif: " Pierre-Louis Bossart
@ 2020-07-07 19:16 ` Pierre-Louis Bossart
  2020-07-07 19:16 ` [PATCH v3 05/10] ASoC: ux500: ux500_msp_i2s: Remove unused variables 'reg_val_DR' and 'reg_val_TSTDR' Pierre-Louis Bossart
                   ` (7 subsequent siblings)
  11 siblings, 0 replies; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-07 19:16 UTC (permalink / raw)
  To: alsa-devel
  Cc: open list, tiwai, Lee Jones, Takashi Iwai, Pierre-Louis Bossart,
	Haojian Zhuang, Liam Girdwood, broonie,
	moderated list:PXA2xx/PXA3xx SUPPORT, Robert Jarzmik,
	Daniel Mack

From: Lee Jones <lee.jones@linaro.org>

This is the only use of kerneldoc in the sourcefile and full
descriptions are not provided.

Fixes the following W=1 kernel build warning(s):

 sound/soc/pxa/pxa-ssp.c:186: warning: Function parameter or member 'ssp' not described in 'pxa_ssp_set_scr'

Cc: Daniel Mack <daniel@zonque.org>
Cc: Haojian Zhuang <haojian.zhuang@gmail.com>
Cc: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
 sound/soc/pxa/pxa-ssp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/pxa/pxa-ssp.c b/sound/soc/pxa/pxa-ssp.c
index 6a72cc1665b7..d1e09ade0190 100644
--- a/sound/soc/pxa/pxa-ssp.c
+++ b/sound/soc/pxa/pxa-ssp.c
@@ -178,7 +178,7 @@ static int pxa_ssp_resume(struct snd_soc_component *component)
 #define pxa_ssp_resume	NULL
 #endif
 
-/**
+/*
  * ssp_set_clkdiv - set SSP clock divider
  * @div: serial clock rate divider
  */
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v3 05/10] ASoC: ux500: ux500_msp_i2s: Remove unused variables 'reg_val_DR' and 'reg_val_TSTDR'
  2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
                   ` (3 preceding siblings ...)
  2020-07-07 19:16 ` [PATCH v3 04/10] ASoC: pxa: pxa-ssp: Demote seemingly unintentional kerneldoc header Pierre-Louis Bossart
@ 2020-07-07 19:16 ` Pierre-Louis Bossart
  2020-07-07 19:16 ` [PATCH v3 06/10] ASoC: sti: uniperif: fix 'defined by not used' warning Pierre-Louis Bossart
                   ` (6 subsequent siblings)
  11 siblings, 0 replies; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-07 19:16 UTC (permalink / raw)
  To: alsa-devel
  Cc: Ola Lilja, tiwai, Lee Jones, Takashi Iwai, Pierre-Louis Bossart,
	Liam Girdwood, Roger Nilsson, broonie, Sandeep Kaushik,
	zhong jiang, open list

From: Lee Jones <lee.jones@linaro.org>

Looks like these have been unchecked since the driver's inception in 2012.

Fixes the following W=1 kernel build warning(s):

 sound/soc/ux500/ux500_msp_i2s.c: In function ‘flush_fifo_rx’:
 sound/soc/ux500/ux500_msp_i2s.c:398:6: warning: variable ‘reg_val_DR’ set but not used [-Wunused-but-set-variable]
 sound/soc/ux500/ux500_msp_i2s.c: In function ‘flush_fifo_tx’:
 sound/soc/ux500/ux500_msp_i2s.c:415:6: warning: variable ‘reg_val_TSTDR’ set but not used [-Wunused-but-set-variable]

Cc: zhong jiang <zhongjiang@huawei.com>
Cc: Ola Lilja <ola.o.lilja@stericsson.com>
Cc: Roger Nilsson <roger.xr.nilsson@stericsson.com>
Cc: Sandeep Kaushik <sandeep.kaushik@st.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
 sound/soc/ux500/ux500_msp_i2s.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/sound/soc/ux500/ux500_msp_i2s.c b/sound/soc/ux500/ux500_msp_i2s.c
index 394d8b2a4a16..fd0b88bb7921 100644
--- a/sound/soc/ux500/ux500_msp_i2s.c
+++ b/sound/soc/ux500/ux500_msp_i2s.c
@@ -395,7 +395,7 @@ static int enable_msp(struct ux500_msp *msp, struct ux500_msp_config *config)
 
 static void flush_fifo_rx(struct ux500_msp *msp)
 {
-	u32 reg_val_DR, reg_val_GCR, reg_val_FLR;
+	u32 reg_val_GCR, reg_val_FLR;
 	u32 limit = 32;
 
 	reg_val_GCR = readl(msp->registers + MSP_GCR);
@@ -403,7 +403,7 @@ static void flush_fifo_rx(struct ux500_msp *msp)
 
 	reg_val_FLR = readl(msp->registers + MSP_FLR);
 	while (!(reg_val_FLR & RX_FIFO_EMPTY) && limit--) {
-		reg_val_DR = readl(msp->registers + MSP_DR);
+		readl(msp->registers + MSP_DR);
 		reg_val_FLR = readl(msp->registers + MSP_FLR);
 	}
 
@@ -412,7 +412,7 @@ static void flush_fifo_rx(struct ux500_msp *msp)
 
 static void flush_fifo_tx(struct ux500_msp *msp)
 {
-	u32 reg_val_TSTDR, reg_val_GCR, reg_val_FLR;
+	u32 reg_val_GCR, reg_val_FLR;
 	u32 limit = 32;
 
 	reg_val_GCR = readl(msp->registers + MSP_GCR);
@@ -421,7 +421,7 @@ static void flush_fifo_tx(struct ux500_msp *msp)
 
 	reg_val_FLR = readl(msp->registers + MSP_FLR);
 	while (!(reg_val_FLR & TX_FIFO_EMPTY) && limit--) {
-		reg_val_TSTDR = readl(msp->registers + MSP_TSTDR);
+		readl(msp->registers + MSP_TSTDR);
 		reg_val_FLR = readl(msp->registers + MSP_FLR);
 	}
 	writel(0x0, msp->registers + MSP_ITCR);
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v3 06/10] ASoC: sti: uniperif: fix 'defined by not used' warning
  2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
                   ` (4 preceding siblings ...)
  2020-07-07 19:16 ` [PATCH v3 05/10] ASoC: ux500: ux500_msp_i2s: Remove unused variables 'reg_val_DR' and 'reg_val_TSTDR' Pierre-Louis Bossart
@ 2020-07-07 19:16 ` Pierre-Louis Bossart
  2020-07-08  9:11   ` Arnaud POULIQUEN
  2020-07-07 19:16 ` [PATCH v3 07/10] ASoC: codecs: rt5631: fix kernel-doc Pierre-Louis Bossart
                   ` (5 subsequent siblings)
  11 siblings, 1 reply; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-07 19:16 UTC (permalink / raw)
  To: alsa-devel
  Cc: tiwai, open list, Takashi Iwai, Arnaud Pouliquen,
	Pierre-Louis Bossart, Liam Girdwood, broonie, Lee Jones

Fix W=1 warning. The table uni_tdm_hw is declared in a header included
by multiple C file. This isn't really a good practice but for now
using __maybe_unused makes the following warning go away.

sound/soc/sti/sti_uniperif.c:12:
sound/soc/sti/uniperif.h:1351:38: warning: ‘uni_tdm_hw’ defined but
not used [-Wunused-const-variable=]
 1351 | static const struct snd_pcm_hardware uni_tdm_hw = {
      |                                      ^~~~~~~~~~

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
 sound/soc/sti/uniperif.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/sti/uniperif.h b/sound/soc/sti/uniperif.h
index 2dc2da5d458b..a16adeb7c1e9 100644
--- a/sound/soc/sti/uniperif.h
+++ b/sound/soc/sti/uniperif.h
@@ -1348,7 +1348,7 @@ struct sti_uniperiph_data {
 	struct sti_uniperiph_dai dai_data;
 };
 
-static const struct snd_pcm_hardware uni_tdm_hw = {
+static __maybe_unused const struct snd_pcm_hardware uni_tdm_hw = {
 	.info = SNDRV_PCM_INFO_INTERLEAVED | SNDRV_PCM_INFO_BLOCK_TRANSFER |
 		SNDRV_PCM_INFO_PAUSE | SNDRV_PCM_INFO_MMAP |
 		SNDRV_PCM_INFO_MMAP_VALID,
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v3 07/10] ASoC: codecs: rt5631: fix kernel-doc
  2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
                   ` (5 preceding siblings ...)
  2020-07-07 19:16 ` [PATCH v3 06/10] ASoC: sti: uniperif: fix 'defined by not used' warning Pierre-Louis Bossart
@ 2020-07-07 19:16 ` Pierre-Louis Bossart
  2020-07-07 19:16 ` [PATCH v3 08/10] ASoC: codecs: rt5659: Remove many unused const variables Pierre-Louis Bossart
                   ` (4 subsequent siblings)
  11 siblings, 0 replies; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-07 19:16 UTC (permalink / raw)
  To: alsa-devel
  Cc: Oder Chiou, tiwai, open list, Takashi Iwai, Pierre-Louis Bossart,
	Liam Girdwood, broonie, Lee Jones

Fix W=1 warning, spurious kernel-doc start and missing arguments

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
 sound/soc/codecs/rt5631.c | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/sound/soc/codecs/rt5631.c b/sound/soc/codecs/rt5631.c
index b5184f0e10e3..653da3eaf355 100644
--- a/sound/soc/codecs/rt5631.c
+++ b/sound/soc/codecs/rt5631.c
@@ -64,7 +64,7 @@ static const struct reg_default rt5631_reg[] = {
 	{ RT5631_PSEUDO_SPATL_CTRL, 0x0553 },
 };
 
-/**
+/*
  * rt5631_write_index - write index register of 2nd layer
  */
 static void rt5631_write_index(struct snd_soc_component *component,
@@ -74,7 +74,7 @@ static void rt5631_write_index(struct snd_soc_component *component,
 	snd_soc_component_write(component, RT5631_INDEX_DATA, value);
 }
 
-/**
+/*
  * rt5631_read_index - read index register of 2nd layer
  */
 static unsigned int rt5631_read_index(struct snd_soc_component *component,
@@ -359,6 +359,7 @@ static int check_adcr_select(struct snd_soc_dapm_widget *source,
 
 /**
  * onebit_depop_power_stage - auto depop in power stage.
+ * @component: ASoC component
  * @enable: power on/off
  *
  * When power on/off headphone, the depop sequence is done by hardware.
@@ -397,6 +398,7 @@ static void onebit_depop_power_stage(struct snd_soc_component *component, int en
 
 /**
  * onebit_depop_mute_stage - auto depop in mute stage.
+ * @component: ASoC component
  * @enable: mute/unmute
  *
  * When mute/unmute headphone, the depop sequence is done by hardware.
@@ -435,6 +437,7 @@ static void onebit_depop_mute_stage(struct snd_soc_component *component, int ena
 
 /**
  * onebit_depop_power_stage - step by step depop sequence in power stage.
+ * @component: ASoC component
  * @enable: power on/off
  *
  * When power on/off headphone, the depop sequence is done in step by step.
@@ -507,6 +510,7 @@ static void depop_seq_power_stage(struct snd_soc_component *component, int enabl
 
 /**
  * depop_seq_mute_stage - step by step depop sequence in mute stage.
+ * @component: ASoC component
  * @enable: mute/unmute
  *
  * When mute/unmute headphone, the depop sequence is done in step by step.
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v3 08/10] ASoC: codecs: rt5659: Remove many unused const variables
  2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
                   ` (6 preceding siblings ...)
  2020-07-07 19:16 ` [PATCH v3 07/10] ASoC: codecs: rt5631: fix kernel-doc Pierre-Louis Bossart
@ 2020-07-07 19:16 ` Pierre-Louis Bossart
  2020-07-07 19:16 ` [PATCH v3 09/10] ASoC: codecs: tlv320aic26: fix kernel-doc warning Pierre-Louis Bossart
                   ` (3 subsequent siblings)
  11 siblings, 0 replies; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-07 19:16 UTC (permalink / raw)
  To: alsa-devel
  Cc: Oder Chiou, tiwai, open list, Takashi Iwai, Pierre-Louis Bossart,
	Liam Girdwood, broonie, Lee Jones

From: Lee Jones <lee.jones@linaro.org>

Looks as though they've never been used.

Fixes the following W=1 kernel build warning(s):

 In file included from  sound/soc/codecs/rt5659.c:25:
 In file included from sound/soc/codecs/rt5659.c:25:
 sound/soc/codecs/rt5659.c:1232:2: warning: ‘rt5659_ad_monor_asrc_enum’ defined but not used [-Wunused-const-variable=]
 1232 | rt5659_ad_monor_asrc_enum, RT5659_ASRC_3, RT5659_AD_MONO_R_T_SFT, 0x7,
 | ^~~~~~~~~~~~~~~~~~~~~~~~~
 include/sound/soc.h:359:24: note: in definition of macro ‘SOC_VALUE_ENUM_DOUBLE_DECL’
 359 | const struct soc_enum name = SOC_VALUE_ENUM_DOUBLE(xreg, xshift_l, xshift_r, xmask, | ^~~~
 sound/soc/codecs/rt5659.c:1231:8: note: in expansion of macro ‘SOC_VALUE_ENUM_SINGLE_DECL’
 1231 | static SOC_VALUE_ENUM_SINGLE_DECL(
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~
 sound/soc/codecs/rt5659.c:1228:2: warning: ‘rt5659_ad_monol_asrc_enum’ defined but not used [-Wunused-const-variable=]
 1228 | rt5659_ad_monol_asrc_enum, RT5659_ASRC_3, RT5659_AD_MONO_L_T_SFT, 0x7,
 | ^~~~~~~~~~~~~~~~~~~~~~~~~
 include/sound/soc.h:359:24: note: in definition of macro ‘SOC_VALUE_ENUM_DOUBLE_DECL’
 359 | const struct soc_enum name = SOC_VALUE_ENUM_DOUBLE(xreg, xshift_l, xshift_r, xmask, | ^~~~
 sound/soc/codecs/rt5659.c:1227:8: note: in expansion of macro ‘SOC_VALUE_ENUM_SINGLE_DECL’
 1227 | static SOC_VALUE_ENUM_SINGLE_DECL(
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~
 sound/soc/codecs/rt5659.c:1224:2: warning: ‘rt5659_ad_sto2_asrc_enum’ defined but not used [-Wunused-const-variable=]
 1224 | rt5659_ad_sto2_asrc_enum, RT5659_ASRC_3, RT5659_AD_STO2_T_SFT, 0x7,
 | ^~~~~~~~~~~~~~~~~~~~~~~~
 include/sound/soc.h:359:24: note: in definition of macro ‘SOC_VALUE_ENUM_DOUBLE_DECL’
 359 | const struct soc_enum name = SOC_VALUE_ENUM_DOUBLE(xreg, xshift_l, xshift_r, xmask, | ^~~~
 sound/soc/codecs/rt5659.c:1223:8: note: in expansion of macro ‘SOC_VALUE_ENUM_SINGLE_DECL’
 1223 | static SOC_VALUE_ENUM_SINGLE_DECL(
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~
 sound/soc/codecs/rt5659.c:1220:2: warning: ‘rt5659_ad_sto1_asrc_enum’ defined but not used [-Wunused-const-variable=]
 1220 | rt5659_ad_sto1_asrc_enum, RT5659_ASRC_2, RT5659_AD_STO1_T_SFT, 0x7,
 | ^~~~~~~~~~~~~~~~~~~~~~~~
 include/sound/soc.h:359:24: note: in definition of macro ‘SOC_VALUE_ENUM_DOUBLE_DECL’
 359 | const struct soc_enum name = SOC_VALUE_ENUM_DOUBLE(xreg, xshift_l, xshift_r, xmask, | ^~~~
 sound/soc/codecs/rt5659.c:1219:8: note: in expansion of macro ‘SOC_VALUE_ENUM_SINGLE_DECL’
 1219 | static SOC_VALUE_ENUM_SINGLE_DECL(
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~
 sound/soc/codecs/rt5659.c:1216:2: warning: ‘rt5659_da_monor_asrc_enum’ defined but not used [-Wunused-const-variable=]
 1216 | rt5659_da_monor_asrc_enum, RT5659_ASRC_2, RT5659_DA_MONO_R_T_SFT, 0x7,
 | ^~~~~~~~~~~~~~~~~~~~~~~~~
 include/sound/soc.h:359:24: note: in definition of macro ‘SOC_VALUE_ENUM_DOUBLE_DECL’
 359 | const struct soc_enum name = SOC_VALUE_ENUM_DOUBLE(xreg, xshift_l, xshift_r, xmask, | ^~~~
 sound/soc/codecs/rt5659.c:1215:8: note: in expansion of macro ‘SOC_VALUE_ENUM_SINGLE_DECL’
 1215 | static SOC_VALUE_ENUM_SINGLE_DECL(
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~
 sound/soc/codecs/rt5659.c:1212:2: warning: ‘rt5659_da_monol_asrc_enum’ defined but not used [-Wunused-const-variable=]
 1212 | rt5659_da_monol_asrc_enum, RT5659_ASRC_2, RT5659_DA_MONO_L_T_SFT, 0x7,
 | ^~~~~~~~~~~~~~~~~~~~~~~~~
 include/sound/soc.h:359:24: note: in definition of macro ‘SOC_VALUE_ENUM_DOUBLE_DECL’
 359 | const struct soc_enum name = SOC_VALUE_ENUM_DOUBLE(xreg, xshift_l, xshift_r, xmask, | ^~~~
 sound/soc/codecs/rt5659.c:1211:8: note: in expansion of macro ‘SOC_VALUE_ENUM_SINGLE_DECL’
 1211 | static SOC_VALUE_ENUM_SINGLE_DECL(
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~
 sound/soc/codecs/rt5659.c:1208:2: warning: ‘rt5659_da_sto_asrc_enum’ defined but not used [-Wunused-const-variable=]
 1208 | rt5659_da_sto_asrc_enum, RT5659_ASRC_2, RT5659_DA_STO_T_SFT, 0x7,
 | ^~~~~~~~~~~~~~~~~~~~~~~
 include/sound/soc.h:359:24: note: in definition of macro ‘SOC_VALUE_ENUM_DOUBLE_DECL’
 359 | const struct soc_enum name = SOC_VALUE_ENUM_DOUBLE(xreg, xshift_l, xshift_r, xmask, | ^~~~
 sound/soc/codecs/rt5659.c:1207:8: note: in expansion of macro ‘SOC_VALUE_ENUM_SINGLE_DECL’
 1207 | static SOC_VALUE_ENUM_SINGLE_DECL(
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~

Cc: Oder Chiou <oder_chiou@realtek.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
 sound/soc/codecs/rt5659.c | 37 -------------------------------------
 1 file changed, 37 deletions(-)

diff --git a/sound/soc/codecs/rt5659.c b/sound/soc/codecs/rt5659.c
index 541fc6f1089b..41e5917b16a5 100644
--- a/sound/soc/codecs/rt5659.c
+++ b/sound/soc/codecs/rt5659.c
@@ -1195,43 +1195,6 @@ static const struct snd_kcontrol_new rt5659_if3_dac_swap_mux =
 static const struct snd_kcontrol_new rt5659_if3_adc_swap_mux =
 	SOC_DAPM_ENUM("IF3 ADC Swap Source", rt5659_if3_adc_enum);
 
-static const char * const rt5659_asrc_clk_src[] = {
-	"clk_sysy_div_out", "clk_i2s1_track", "clk_i2s2_track",
-	"clk_i2s3_track", "clk_sys2", "clk_sys3"
-};
-
-static unsigned int rt5659_asrc_clk_map_values[] = {
-	0, 1, 2, 3, 5, 6,
-};
-
-static SOC_VALUE_ENUM_SINGLE_DECL(
-	rt5659_da_sto_asrc_enum, RT5659_ASRC_2, RT5659_DA_STO_T_SFT, 0x7,
-	rt5659_asrc_clk_src, rt5659_asrc_clk_map_values);
-
-static SOC_VALUE_ENUM_SINGLE_DECL(
-	rt5659_da_monol_asrc_enum, RT5659_ASRC_2, RT5659_DA_MONO_L_T_SFT, 0x7,
-	rt5659_asrc_clk_src, rt5659_asrc_clk_map_values);
-
-static SOC_VALUE_ENUM_SINGLE_DECL(
-	rt5659_da_monor_asrc_enum, RT5659_ASRC_2, RT5659_DA_MONO_R_T_SFT, 0x7,
-	rt5659_asrc_clk_src, rt5659_asrc_clk_map_values);
-
-static SOC_VALUE_ENUM_SINGLE_DECL(
-	rt5659_ad_sto1_asrc_enum, RT5659_ASRC_2, RT5659_AD_STO1_T_SFT, 0x7,
-	rt5659_asrc_clk_src, rt5659_asrc_clk_map_values);
-
-static SOC_VALUE_ENUM_SINGLE_DECL(
-	rt5659_ad_sto2_asrc_enum, RT5659_ASRC_3, RT5659_AD_STO2_T_SFT, 0x7,
-	rt5659_asrc_clk_src, rt5659_asrc_clk_map_values);
-
-static SOC_VALUE_ENUM_SINGLE_DECL(
-	rt5659_ad_monol_asrc_enum, RT5659_ASRC_3, RT5659_AD_MONO_L_T_SFT, 0x7,
-	rt5659_asrc_clk_src, rt5659_asrc_clk_map_values);
-
-static SOC_VALUE_ENUM_SINGLE_DECL(
-	rt5659_ad_monor_asrc_enum, RT5659_ASRC_3, RT5659_AD_MONO_R_T_SFT, 0x7,
-	rt5659_asrc_clk_src, rt5659_asrc_clk_map_values);
-
 static int rt5659_hp_vol_put(struct snd_kcontrol *kcontrol,
 		struct snd_ctl_elem_value *ucontrol)
 {
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v3 09/10] ASoC: codecs: tlv320aic26: fix kernel-doc warning
  2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
                   ` (7 preceding siblings ...)
  2020-07-07 19:16 ` [PATCH v3 08/10] ASoC: codecs: rt5659: Remove many unused const variables Pierre-Louis Bossart
@ 2020-07-07 19:16 ` Pierre-Louis Bossart
  2020-07-07 19:16 ` [PATCH v3 10/10] ASoC: codecs: ak4458: Remove set but never checked variable 'ret' Pierre-Louis Bossart
                   ` (2 subsequent siblings)
  11 siblings, 0 replies; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-07 19:16 UTC (permalink / raw)
  To: alsa-devel
  Cc: Kuninori Morimoto, Liam Girdwood, tiwai, open list, Takashi Iwai,
	Pierre-Louis Bossart, broonie, Lee Jones

Fix W=1 warning. Remove spurious /** since there isn't any kernel-doc
comment in this file.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
 sound/soc/codecs/tlv320aic26.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/codecs/tlv320aic26.c b/sound/soc/codecs/tlv320aic26.c
index 032b39735643..4569bbc08acb 100644
--- a/sound/soc/codecs/tlv320aic26.c
+++ b/sound/soc/codecs/tlv320aic26.c
@@ -131,7 +131,7 @@ static int aic26_hw_params(struct snd_pcm_substream *substream,
 	return 0;
 }
 
-/**
+/*
  * aic26_mute - Mute control to reduce noise when changing audio format
  */
 static int aic26_mute(struct snd_soc_dai *dai, int mute)
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v3 10/10] ASoC: codecs: ak4458: Remove set but never checked variable 'ret'
  2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
                   ` (8 preceding siblings ...)
  2020-07-07 19:16 ` [PATCH v3 09/10] ASoC: codecs: tlv320aic26: fix kernel-doc warning Pierre-Louis Bossart
@ 2020-07-07 19:16 ` Pierre-Louis Bossart
  2020-07-08  6:39 ` [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Lee Jones
  2020-07-10 15:39 ` Mark Brown
  11 siblings, 0 replies; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-07 19:16 UTC (permalink / raw)
  To: alsa-devel
  Cc: Kuninori Morimoto, tiwai, open list, Takashi Iwai,
	Pierre-Louis Bossart, Junichi Wakasugi, Liam Girdwood, broonie,
	Mihai Serban, Lee Jones

From: Lee Jones <lee.jones@linaro.org>

Looks as though the result of snd_soc_update_bits() has never been checked.

Fixes the following W=1 kernel build warning(s):

 sound/soc/codecs/ak4458.c: In function ‘ak4458_set_dai_mute’:
 sound/soc/codecs/ak4458.c:408:16: warning: variable ‘ret’ set but not used [-Wunused-but-set-variable]

Cc: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Cc: Junichi Wakasugi <wakasugi.jb@om.asahi-kasei.co.jp>
Cc: Mihai Serban <mihai.serban@nxp.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
 sound/soc/codecs/ak4458.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/sound/soc/codecs/ak4458.c b/sound/soc/codecs/ak4458.c
index f180cb5dfe4f..39ae089dcd1d 100644
--- a/sound/soc/codecs/ak4458.c
+++ b/sound/soc/codecs/ak4458.c
@@ -405,7 +405,7 @@ static int ak4458_set_dai_mute(struct snd_soc_dai *dai, int mute)
 {
 	struct snd_soc_component *component = dai->component;
 	struct ak4458_priv *ak4458 = snd_soc_component_get_drvdata(component);
-	int nfs, ndt, ret, reg;
+	int nfs, ndt, reg;
 	int ats;
 
 	nfs = ak4458->fs;
@@ -416,14 +416,14 @@ static int ak4458_set_dai_mute(struct snd_soc_dai *dai, int mute)
 	ndt = att_speed[ats] / (nfs / 1000);
 
 	if (mute) {
-		ret = snd_soc_component_update_bits(component, AK4458_01_CONTROL2,  0x01, 1);
+		snd_soc_component_update_bits(component, AK4458_01_CONTROL2,  0x01, 1);
 		mdelay(ndt);
 		if (ak4458->mute_gpiod)
 			gpiod_set_value_cansleep(ak4458->mute_gpiod, 1);
 	} else {
 		if (ak4458->mute_gpiod)
 			gpiod_set_value_cansleep(ak4458->mute_gpiod, 0);
-		ret = snd_soc_component_update_bits(component, AK4458_01_CONTROL2, 0x01, 0);
+		snd_soc_component_update_bits(component, AK4458_01_CONTROL2, 0x01, 0);
 		mdelay(ndt);
 	}
 
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* Re: [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2
  2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
                   ` (9 preceding siblings ...)
  2020-07-07 19:16 ` [PATCH v3 10/10] ASoC: codecs: ak4458: Remove set but never checked variable 'ret' Pierre-Louis Bossart
@ 2020-07-08  6:39 ` Lee Jones
  2020-07-08 12:59   ` Pierre-Louis Bossart
  2020-07-10 15:39 ` Mark Brown
  11 siblings, 1 reply; 23+ messages in thread
From: Lee Jones @ 2020-07-08  6:39 UTC (permalink / raw)
  To: Pierre-Louis Bossart; +Cc: tiwai, alsa-devel, broonie

On Tue, 07 Jul 2020, Pierre-Louis Bossart wrote:

> Both Lee Jones and I submitted separate series, this is the second
> part of the merged result, for which no feedback was provided.
> 
> I picked Lee's patches for rt5659 and ak4458 and added the pxa and
> ux500 that I didn't fix. The rest is largely identical between our
> respective series, with the exception of the sunxi which I documented
> and Lee removed. I don't have any specific preference and will go with
> the flow on this.
> 
> Lee Jones (4):
>   ASoC: pxa: pxa-ssp: Demote seemingly unintentional kerneldoc header
>   ASoC: ux500: ux500_msp_i2s: Remove unused variables 'reg_val_DR' and
>     'reg_val_TSTDR'
>   ASoC: codecs: rt5659: Remove many unused const variables
>   ASoC: codecs: ak4458: Remove set but never checked variable 'ret'
> 
> Pierre-Louis Bossart (6):
>   ASoC: qcom: q6asm: fix kernel-doc
>   ASoC: sunxi: sun4i-i2s: fix kernel-doc
>   ASoC: sunxi: sun4i-spdif: fix kernel-doc
>   ASoC: codecs: rt5631: fix kernel-doc
>   ASoC: codecs: tlv320aic26: fix kernel-doc warning

Would you mind elaborating on "fix kernel-doc".  Some tooling relies
on the fact that subject lines are, at least for the most part, pretty
unique, and if we have to fix another kerneldoc issue in the future
with the same thirst for simpleness, I'm afraid there might be
clashes.

Take a look at my patches, if you require inspiration.

>   ASoC: sti: uniperif: fix 'defined by not used' warning
> 
>  sound/soc/codecs/ak4458.c       |  6 +++---
>  sound/soc/codecs/rt5631.c       |  8 +++++--
>  sound/soc/codecs/rt5659.c       | 37 ---------------------------------
>  sound/soc/codecs/tlv320aic26.c  |  2 +-
>  sound/soc/pxa/pxa-ssp.c         |  2 +-
>  sound/soc/qcom/qdsp6/q6asm.c    |  2 +-
>  sound/soc/sti/uniperif.h        |  2 +-
>  sound/soc/sunxi/sun4i-i2s.c     | 10 ++++++++-
>  sound/soc/sunxi/sun4i-spdif.c   |  2 +-
>  sound/soc/ux500/ux500_msp_i2s.c |  8 +++----
>  10 files changed, 27 insertions(+), 52 deletions(-)
> 

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v3 02/10] ASoC: sunxi: sun4i-i2s: fix kernel-doc
  2020-07-07 19:16 ` [PATCH v3 02/10] ASoC: sunxi: sun4i-i2s: " Pierre-Louis Bossart
@ 2020-07-08  8:11   ` Maxime Ripard
  0 siblings, 0 replies; 23+ messages in thread
From: Maxime Ripard @ 2020-07-08  8:11 UTC (permalink / raw)
  To: Pierre-Louis Bossart
  Cc: alsa-devel, tiwai, open list, Takashi Iwai, Liam Girdwood,
	Marcus Cooper, Chen-Yu Tsai, broonie, Lee Jones,
	moderated list:ARM/Allwinner sunXi SoC support

On Tue, Jul 07, 2020 at 02:16:07PM -0500, Pierre-Louis Bossart wrote:
> Fix W=1 warnings - missing fields in description
> 
> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>

Acked-by: Maxime Ripard <mripard@kernel.org>

Thanks!
Maxime

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v3 03/10] ASoC: sunxi: sun4i-spdif: fix kernel-doc
  2020-07-07 19:16 ` [PATCH v3 03/10] ASoC: sunxi: sun4i-spdif: " Pierre-Louis Bossart
@ 2020-07-08  8:12   ` Maxime Ripard
  0 siblings, 0 replies; 23+ messages in thread
From: Maxime Ripard @ 2020-07-08  8:12 UTC (permalink / raw)
  To: Pierre-Louis Bossart
  Cc: alsa-devel, Rafael J. Wysocki, Kuninori Morimoto, tiwai,
	open list, Masahiro Yamada, Takashi Iwai, Liam Girdwood,
	Bartosz Golaszewski, Chen-Yu Tsai, broonie, Lee Jones,
	moderated list:ARM/Allwinner sunXi SoC support

On Tue, Jul 07, 2020 at 02:16:08PM -0500, Pierre-Louis Bossart wrote:
> Fix W=1 warning - typo in field description
> 
> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>

Acked-by: Maxime Ripard <mripard@kernel.org>

Thanks!
Maxime

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v3 06/10] ASoC: sti: uniperif: fix 'defined by not used' warning
  2020-07-07 19:16 ` [PATCH v3 06/10] ASoC: sti: uniperif: fix 'defined by not used' warning Pierre-Louis Bossart
@ 2020-07-08  9:11   ` Arnaud POULIQUEN
  2020-07-08 12:55     ` Pierre-Louis Bossart
  0 siblings, 1 reply; 23+ messages in thread
From: Arnaud POULIQUEN @ 2020-07-08  9:11 UTC (permalink / raw)
  To: Pierre-Louis Bossart, alsa-devel
  Cc: tiwai, open list, Takashi Iwai, Liam Girdwood, broonie, Lee Jones

Hi Pierre-Louis,

On 7/7/20 9:16 PM, Pierre-Louis Bossart wrote:
> Fix W=1 warning. The table uni_tdm_hw is declared in a header included
> by multiple C file. This isn't really a good practice but for now
> using __maybe_unused makes the following warning go away.
> 
> sound/soc/sti/sti_uniperif.c:12:
> sound/soc/sti/uniperif.h:1351:38: warning: ‘uni_tdm_hw’ defined but
> not used [-Wunused-const-variable=]
>  1351 | static const struct snd_pcm_hardware uni_tdm_hw = {
>       |                                      ^~~~~~~~~~
> 
> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>

Thanks for the patch, 
Seems that the same patch has already been proposed by Lee: 
https://www.spinics.net/lists/arm-kernel/msg820327.html

Regards,
Arnaud

> ---
>  sound/soc/sti/uniperif.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/sound/soc/sti/uniperif.h b/sound/soc/sti/uniperif.h
> index 2dc2da5d458b..a16adeb7c1e9 100644
> --- a/sound/soc/sti/uniperif.h
> +++ b/sound/soc/sti/uniperif.h
> @@ -1348,7 +1348,7 @@ struct sti_uniperiph_data {
>  	struct sti_uniperiph_dai dai_data;
>  };
>  
> -static const struct snd_pcm_hardware uni_tdm_hw = {
> +static __maybe_unused const struct snd_pcm_hardware uni_tdm_hw = {
>  	.info = SNDRV_PCM_INFO_INTERLEAVED | SNDRV_PCM_INFO_BLOCK_TRANSFER |
>  		SNDRV_PCM_INFO_PAUSE | SNDRV_PCM_INFO_MMAP |
>  		SNDRV_PCM_INFO_MMAP_VALID,
> 

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v3 06/10] ASoC: sti: uniperif: fix 'defined by not used' warning
  2020-07-08  9:11   ` Arnaud POULIQUEN
@ 2020-07-08 12:55     ` Pierre-Louis Bossart
  2020-07-08 13:33       ` Arnaud POULIQUEN
  0 siblings, 1 reply; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-08 12:55 UTC (permalink / raw)
  To: Arnaud POULIQUEN, alsa-devel
  Cc: tiwai, Takashi Iwai, Liam Girdwood, open list, broonie, Lee Jones



On 7/8/20 4:11 AM, Arnaud POULIQUEN wrote:
> Hi Pierre-Louis,
> 
> On 7/7/20 9:16 PM, Pierre-Louis Bossart wrote:
>> Fix W=1 warning. The table uni_tdm_hw is declared in a header included
>> by multiple C file. This isn't really a good practice but for now
>> using __maybe_unused makes the following warning go away.
>>
>> sound/soc/sti/sti_uniperif.c:12:
>> sound/soc/sti/uniperif.h:1351:38: warning: ‘uni_tdm_hw’ defined but
>> not used [-Wunused-const-variable=]
>>   1351 | static const struct snd_pcm_hardware uni_tdm_hw = {
>>        |                                      ^~~~~~~~~~
>>
>> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
> 
> Thanks for the patch,
> Seems that the same patch has already been proposed by Lee:
> https://www.spinics.net/lists/arm-kernel/msg820327.html

that's right, we both fixed the same things, and this is the merged series.
Do you mind providing a tag if you're ok with the change?

> Regards,
> Arnaud
> 
>> ---
>>   sound/soc/sti/uniperif.h | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/sound/soc/sti/uniperif.h b/sound/soc/sti/uniperif.h
>> index 2dc2da5d458b..a16adeb7c1e9 100644
>> --- a/sound/soc/sti/uniperif.h
>> +++ b/sound/soc/sti/uniperif.h
>> @@ -1348,7 +1348,7 @@ struct sti_uniperiph_data {
>>   	struct sti_uniperiph_dai dai_data;
>>   };
>>   
>> -static const struct snd_pcm_hardware uni_tdm_hw = {
>> +static __maybe_unused const struct snd_pcm_hardware uni_tdm_hw = {
>>   	.info = SNDRV_PCM_INFO_INTERLEAVED | SNDRV_PCM_INFO_BLOCK_TRANSFER |
>>   		SNDRV_PCM_INFO_PAUSE | SNDRV_PCM_INFO_MMAP |
>>   		SNDRV_PCM_INFO_MMAP_VALID,
>>

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2
  2020-07-08  6:39 ` [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Lee Jones
@ 2020-07-08 12:59   ` Pierre-Louis Bossart
  2020-07-08 13:06     ` Lee Jones
  0 siblings, 1 reply; 23+ messages in thread
From: Pierre-Louis Bossart @ 2020-07-08 12:59 UTC (permalink / raw)
  To: Lee Jones; +Cc: tiwai, alsa-devel, broonie



On 7/8/20 1:39 AM, Lee Jones wrote:
> On Tue, 07 Jul 2020, Pierre-Louis Bossart wrote:
> 
>> Both Lee Jones and I submitted separate series, this is the second
>> part of the merged result, for which no feedback was provided.
>>
>> I picked Lee's patches for rt5659 and ak4458 and added the pxa and
>> ux500 that I didn't fix. The rest is largely identical between our
>> respective series, with the exception of the sunxi which I documented
>> and Lee removed. I don't have any specific preference and will go with
>> the flow on this.
>>
>> Lee Jones (4):
>>    ASoC: pxa: pxa-ssp: Demote seemingly unintentional kerneldoc header
>>    ASoC: ux500: ux500_msp_i2s: Remove unused variables 'reg_val_DR' and
>>      'reg_val_TSTDR'
>>    ASoC: codecs: rt5659: Remove many unused const variables
>>    ASoC: codecs: ak4458: Remove set but never checked variable 'ret'
>>
>> Pierre-Louis Bossart (6):
>>    ASoC: qcom: q6asm: fix kernel-doc
>>    ASoC: sunxi: sun4i-i2s: fix kernel-doc
>>    ASoC: sunxi: sun4i-spdif: fix kernel-doc
>>    ASoC: codecs: rt5631: fix kernel-doc
>>    ASoC: codecs: tlv320aic26: fix kernel-doc warning
> 
> Would you mind elaborating on "fix kernel-doc".  Some tooling relies
> on the fact that subject lines are, at least for the most part, pretty
> unique, and if we have to fix another kerneldoc issue in the future
> with the same thirst for simpleness, I'm afraid there might be
> clashes.

which tools? seems pretty bad to me to rely on string uniqueness, isn't 
uniqueness defined by SHA1s?

> Take a look at my patches, if you require inspiration.

I have a minimalist style for commit subjects but ok, will update them.

>>    ASoC: sti: uniperif: fix 'defined by not used' warning
>>
>>   sound/soc/codecs/ak4458.c       |  6 +++---
>>   sound/soc/codecs/rt5631.c       |  8 +++++--
>>   sound/soc/codecs/rt5659.c       | 37 ---------------------------------
>>   sound/soc/codecs/tlv320aic26.c  |  2 +-
>>   sound/soc/pxa/pxa-ssp.c         |  2 +-
>>   sound/soc/qcom/qdsp6/q6asm.c    |  2 +-
>>   sound/soc/sti/uniperif.h        |  2 +-
>>   sound/soc/sunxi/sun4i-i2s.c     | 10 ++++++++-
>>   sound/soc/sunxi/sun4i-spdif.c   |  2 +-
>>   sound/soc/ux500/ux500_msp_i2s.c |  8 +++----
>>   10 files changed, 27 insertions(+), 52 deletions(-)
>>
> 

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2
  2020-07-08 12:59   ` Pierre-Louis Bossart
@ 2020-07-08 13:06     ` Lee Jones
  2020-07-08 13:38       ` Mark Brown
  0 siblings, 1 reply; 23+ messages in thread
From: Lee Jones @ 2020-07-08 13:06 UTC (permalink / raw)
  To: Pierre-Louis Bossart; +Cc: tiwai, alsa-devel, broonie

On Wed, 08 Jul 2020, Pierre-Louis Bossart wrote:

> 
> 
> On 7/8/20 1:39 AM, Lee Jones wrote:
> > On Tue, 07 Jul 2020, Pierre-Louis Bossart wrote:
> > 
> > > Both Lee Jones and I submitted separate series, this is the second
> > > part of the merged result, for which no feedback was provided.
> > > 
> > > I picked Lee's patches for rt5659 and ak4458 and added the pxa and
> > > ux500 that I didn't fix. The rest is largely identical between our
> > > respective series, with the exception of the sunxi which I documented
> > > and Lee removed. I don't have any specific preference and will go with
> > > the flow on this.
> > > 
> > > Lee Jones (4):
> > >    ASoC: pxa: pxa-ssp: Demote seemingly unintentional kerneldoc header
> > >    ASoC: ux500: ux500_msp_i2s: Remove unused variables 'reg_val_DR' and
> > >      'reg_val_TSTDR'
> > >    ASoC: codecs: rt5659: Remove many unused const variables
> > >    ASoC: codecs: ak4458: Remove set but never checked variable 'ret'
> > > 
> > > Pierre-Louis Bossart (6):
> > >    ASoC: qcom: q6asm: fix kernel-doc
> > >    ASoC: sunxi: sun4i-i2s: fix kernel-doc
> > >    ASoC: sunxi: sun4i-spdif: fix kernel-doc
> > >    ASoC: codecs: rt5631: fix kernel-doc
> > >    ASoC: codecs: tlv320aic26: fix kernel-doc warning
> > 
> > Would you mind elaborating on "fix kernel-doc".  Some tooling relies
> > on the fact that subject lines are, at least for the most part, pretty
> > unique, and if we have to fix another kerneldoc issue in the future
> > with the same thirst for simpleness, I'm afraid there might be
> > clashes.
> 
> which tools? seems pretty bad to me to rely on string uniqueness, isn't
> uniqueness defined by SHA1s?

SHAs don't work across rebases/cherry-picks.

Sometimes subject lines are the most reliable way to 'match'.

> > Take a look at my patches, if you require inspiration.
> 
> I have a minimalist style for commit subjects but ok, will update them.

I'd appreciated it.  Thanks.

> > >    ASoC: sti: uniperif: fix 'defined by not used' warning
> > > 
> > >   sound/soc/codecs/ak4458.c       |  6 +++---
> > >   sound/soc/codecs/rt5631.c       |  8 +++++--
> > >   sound/soc/codecs/rt5659.c       | 37 ---------------------------------
> > >   sound/soc/codecs/tlv320aic26.c  |  2 +-
> > >   sound/soc/pxa/pxa-ssp.c         |  2 +-
> > >   sound/soc/qcom/qdsp6/q6asm.c    |  2 +-
> > >   sound/soc/sti/uniperif.h        |  2 +-
> > >   sound/soc/sunxi/sun4i-i2s.c     | 10 ++++++++-
> > >   sound/soc/sunxi/sun4i-spdif.c   |  2 +-
> > >   sound/soc/ux500/ux500_msp_i2s.c |  8 +++----
> > >   10 files changed, 27 insertions(+), 52 deletions(-)
> > > 
> > 

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v3 06/10] ASoC: sti: uniperif: fix 'defined by not used' warning
  2020-07-08 12:55     ` Pierre-Louis Bossart
@ 2020-07-08 13:33       ` Arnaud POULIQUEN
  0 siblings, 0 replies; 23+ messages in thread
From: Arnaud POULIQUEN @ 2020-07-08 13:33 UTC (permalink / raw)
  To: Pierre-Louis Bossart, alsa-devel
  Cc: tiwai, Takashi Iwai, Liam Girdwood, open list, broonie, Lee Jones

hi

On 7/8/20 2:55 PM, Pierre-Louis Bossart wrote:
> 
> 
> On 7/8/20 4:11 AM, Arnaud POULIQUEN wrote:
>> Hi Pierre-Louis,
>>
>> On 7/7/20 9:16 PM, Pierre-Louis Bossart wrote:
>>> Fix W=1 warning. The table uni_tdm_hw is declared in a header included
>>> by multiple C file. This isn't really a good practice but for now
>>> using __maybe_unused makes the following warning go away.
>>>
>>> sound/soc/sti/sti_uniperif.c:12:
>>> sound/soc/sti/uniperif.h:1351:38: warning: ‘uni_tdm_hw’ defined but
>>> not used [-Wunused-const-variable=]
>>>   1351 | static const struct snd_pcm_hardware uni_tdm_hw = {
>>>        |                                      ^~~~~~~~~~
>>>
>>> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
>>
>> Thanks for the patch,
>> Seems that the same patch has already been proposed by Lee:
>> https://www.spinics.net/lists/arm-kernel/msg820327.html
> 
> that's right, we both fixed the same things, and this is the merged series.
> Do you mind providing a tag if you're ok with the change?

Sure, just need to known which one i should tag... I saw that you are discussing with Lee 
by default i ack both, i let you decide which one will be merged :)

Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com>

> 
>> Regards,
>> Arnaud
>>
>>> ---
>>>   sound/soc/sti/uniperif.h | 2 +-
>>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/sound/soc/sti/uniperif.h b/sound/soc/sti/uniperif.h
>>> index 2dc2da5d458b..a16adeb7c1e9 100644
>>> --- a/sound/soc/sti/uniperif.h
>>> +++ b/sound/soc/sti/uniperif.h
>>> @@ -1348,7 +1348,7 @@ struct sti_uniperiph_data {
>>>   	struct sti_uniperiph_dai dai_data;
>>>   };
>>>   
>>> -static const struct snd_pcm_hardware uni_tdm_hw = {
>>> +static __maybe_unused const struct snd_pcm_hardware uni_tdm_hw = {
>>>   	.info = SNDRV_PCM_INFO_INTERLEAVED | SNDRV_PCM_INFO_BLOCK_TRANSFER |
>>>   		SNDRV_PCM_INFO_PAUSE | SNDRV_PCM_INFO_MMAP |
>>>   		SNDRV_PCM_INFO_MMAP_VALID,
>>>

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2
  2020-07-08 13:06     ` Lee Jones
@ 2020-07-08 13:38       ` Mark Brown
  2020-07-08 13:50         ` Lee Jones
  0 siblings, 1 reply; 23+ messages in thread
From: Mark Brown @ 2020-07-08 13:38 UTC (permalink / raw)
  To: Lee Jones; +Cc: tiwai, alsa-devel, Pierre-Louis Bossart

[-- Attachment #1: Type: text/plain, Size: 671 bytes --]

On Wed, Jul 08, 2020 at 02:06:06PM +0100, Lee Jones wrote:
> On Wed, 08 Jul 2020, Pierre-Louis Bossart wrote:

> > > >    ASoC: sunxi: sun4i-i2s: fix kernel-doc
> > > >    ASoC: sunxi: sun4i-spdif: fix kernel-doc
> > > >    ASoC: codecs: rt5631: fix kernel-doc

> > which tools? seems pretty bad to me to rely on string uniqueness, isn't
> > uniqueness defined by SHA1s?

> SHAs don't work across rebases/cherry-picks.

> Sometimes subject lines are the most reliable way to 'match'.

Note that all these patches have unique subjects due to the prefixes
saying what they're modifying, this is a common pattern for these sorts
of repetitive serieses doing broad cleanups.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2
  2020-07-08 13:38       ` Mark Brown
@ 2020-07-08 13:50         ` Lee Jones
  2020-07-08 14:42           ` Mark Brown
  0 siblings, 1 reply; 23+ messages in thread
From: Lee Jones @ 2020-07-08 13:50 UTC (permalink / raw)
  To: Mark Brown; +Cc: tiwai, alsa-devel, Pierre-Louis Bossart

On Wed, 08 Jul 2020, Mark Brown wrote:

> On Wed, Jul 08, 2020 at 02:06:06PM +0100, Lee Jones wrote:
> > On Wed, 08 Jul 2020, Pierre-Louis Bossart wrote:
> 
> > > > >    ASoC: sunxi: sun4i-i2s: fix kernel-doc
> > > > >    ASoC: sunxi: sun4i-spdif: fix kernel-doc
> > > > >    ASoC: codecs: rt5631: fix kernel-doc
> 
> > > which tools? seems pretty bad to me to rely on string uniqueness, isn't
> > > uniqueness defined by SHA1s?
> 
> > SHAs don't work across rebases/cherry-picks.
> 
> > Sometimes subject lines are the most reliable way to 'match'.
> 
> Note that all these patches have unique subjects due to the prefixes
> saying what they're modifying, this is a common pattern for these sorts
> of repetitive serieses doing broad cleanups.

Yes, they're unique within *this* set.  The fun starts when you
conduct another pass a few months/years down the line and have the
same lack of imagination. :)

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2
  2020-07-08 13:50         ` Lee Jones
@ 2020-07-08 14:42           ` Mark Brown
  0 siblings, 0 replies; 23+ messages in thread
From: Mark Brown @ 2020-07-08 14:42 UTC (permalink / raw)
  To: Lee Jones; +Cc: tiwai, alsa-devel, Pierre-Louis Bossart

[-- Attachment #1: Type: text/plain, Size: 620 bytes --]

On Wed, Jul 08, 2020 at 02:50:16PM +0100, Lee Jones wrote:
> On Wed, 08 Jul 2020, Mark Brown wrote:

> > Note that all these patches have unique subjects due to the prefixes
> > saying what they're modifying, this is a common pattern for these sorts
> > of repetitive serieses doing broad cleanups.

> Yes, they're unique within *this* set.  The fun starts when you
> conduct another pass a few months/years down the line and have the
> same lack of imagination. :)

If you're doing that sort of tracking over any period of time,
especially with this kind of shut up the warnings stuff, you're going to
run into issues.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2
  2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
                   ` (10 preceding siblings ...)
  2020-07-08  6:39 ` [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Lee Jones
@ 2020-07-10 15:39 ` Mark Brown
  11 siblings, 0 replies; 23+ messages in thread
From: Mark Brown @ 2020-07-10 15:39 UTC (permalink / raw)
  To: alsa-devel, Pierre-Louis Bossart; +Cc: tiwai, Lee Jones

On Tue, 7 Jul 2020 14:16:05 -0500, Pierre-Louis Bossart wrote:
> Both Lee Jones and I submitted separate series, this is the second
> part of the merged result, for which no feedback was provided.
> 
> I picked Lee's patches for rt5659 and ak4458 and added the pxa and
> ux500 that I didn't fix. The rest is largely identical between our
> respective series, with the exception of the sunxi which I documented
> and Lee removed. I don't have any specific preference and will go with
> the flow on this.
> 
> [...]

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[01/10] ASoC: qcom: qdsp6: q6asm: Provide documentation for 'codec_profile'
        commit: d4633504213eff9913f722da7320e23eecd48b59
[02/10] ASoC: sunxi: sun4i-i2s: add missing clock and format arguments in kernel-doc
        commit: 643e305e9b2c42800fe73ac0e23bd02ba87fe202
[03/10] ASoC: sunxi: sun4i-spdif: Fix misspelling of 'reg_dac_txdata' in kernel-doc
        commit: c7202a19cf838d2a999e554cffa552bf7f480fde
[04/10] ASoC: pxa: pxa-ssp: Demote seemingly unintentional kerneldoc header
        commit: 701f4727f7bb35e9dca7e2c65f44af0608ef3d6b
[05/10] ASoC: ux500: ux500_msp_i2s: Remove unused variables 'reg_val_DR' and 'reg_val_TSTDR'
        commit: 79b094c9dcd70123f51e4039ea9a29ebbd073edd
[06/10] ASoC: sti: uniperif: fix 'defined by not used' warning
        commit: 97d73032a89d85437d6be354ef1cfde7dd97a24a
[07/10] ASoC: codecs: rt5631: fix spurious kernel-doc start and missing arguments
        commit: 762a3d4313aa44a2158c95fbc6e95ec19b7add4a
[08/10] ASoC: codecs: rt5659: Remove many unused const variables
        commit: e57f0e4d4a836e37c5af7ddf1a2c3e09c7970239
[09/10] ASoC: codecs: tlv320aic26: Demote seemingly unintentional kerneldoc header
        commit: c90a67458ee158ba770d656ec66abca81e23f53a
[10/10] ASoC: codecs: ak4458: Remove set but never checked variable 'ret'
        commit: cc3cceedcb7e92ad0a43e5a4a42e653e9d919109

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

^ permalink raw reply	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2020-07-10 15:40 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-07 19:16 [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Pierre-Louis Bossart
2020-07-07 19:16 ` [PATCH v3 01/10] ASoC: qcom: q6asm: fix kernel-doc Pierre-Louis Bossart
2020-07-07 19:16 ` [PATCH v3 02/10] ASoC: sunxi: sun4i-i2s: " Pierre-Louis Bossart
2020-07-08  8:11   ` Maxime Ripard
2020-07-07 19:16 ` [PATCH v3 03/10] ASoC: sunxi: sun4i-spdif: " Pierre-Louis Bossart
2020-07-08  8:12   ` Maxime Ripard
2020-07-07 19:16 ` [PATCH v3 04/10] ASoC: pxa: pxa-ssp: Demote seemingly unintentional kerneldoc header Pierre-Louis Bossart
2020-07-07 19:16 ` [PATCH v3 05/10] ASoC: ux500: ux500_msp_i2s: Remove unused variables 'reg_val_DR' and 'reg_val_TSTDR' Pierre-Louis Bossart
2020-07-07 19:16 ` [PATCH v3 06/10] ASoC: sti: uniperif: fix 'defined by not used' warning Pierre-Louis Bossart
2020-07-08  9:11   ` Arnaud POULIQUEN
2020-07-08 12:55     ` Pierre-Louis Bossart
2020-07-08 13:33       ` Arnaud POULIQUEN
2020-07-07 19:16 ` [PATCH v3 07/10] ASoC: codecs: rt5631: fix kernel-doc Pierre-Louis Bossart
2020-07-07 19:16 ` [PATCH v3 08/10] ASoC: codecs: rt5659: Remove many unused const variables Pierre-Louis Bossart
2020-07-07 19:16 ` [PATCH v3 09/10] ASoC: codecs: tlv320aic26: fix kernel-doc warning Pierre-Louis Bossart
2020-07-07 19:16 ` [PATCH v3 10/10] ASoC: codecs: ak4458: Remove set but never checked variable 'ret' Pierre-Louis Bossart
2020-07-08  6:39 ` [PATCH v3 00/10] ASoC: Clean-up W=1 build warnings​ - part2 Lee Jones
2020-07-08 12:59   ` Pierre-Louis Bossart
2020-07-08 13:06     ` Lee Jones
2020-07-08 13:38       ` Mark Brown
2020-07-08 13:50         ` Lee Jones
2020-07-08 14:42           ` Mark Brown
2020-07-10 15:39 ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).