Skip to content

Commit

Permalink
[ALSA] at73c213: fix error checking for clk API
Browse files Browse the repository at this point in the history
The clk_round_rate() and clk_set_rate() will return int, so not store thier
return value to unsigned long variable.  This bug hides real error on these
API.

Signed-off-by: Atsushi Nemoto <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Takashi Iwai <[email protected]>
  • Loading branch information
atsushi-nemoto authored and tiwai committed Apr 24, 2008
1 parent b419f34 commit c67582b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion sound/spi/at73c213.c
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,8 @@ static struct snd_pcm_hardware snd_at73c213_playback_hw = {
static int snd_at73c213_set_bitrate(struct snd_at73c213 *chip)
{
unsigned long ssc_rate = clk_get_rate(chip->ssc->clk);
unsigned long dac_rate_new, ssc_div, status;
unsigned long dac_rate_new, ssc_div;
int status;
unsigned long ssc_div_max, ssc_div_min;
int max_tries;

Expand Down

0 comments on commit c67582b

Please sign in to comment.