diff mbox series

ASoC: SOF: compr: Mark snd_compress_ops static

Message ID 20220211082631.179735-1-daniel.baluta@oss.nxp.com (mailing list archive)
State Accepted
Commit e7c799e76f070b4ac13498e532574466064ad6a5
Headers show
Series ASoC: SOF: compr: Mark snd_compress_ops static | expand

Commit Message

Daniel Baluta (OSS) Feb. 11, 2022, 8:26 a.m. UTC
From: Daniel Baluta <daniel.baluta@nxp.com>

Functions won't be directly used outside of compress.c file
so mark them as static.

This will also fix warnings reported by kernel test robot:

>> sound/soc/sof/compress.c:91:5: warning: no previous prototype for
function 'sof_compr_open' [-Wmissing-prototypes]
   int sof_compr_open(struct snd_soc_component *component,
       ^
   sound/soc/sof/compress.c:91:1: note: declare 'static' if the function
is not intended to be used outside of this translation unit
   int sof_compr_open(struct snd_soc_component *component,

Fixes: 6324cf901e14 ("SoC: SOF: compr: Add compress ops implementation")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
---
 sound/soc/sof/compress.c | 26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

Comments

Mark Brown Feb. 14, 2022, 12:54 p.m. UTC | #1
On Fri, 11 Feb 2022 10:26:31 +0200, Daniel Baluta wrote:
> From: Daniel Baluta <daniel.baluta@nxp.com>
> 
> Functions won't be directly used outside of compress.c file
> so mark them as static.
> 
> This will also fix warnings reported by kernel test robot:
> 
> [...]

Applied to

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

Thanks!

[1/1] ASoC: SOF: compr: Mark snd_compress_ops static
      commit: e7c799e76f070b4ac13498e532574466064ad6a5

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
diff mbox series

Patch

diff --git a/sound/soc/sof/compress.c b/sound/soc/sof/compress.c
index 2137d1d65dd9..2af8d75204e9 100644
--- a/sound/soc/sof/compress.c
+++ b/sound/soc/sof/compress.c
@@ -89,8 +89,8 @@  static int create_page_table(struct snd_soc_component *component,
 					 spcm->stream[dir].page_table.area, size);
 }
 
-int sof_compr_open(struct snd_soc_component *component,
-		   struct snd_compr_stream *cstream)
+static int sof_compr_open(struct snd_soc_component *component,
+			  struct snd_compr_stream *cstream)
 {
 	struct snd_soc_pcm_runtime *rtd = cstream->private_data;
 	struct snd_compr_runtime *crtd = cstream->runtime;
@@ -125,8 +125,8 @@  int sof_compr_open(struct snd_soc_component *component,
 	return 0;
 }
 
-int sof_compr_free(struct snd_soc_component *component,
-		   struct snd_compr_stream *cstream)
+static int sof_compr_free(struct snd_soc_component *component,
+			  struct snd_compr_stream *cstream)
 {
 	struct snd_sof_dev *sdev = snd_soc_component_get_drvdata(component);
 	struct snd_compr_tstamp *tstamp = cstream->runtime->private_data;
@@ -159,8 +159,8 @@  int sof_compr_free(struct snd_soc_component *component,
 	return ret;
 }
 
-int sof_compr_set_params(struct snd_soc_component *component,
-			 struct snd_compr_stream *cstream, struct snd_compr_params *params)
+static int sof_compr_set_params(struct snd_soc_component *component,
+				struct snd_compr_stream *cstream, struct snd_compr_params *params)
 {
 	struct snd_sof_dev *sdev = snd_soc_component_get_drvdata(component);
 	struct snd_soc_pcm_runtime *rtd = cstream->private_data;
@@ -222,8 +222,8 @@  int sof_compr_set_params(struct snd_soc_component *component,
 	return 0;
 }
 
-int sof_compr_get_params(struct snd_soc_component *component,
-			 struct snd_compr_stream *cstream, struct snd_codec *params)
+static int sof_compr_get_params(struct snd_soc_component *component,
+				struct snd_compr_stream *cstream, struct snd_codec *params)
 {
 	/* TODO: we don't query the supported codecs for now, if the
 	 * application asks for an unsupported codec the set_params() will fail.
@@ -231,8 +231,8 @@  int sof_compr_get_params(struct snd_soc_component *component,
 	return 0;
 }
 
-int sof_compr_trigger(struct snd_soc_component *component,
-		      struct snd_compr_stream *cstream, int cmd)
+static int sof_compr_trigger(struct snd_soc_component *component,
+			     struct snd_compr_stream *cstream, int cmd)
 {
 	struct snd_sof_dev *sdev = snd_soc_component_get_drvdata(component);
 	struct snd_soc_pcm_runtime *rtd = cstream->private_data;
@@ -271,9 +271,9 @@  int sof_compr_trigger(struct snd_soc_component *component,
 				  &reply, sizeof(reply));
 }
 
-int sof_compr_copy(struct snd_soc_component *component,
-		   struct snd_compr_stream *cstream,
-		   char __user *buf, size_t count)
+static int sof_compr_copy(struct snd_soc_component *component,
+			  struct snd_compr_stream *cstream,
+			  char __user *buf, size_t count)
 {
 	struct snd_compr_runtime *rtd = cstream->runtime;
 	unsigned int offset, n;