[alsa-devel] [PATCH v4 22/22] sound/usb: Use Media Controller API to share media resources
Shuah Khan
shuahkh at osg.samsung.com
Wed Mar 2 17:59:43 CET 2016
On 03/01/2016 12:53 PM, Laurent Pinchart wrote:
> Hi Shuah,
>
> Thank you for the patch.
>
snip
>> +struct media_mixer_ctl {
>> + struct media_device *media_dev;
>> + struct media_entity media_entity;
>> + struct media_intf_devnode *intf_devnode;
>> + struct media_link *intf_link;
>> + struct media_pad media_pad[MEDIA_MIXER_PAD_MAX];
>> + struct media_pipeline media_pipe;
>> +};
>> +
>> +int media_device_create(struct snd_usb_audio *chip,
>> + struct usb_interface *iface);
>> +void media_device_delete(struct snd_usb_audio *chip);
>> +int media_stream_init(struct snd_usb_substream *subs, struct snd_pcm *pcm,
>> + int stream);
>> +void media_stream_delete(struct snd_usb_substream *subs);
>> +int media_start_pipeline(struct snd_usb_substream *subs);
>> +void media_stop_pipeline(struct snd_usb_substream *subs);
>
> As this API is sound-specific, would it make sense to call the functions
> media_snd_* or something similar ? The names are very generic now, and could
> clash with core media code.
Thanks. I renamed the interfaces. Please see patch v5
that was sent out a little while ago.
-- Shuah
>
>> +#else
>> +static inline int media_device_create(struct snd_usb_audio *chip,
>> + struct usb_interface *iface)
>> + { return 0; }
>> +static inline void media_device_delete(struct snd_usb_audio *chip) { }
>> +static inline int media_stream_init(struct snd_usb_substream *subs,
>> + struct snd_pcm *pcm, int stream)
>> + { return 0; }
>> +static inline void media_stream_delete(struct snd_usb_substream *subs) { }
>> +static inline int media_start_pipeline(struct snd_usb_substream *subs)
>> + { return 0; }
>> +static inline void media_stop_pipeline(struct snd_usb_substream *subs) { }
>> +#endif
>> +#endif /* __MEDIA_H */
>
--
Shuah Khan
Sr. Linux Kernel Developer
Open Source Innovation Group
Samsung Research America (Silicon Valley)
shuahkh at osg.samsung.com | (970) 217-8978
More information about the Alsa-devel
mailing list