Skip to content

Commit 576b831

Browse files
Meng Dongyangrkhuangtao
authored andcommitted
usb: gadget: uac: correct f_audio_source.c to remove warning
If the CONFIG_USB_CONFIGFS is not define, the 'audio_source_bind_config' may be unused. Corrcet warning of no previous prototype for 'audio_source_bind_config' by adding judgment of CONFIG_USB_CONFIGFS macro definition. Change-Id: I174ae996c1d53e78b76f72cf463bc1efb189675b Signed-off-by: Meng Dongyang <daniel.meng@rock-chips.com>
1 parent cfb692c commit 576b831

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

drivers/usb/gadget/function/f_audio_source.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1215,6 +1215,7 @@ static struct snd_pcm_ops audio_playback_ops = {
12151215
.pointer = audio_pcm_pointer,
12161216
};
12171217

1218+
#ifndef CONFIG_USB_CONFIGFS
12181219
int audio_source_bind_config(struct usb_configuration *c,
12191220
struct audio_source_config *config)
12201221
{
@@ -1253,6 +1254,7 @@ int audio_source_bind_config(struct usb_configuration *c,
12531254
snd_card_free(audio->card);
12541255
return err;
12551256
}
1257+
#endif
12561258

12571259
static int snd_card_setup(struct usb_configuration *c,
12581260
struct audio_source_config *config)

0 commit comments

Comments
 (0)