ALSA: hdspm: Fix zero-division
Orabug:
23330988
[ Upstream commit
c1099c3294c2344110085a38c50e478a5992b368 ]
HDSPM driver contains a code issuing zero-division potentially in
system sample rate ctl code. This patch fixes it by not processing
a zero or invalid rate value as a divisor, as well as excluding the
invalid value to be passed via the given ctl element.
Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
(cherry picked from commit
6177e82a6b6586a057e2f00940e2e220b993547e)
Signed-off-by: Dan Duval <dan.duval@oracle.com>