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

Commit 213d9421 authored by Javier Martinez Canillas's avatar Javier Martinez Canillas Committed by Kalle Valo
Browse files

mwifiex: check if mwifiex_sdio_probe_of() fails and return error



The function can fail so the returned value should be checked
and the error propagated to the caller in case of a failure.

Signed-off-by: default avatarJavier Martinez Canillas <javier@osg.samsung.com>
Reviewed-by: default avatarJulian Calaby <julian.calaby@gmail.com>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
parent d3f04ece
Loading
Loading
Loading
Loading
+7 −2
Original line number Original line Diff line number Diff line
@@ -187,8 +187,13 @@ mwifiex_sdio_probe(struct sdio_func *func, const struct sdio_device_id *id)
	}
	}


	/* device tree node parsing and platform specific configuration*/
	/* device tree node parsing and platform specific configuration*/
	if (func->dev.of_node)
	if (func->dev.of_node) {
		mwifiex_sdio_probe_of(&func->dev, card);
		ret = mwifiex_sdio_probe_of(&func->dev, card);
		if (ret) {
			dev_err(&func->dev, "SDIO dt node parse failed\n");
			goto err_disable;
		}
	}


	ret = mwifiex_add_card(card, &add_remove_card_sem, &sdio_ops,
	ret = mwifiex_add_card(card, &add_remove_card_sem, &sdio_ops,
			       MWIFIEX_SDIO);
			       MWIFIEX_SDIO);