diff options
author | Otavio Salvador <otavio@ossystems.com.br> | 2019-03-28 10:47:24 -0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-28 10:47:24 -0300 |
commit | 0a8ab17689e628c84a666195bfc6ab85d11cf057 (patch) | |
tree | 01630dc4a6935df99bf7d11d34ff8d384fed86e2 /include/sound/pcm_params.h | |
parent | 1e71d8c630cbc0d1f5d762fd019690b5cdb880ae (diff) | |
parent | 32aca03c2ce868d3412da0bb6ce6798c7bea357e (diff) |
Merge pull request #46 from toradex/4.9-2.3.x-imx
4.9 2.3.x imx
Diffstat (limited to 'include/sound/pcm_params.h')
-rw-r--r-- | include/sound/pcm_params.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/sound/pcm_params.h b/include/sound/pcm_params.h index c704357775fc..2af7bb3ee57d 100644 --- a/include/sound/pcm_params.h +++ b/include/sound/pcm_params.h @@ -247,11 +247,13 @@ static inline int snd_interval_empty(const struct snd_interval *i) static inline int snd_interval_single(const struct snd_interval *i) { return (i->min == i->max || - (i->min + 1 == i->max && i->openmax)); + (i->min + 1 == i->max && (i->openmin || i->openmax))); } static inline int snd_interval_value(const struct snd_interval *i) { + if (i->openmin && !i->openmax) + return i->max; return i->min; } |