]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
ASoC: SOF: Remove struct sof_ops_table and sof_get_ops() macro
authorPeter Ujfalusi <peter.ujfalusi@linux.intel.com>
Mon, 20 Sep 2021 06:41:56 +0000 (09:41 +0300)
committerMark Brown <broonie@kernel.org>
Mon, 20 Sep 2021 12:38:10 +0000 (13:38 +0100)
sof_get_ops() is not used and the struct sof_ops_table is only used by that
macro.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Reviewed-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20210920064156.4763-1-peter.ujfalusi@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sof/ops.h
sound/soc/sof/sof-priv.h

index b4121e51658599a5ed8e66146998483f389eafcd..d40ce2581d944488941d2f12adcb600c259ba8b0 100644 (file)
@@ -524,21 +524,6 @@ snd_sof_set_mach_params(const struct snd_soc_acpi_mach *mach,
                sof_ops(sdev)->set_mach_params(mach, sdev);
 }
 
-static inline const struct snd_sof_dsp_ops
-*sof_get_ops(const struct sof_dev_desc *d,
-            const struct sof_ops_table mach_ops[], int asize)
-{
-       int i;
-
-       for (i = 0; i < asize; i++) {
-               if (d == mach_ops[i].desc)
-                       return mach_ops[i].ops;
-       }
-
-       /* not found */
-       return NULL;
-}
-
 /**
  * snd_sof_dsp_register_poll_timeout - Periodically poll an address
  * until a condition is met or a timeout occurs
index 9b1bdba15c74039d7b90219e0cfe9c2543ba5b19..6b1dbae3344cf5a46e78fb615a80a883c254c6a7 100644 (file)
@@ -294,12 +294,6 @@ struct dsp_arch_ops {
 
 #define sof_dsp_arch_ops(sdev) ((sdev)->pdata->desc->ops->dsp_arch_ops)
 
-/* DSP device HW descriptor mapping between bus ID and ops */
-struct sof_ops_table {
-       const struct sof_dev_desc *desc;
-       const struct snd_sof_dsp_ops *ops;
-};
-
 /* FS entry for debug files that can expose DSP memories, registers */
 struct snd_sof_dfsentry {
        size_t size;