OSDN Git Service

pcm: recalculate all rules after changing hw_params flags
authorClemens Ladisch <clemens@ladisch.de>
Wed, 21 Sep 2011 06:30:20 +0000 (08:30 +0200)
committerClemens Ladisch <clemens@ladisch.de>
Wed, 21 Sep 2011 06:30:20 +0000 (08:30 +0200)
commit6dab1a91cbbd40d2f52a0c5a1bd961a1db7bb319
tree99f03573b102ed4e832b7c99b8a2b84b32a8a4e2
parent7924500688fdfeac71e5968e5f5875726a8dce14
pcm: recalculate all rules after changing hw_params flags

The rules engine avoids recalculating rules that do not depend on
any changed parameter, but there is no mechanism to record changed
flags.  So when we change a flag, we have to ensure that all rules
depending on that flag are recalculated; the only method to do this
is to force recalculation of all rules.

So far, there have been no kernel drivers with rules depending
on flags, but rules to disable hardware SRCs by setting
SND_PCM_HW_PARAMS_NORESAMPLE are being introduced now.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
src/pcm/pcm.c