提交 fc4b3fa7 编写于 作者: H Hans-Frieder Vogt 提交者: Mauro Carvalho Chehab

[media] rtl2832.c: minor cleanup

The current formulation of the bw_params loop uses the counter j as an
index for the first dimension of the bw_params array which is later
incremented by the variable i. It is evaluated correctly only, because j
is initialized to 0 at the beginning of the loop. I think that
explicitly using the index 0 better reflects the intent of the
expression.
Signed-off-by: NHans-Frieder Vogt <hfvogt@gmx.net>
Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
上级 26ff6313
......@@ -589,7 +589,7 @@ static int rtl2832_set_frontend(struct dvb_frontend *fe)
return -EINVAL;
}
for (j = 0; j < sizeof(bw_params[j]); j++) {
for (j = 0; j < sizeof(bw_params[0]); j++) {
ret = rtl2832_wr_regs(priv, 0x1c+j, 1, &bw_params[i][j], 1);
if (ret)
goto err;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册