Skip to contentSkip to conversation

ASoC: codecs: nau8360: Fix static declarations and endianness

PATCH In review Neo Chang 2 participants 3 messages Sep 3

Subsystems (2)
lore
Share & tools
lore

Neo Chang

author
#0 lore raw

PATCH 1/2 ASoC: codecs: nau8360: Fix static declarations and endianness

Fix warnings reported by the kernel test robot:
1. Make the 'nau8360_dsp_addr' array static to resolve namespace pollution.
2. Change the variable type to '__be16' to fix the incorrect type.

---
 sound/soc/codecs/nau8360-dsp.c | 2 +-
 sound/soc/codecs/nau8360.c     | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
sound/soc/codecs/nau8360-dsp.c +1 -1
index 2d6bc2962229..41afccbea2c0 100644
@@ -20,7 +20,7 @@
 #include "nau8360.h"
 
 #define NAU8360_DSP_IDLE_RETRY 10
-const unsigned short nau8360_dsp_addr[NAU8360_DSP_FW_NUM] = {
+static const unsigned short nau8360_dsp_addr[NAU8360_DSP_FW_NUM] = {
 	NAU8360_RF000_DSP_COMM, NAU8360_RF002_DSP_COMM };
 
 static int nau8360_dsp_chan_kcs_setup(struct snd_soc_component *cp,
sound/soc/codecs/nau8360.c +1 -1
index d7af2dffb749..802806d92fc4 100644
@@ -409,7 +409,7 @@ static int nau8360_peq_coeff_get(struct snd_kcontrol *kcontrol,
 	struct nau8360 *nau8360 = snd_soc_component_get_drvdata(cp);
 	struct soc_bytes_ext *params = (void *)kcontrol->private_value;
 	int i, value, reg, ret = 0;
-	u16 *val = (u16 *)ucontrol->value.bytes.data;
+	__be16 *val = (__be16 *)ucontrol->value.bytes.data;
 
 	/* Use the DAPM lock to prevent race conditions during DAPM power-up
 	 * state transitions, and check component active status to prohibit
Signature · 1 line
2.25.1
author
#1 lore raw

PATCH 2/2 ASoC: codecs: nau8360: Fix kernel-doc issues

Fix various warnings reported by the kernel test robot:
Correct kernel-doc formatting and warnings.

---
 sound/soc/codecs/nau8360-dsp.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
sound/soc/codecs/nau8360-dsp.c +6 -6
index 41afccbea2c0..2e5b61bfc303 100644
@@ -39,7 +39,7 @@ static int nau8360_dsp_chan_kcs_setup(struct snd_soc_component *cp,
 		.cmd_id = _id, \
 	}
 
-/**
+/*
  * Preamble Fragment Masks:
  * FIELD           | BITS   | SHIFT | MASK | DETAILS
  * ----------------|--------|-------|------|---------------------------------
@@ -53,7 +53,7 @@ static int nau8360_dsp_chan_kcs_setup(struct snd_soc_component *cp,
 #define NAU8360_HOST_LEN_LOW_MASK	GENMASK(17, 16)
 #define NAU8360_HOST_PREAMBLE_MASK	GENMASK(15, 0)
 
-/**
+/*
  * Payload Fragment Masks:
  * FIELD           | BITS   | SHIFT | MASK | DETAILS
  * ----------------|--------|-------|------|---------------------------------
@@ -63,7 +63,7 @@ static int nau8360_dsp_chan_kcs_setup(struct snd_soc_component *cp,
 #define NAU8360_HOST_PARAM_SIZE_MASK	GENMASK(31, 16)
 #define NAU8360_HOST_PARAM_OFFSET_MASK	GENMASK(15, 0)
 
-/**
+/*
  * Trailing Fragment Masks:
  * FIELD           | BITS   | SHIFT | MASK | DETAILS
  * ----------------|--------|-------|------|---------------------------------
@@ -76,7 +76,7 @@ static int nau8360_dsp_chan_kcs_setup(struct snd_soc_component *cp,
 #define NAU8360_TRAIL_PAD_MASK		GENMASK(13, 12)
 #define NAU8360_TRAIL_LEN_HIGH_MASK	GENMASK(15, 14)
 
-/**
+/*
  * Reply Preamble Masks:
  * FIELD           | BITS   | SHIFT | MASK | DETAILS
  * ----------------|--------|-------|------|---------------------------------
@@ -364,7 +364,7 @@ static int nau8360_reply_from_dsp(struct snd_soc_component *cp,
 /**
  * nau8360_send_dsp_command - Send command to DSP
  *
- * @component:  component to register
+ * @cp:  component to register
  * @cmd_id:  DSP supported command ID
  * @kcs_setup: KCS setup structure
  * @dsp_addr: DSP address
@@ -454,7 +454,7 @@ static inline int nau8360_send_dsp_broadcast(struct snd_soc_component *cp, int c
 /**
  * nau8360_dsp_kcs_setup - Send KCS setup command to DSP
  *
- * @component:  component to register
+ * @cp:  component to register
  * @offset: address offset relative to KCS start
  * @size: size of data writen to KCS
  * @data: data writen to KCS setup
Signature · 1 line
2.25.1
maintainer
#2 lore raw
In reply to Neo Chang
Quoted 1 line · Neo Chang

ASoC: codecs: nau8360: Fix static declarations and endianness

Applied to

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

Thanks!

[1/2] ASoC: codecs: nau8360: Fix static declarations and endianness

      https://git.kernel.org/broonie/sound/c/3b05666859ba
[2/2] ASoC: codecs: nau8360: Fix kernel-doc issues
      https://git.kernel.org/broonie/sound/c/aa19a6de4a08

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