Re: [RFC 00/xx] ALSA: ALSA: add snd_stream_is_playback/capture()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On Thu, Jul 18, 2024 at 11:34:01PM +0000, Kuninori Morimoto wrote:
> Current many drivers are using below code to know its direction.
> 
> 	if (direction == SNDRV_PCM_STREAM_PLAYBACK)
> 
> I think it should be handled by function. But is it acceptable idea ?
> Because it will be too many patch-set, I want to know it was acceptable
> idea or not before posting patch-bomb.
> 
> I will post main patch, and sample driver patches.

It is better to rename these inline functions introduced in this
patchset so that they belong to PCM category, since in Linux sound
subsystem there is another type of substream in rawmidi category.

The concept of 'substream' corresponds to 'subdevice' in some operations
to PCM/RawMidi cdev, thus should be handled with enough care as much as
possible, in my opinion.


Regards

Takashi Sakamoto



[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux