1
0
Fork 0

MLK-10055-2: mfd: si476x-i2c: sound is registered when no FM module attached

The si476x_core_get_revision_info will send i2c command to FM module, if it
return error, there is no FM modules attached, so we need't to register the
sound card. otherwise, the pulseaudio will access this sound card, but return
a lot of i2c error.

Signed-off-by: Shengjiu Wang <shengjiu.wang@freescale.com>
(cherry picked from commit 4c8e9916128f05f9b4115e1ee1af4a1e7d800c4a)
pull/10/head
Shengjiu Wang 2014-12-24 16:51:22 +08:00 committed by Jason Liu
parent ad9afa8889
commit 89b92ae5e6
1 changed files with 6 additions and 7 deletions

View File

@ -811,15 +811,14 @@ static int si476x_core_probe(struct i2c_client *client,
core->power_state = SI476X_POWER_UP_FULL;
si476x_core_set_power_state(core, SI476X_POWER_DOWN);
rval = si476x_core_get_revision_info(core);
if (rval < 0) {
rval = -ENODEV;
goto free_kfifo;
}
if (of_property_read_bool(client->dev.of_node, "revision-a10"))
core->revision = SI476X_REVISION_A10;
else {
rval = si476x_core_get_revision_info(core);
if (rval < 0) {
rval = -ENODEV;
goto free_kfifo;
}
}
cell_num = 0;