Browse Source

[media] mt9m111: Propagate the real error on v4l2_clk_get() failure

v4l2_clk_get() may return different error codes other than -EPROBE_DEFER,
so it is better to return the real error code instead.

Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Fabio Estevam 8 years ago
parent
commit
bddb4b5335
1 changed files with 1 additions and 1 deletions
  1. 1 1
      drivers/media/i2c/mt9m111.c

+ 1 - 1
drivers/media/i2c/mt9m111.c

@@ -945,7 +945,7 @@ static int mt9m111_probe(struct i2c_client *client,
 
 	mt9m111->clk = v4l2_clk_get(&client->dev, "mclk");
 	if (IS_ERR(mt9m111->clk))
-		return -EPROBE_DEFER;
+		return PTR_ERR(mt9m111->clk);
 
 	/* Default HIGHPOWER context */
 	mt9m111->ctx = &context_b;