* [PATCH for-next] ASoC: SOF: Make return of remove_late void, too
@ 2023-10-23 15:36 Takashi Iwai
2023-10-23 18:34 ` Mark Brown
0 siblings, 1 reply; 2+ messages in thread
From: Takashi Iwai @ 2023-10-23 15:36 UTC (permalink / raw)
To: alsa-devel; +Cc: Mark Brown, Pierre-Louis Bossart, Peter Ujfalusi
Like the change we've done for remove callback, the newly introduced
remove_late callback should be changed to void return, too.
Fixes: 17baaa1f950b ("ASoC: SOF: core: Add probe_early and remove_late callbacks")
Signed-off-by: Takashi Iwai <tiwai@suse.de>
---
@Mark, as this is based on a merge result, I'm going to apply it to
for-next branch of my sound git tree. Please pull onto yours later.
sound/soc/sof/intel/hda.c | 4 +---
sound/soc/sof/intel/hda.h | 2 +-
sound/soc/sof/ops.h | 6 ++----
sound/soc/sof/sof-priv.h | 2 +-
4 files changed, 5 insertions(+), 9 deletions(-)
diff --git a/sound/soc/sof/intel/hda.c b/sound/soc/sof/intel/hda.c
index 8342fcf52f52..744c0dd5766d 100644
--- a/sound/soc/sof/intel/hda.c
+++ b/sound/soc/sof/intel/hda.c
@@ -1382,13 +1382,11 @@ void hda_dsp_remove(struct snd_sof_dev *sdev)
iounmap(sdev->bar[HDA_DSP_BAR]);
}
-int hda_dsp_remove_late(struct snd_sof_dev *sdev)
+void hda_dsp_remove_late(struct snd_sof_dev *sdev)
{
iounmap(sof_to_bus(sdev)->remap_addr);
sof_hda_bus_exit(sdev);
hda_codec_i915_exit(sdev);
-
- return 0;
}
int hda_power_down_dsp(struct snd_sof_dev *sdev)
diff --git a/sound/soc/sof/intel/hda.h b/sound/soc/sof/intel/hda.h
index f57a9a4b0b75..d628d6a3a7e5 100644
--- a/sound/soc/sof/intel/hda.h
+++ b/sound/soc/sof/intel/hda.h
@@ -579,7 +579,7 @@ struct sof_intel_hda_stream {
int hda_dsp_probe_early(struct snd_sof_dev *sdev);
int hda_dsp_probe(struct snd_sof_dev *sdev);
void hda_dsp_remove(struct snd_sof_dev *sdev);
-int hda_dsp_remove_late(struct snd_sof_dev *sdev);
+void hda_dsp_remove_late(struct snd_sof_dev *sdev);
int hda_dsp_core_power_up(struct snd_sof_dev *sdev, unsigned int core_mask);
int hda_dsp_core_run(struct snd_sof_dev *sdev, unsigned int core_mask);
int hda_dsp_enable_core(struct snd_sof_dev *sdev, unsigned int core_mask);
diff --git a/sound/soc/sof/ops.h b/sound/soc/sof/ops.h
index 09d1452e3705..6538d9f4fe96 100644
--- a/sound/soc/sof/ops.h
+++ b/sound/soc/sof/ops.h
@@ -57,12 +57,10 @@ static inline void snd_sof_remove(struct snd_sof_dev *sdev)
sof_ops(sdev)->remove(sdev);
}
-static inline int snd_sof_remove_late(struct snd_sof_dev *sdev)
+static inline void snd_sof_remove_late(struct snd_sof_dev *sdev)
{
if (sof_ops(sdev)->remove_late)
- return sof_ops(sdev)->remove_late(sdev);
-
- return 0;
+ sof_ops(sdev)->remove_late(sdev);
}
static inline int snd_sof_shutdown(struct snd_sof_dev *sdev)
diff --git a/sound/soc/sof/sof-priv.h b/sound/soc/sof/sof-priv.h
index f712bd39d13d..f4185012eb69 100644
--- a/sound/soc/sof/sof-priv.h
+++ b/sound/soc/sof/sof-priv.h
@@ -168,7 +168,7 @@ struct snd_sof_dsp_ops {
int (*probe_early)(struct snd_sof_dev *sof_dev); /* optional */
int (*probe)(struct snd_sof_dev *sof_dev); /* mandatory */
void (*remove)(struct snd_sof_dev *sof_dev); /* optional */
- int (*remove_late)(struct snd_sof_dev *sof_dev); /* optional */
+ void (*remove_late)(struct snd_sof_dev *sof_dev); /* optional */
int (*shutdown)(struct snd_sof_dev *sof_dev); /* optional */
/* DSP core boot / reset */
base-commit: 41a3056e4e73172d09dad6921e70d0f04b57cdf0
--
2.35.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH for-next] ASoC: SOF: Make return of remove_late void, too
2023-10-23 15:36 [PATCH for-next] ASoC: SOF: Make return of remove_late void, too Takashi Iwai
@ 2023-10-23 18:34 ` Mark Brown
0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2023-10-23 18:34 UTC (permalink / raw)
To: Takashi Iwai; +Cc: alsa-devel, Pierre-Louis Bossart, Peter Ujfalusi
[-- Attachment #1: Type: text/plain, Size: 380 bytes --]
On Mon, Oct 23, 2023 at 05:36:05PM +0200, Takashi Iwai wrote:
> Like the change we've done for remove callback, the newly introduced
> remove_late callback should be changed to void return, too.
>
> Fixes: 17baaa1f950b ("ASoC: SOF: core: Add probe_early and remove_late callbacks")
> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Acked-by: Mark Brown <broonie@kernel.org>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-10-23 18:36 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-10-23 15:36 [PATCH for-next] ASoC: SOF: Make return of remove_late void, too Takashi Iwai
2023-10-23 18:34 ` Mark Brown
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.