提交 bd1ed17d 编写于 作者: S Sakari Ailus 提交者: Mauro Carvalho Chehab

media: ccs: Fix return value from probe

rval wasn't set, resulting in probe returning zero instead of an error.

Fixes: de10c161 ("[media] smiapp: Get clock rate if it's not available through DT")
Reported-by: NZhang Changzhong <zhangchangzhong@huawei.com>
Signed-off-by: NSakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: NMauro Carvalho Chehab <mchehab+huawei@kernel.org>
上级 747d2305
...@@ -3030,7 +3030,7 @@ static int ccs_probe(struct i2c_client *client) ...@@ -3030,7 +3030,7 @@ static int ccs_probe(struct i2c_client *client)
dev_err(&client->dev, dev_err(&client->dev,
"can't set clock freq, asked for %u but got %lu\n", "can't set clock freq, asked for %u but got %lu\n",
sensor->hwcfg.ext_clk, rate); sensor->hwcfg.ext_clk, rate);
return rval; return -EINVAL;
} }
} else { } else {
sensor->hwcfg.ext_clk = clk_get_rate(sensor->ext_clk); sensor->hwcfg.ext_clk = clk_get_rate(sensor->ext_clk);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册