Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4d6efc7a authored by Luis Alves's avatar Luis Alves Committed by Mauro Carvalho Chehab
Browse files

[media] si2168: Fix i2c_add_mux_adapter return value



In case of failure the return value was always 0. Return proper
error code (ENODEV) instead.

Signed-off-by: default avatarLuis Alves <ljalvs@gmail.com>
Signed-off-by: default avatarAntti Palosaari <crope@iki.fi>
Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
parent 43911776
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -640,8 +640,10 @@ static int si2168_probe(struct i2c_client *client,
	/* create mux i2c adapter for tuner */
	s->adapter = i2c_add_mux_adapter(client->adapter, &client->dev, s,
			0, 0, 0, si2168_select, si2168_deselect);
	if (s->adapter == NULL)
	if (s->adapter == NULL) {
		ret = -ENODEV;
		goto err;
	}

	/* create dvb_frontend */
	memcpy(&s->fe.ops, &si2168_ops, sizeof(struct dvb_frontend_ops));