[media] max2165: trival fix for some -Wuninitialized warning
Fix for some -Wuninitialized compiler warnings. Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
This commit is contained in:
Родитель
9fa728ea35
Коммит
32d7e63c1f
|
@ -168,7 +168,7 @@ int fixpt_div32(u32 dividend, u32 divisor, u32 *quotient, u32 *fraction)
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
if (0 == divisor)
|
if (0 == divisor)
|
||||||
return -1;
|
return -EINVAL;
|
||||||
|
|
||||||
q = dividend / divisor;
|
q = dividend / divisor;
|
||||||
remainder = dividend - q * divisor;
|
remainder = dividend - q * divisor;
|
||||||
|
@ -194,10 +194,13 @@ static int max2165_set_rf(struct max2165_priv *priv, u32 freq)
|
||||||
u8 tf_ntch;
|
u8 tf_ntch;
|
||||||
u32 t;
|
u32 t;
|
||||||
u32 quotient, fraction;
|
u32 quotient, fraction;
|
||||||
|
int ret;
|
||||||
|
|
||||||
/* Set PLL divider according to RF frequency */
|
/* Set PLL divider according to RF frequency */
|
||||||
fixpt_div32(freq / 1000, priv->config->osc_clk * 1000,
|
ret = fixpt_div32(freq / 1000, priv->config->osc_clk * 1000,
|
||||||
"ient, &fraction);
|
"ient, &fraction);
|
||||||
|
if (ret != 0)
|
||||||
|
return ret;
|
||||||
|
|
||||||
/* 20-bit fraction */
|
/* 20-bit fraction */
|
||||||
fraction >>= 12;
|
fraction >>= 12;
|
||||||
|
|
Загрузка…
Ссылка в новой задаче