• Takashi Sakamoto's avatar
    ALSA: dice: limit to current sampling transfer frequency · 0d5ee195
    Takashi Sakamoto authored
    ALSA PCM core has a functionality for rule of PCM substream parameters.
    Typically, when userspace opens PCM character devices, each driver adds
    its own rules to PCM substream according to design of hardware. When the
    userspace executes hw_params ioctl with favorite parameters, the actual
    parameters are calculated according to the rules and the given parameters.
    Then, the result is returned to userspace.
    
    Currently, ALSA Dice driver has the rule between channels and rates, while
    Dice interface design doesn't allow drivers to retrieve all of the
    combinations. Dice drivers are just allowed to get current sampling
    transfer frequency and the number of multi bit linear audio data channels
    in an data block of an AMDTP packet.
    
    This commit purges the rule, and limit PCM substreams to current sampling
    transfer frequency, following to the interface design.
    Signed-off-by: default avatarTakashi Sakamoto <o-takashi@sakamocchi.jp>
    Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
    0d5ee195
dice-pcm.c 7.7 KB