From 4dad64ab323e0749edfaf87bc2b0fc0f50ee9e6e Mon Sep 17 00:00:00 2001 From: Jack Pham Date: Tue, 5 Apr 2022 11:16:16 -0700 Subject: [PATCH] ANDROID: sound: usb: Export symbols for endpoint management Export the following symbols which are needed to support USB audio offload to a co-processor. snd_usb_autoresume snd_usb_autosuspend snd_usb_endpoint_open snd_usb_endpoint_close snd_usb_endpoint_configure Bug: 224904393 Change-Id: I8feaa225c7b869592b395815b3a7be47813c7aac Signed-off-by: Jack Pham --- sound/usb/card.c | 2 ++ sound/usb/endpoint.c | 3 +++ 2 files changed, 5 insertions(+) diff --git a/sound/usb/card.c b/sound/usb/card.c index d70cec6eda8f..03c6c9f44875 100644 --- a/sound/usb/card.c +++ b/sound/usb/card.c @@ -1018,6 +1018,7 @@ int snd_usb_autoresume(struct snd_usb_audio *chip) } return 0; } +EXPORT_SYMBOL_GPL(snd_usb_autoresume); void snd_usb_autosuspend(struct snd_usb_audio *chip) { @@ -1031,6 +1032,7 @@ void snd_usb_autosuspend(struct snd_usb_audio *chip) for (i = 0; i < chip->num_interfaces; i++) usb_autopm_put_interface(chip->intf[i]); } +EXPORT_SYMBOL_GPL(snd_usb_autosuspend); static int usb_audio_suspend(struct usb_interface *intf, pm_message_t message) { diff --git a/sound/usb/endpoint.c b/sound/usb/endpoint.c index 527ecf89d9a9..1fbc8697f131 100644 --- a/sound/usb/endpoint.c +++ b/sound/usb/endpoint.c @@ -819,6 +819,7 @@ snd_usb_endpoint_open(struct snd_usb_audio *chip, mutex_unlock(&chip->mutex); return ep; } +EXPORT_SYMBOL_GPL(snd_usb_endpoint_open); /* * snd_usb_endpoint_set_sync: Link data and sync endpoints @@ -902,6 +903,7 @@ void snd_usb_endpoint_close(struct snd_usb_audio *chip, } mutex_unlock(&chip->mutex); } +EXPORT_SYMBOL_GPL(snd_usb_endpoint_close); /* Prepare for suspening EP, called from the main suspend handler */ void snd_usb_endpoint_suspend(struct snd_usb_endpoint *ep) @@ -1405,6 +1407,7 @@ unlock: mutex_unlock(&chip->mutex); return err; } +EXPORT_SYMBOL_GPL(snd_usb_endpoint_configure); /* get the current rate set to the given clock by any endpoint */ int snd_usb_endpoint_get_clock_rate(struct snd_usb_audio *chip, int clock)