提交 231e83fd 编写于 作者: E Enrico Weigelt 提交者: Kalle Valo

rsi: return explicit error values

Explicitly return constants instead of variable (and rely on
it to be explicitly initialized), if the value is supposed
to be fixed anyways. Align it with the rest of the driver,
which does it the same way.
Signed-off-by: NEnrico Weigelt <info@metux.net>
Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
上级 3e3bb695
......@@ -844,11 +844,11 @@ static int rsi_init_sdio_interface(struct rsi_hw *adapter,
struct sdio_func *pfunction)
{
struct rsi_91x_sdiodev *rsi_91x_dev;
int status = -ENOMEM;
int status;
rsi_91x_dev = kzalloc(sizeof(*rsi_91x_dev), GFP_KERNEL);
if (!rsi_91x_dev)
return status;
return -ENOMEM;
adapter->rsi_dev = rsi_91x_dev;
......@@ -890,7 +890,7 @@ static int rsi_init_sdio_interface(struct rsi_hw *adapter,
#ifdef CONFIG_RSI_DEBUGFS
adapter->num_debugfs_entries = MAX_DEBUGFS_ENTRIES;
#endif
return status;
return 0;
fail:
sdio_disable_func(pfunction);
sdio_release_host(pfunction);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册