mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-09-18 22:14:16 +00:00
firmware: turris-mox-rwtm: Initialize completion before mailbox
Initialize the completion before the mailbox channel is requested.
Fixes: 389711b374 ("firmware: Add Turris Mox rWTM firmware driver")
Signed-off-by: Marek Behún <kabel@kernel.org>
Reviewed-by: Andy Shevchenko <andy@kernel.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
This commit is contained in:
parent
8467cfe821
commit
49e24c80d3
1 changed files with 1 additions and 2 deletions
|
|
@ -499,6 +499,7 @@ static int turris_mox_rwtm_probe(struct platform_device *pdev)
|
|||
platform_set_drvdata(pdev, rwtm);
|
||||
|
||||
mutex_init(&rwtm->busy);
|
||||
init_completion(&rwtm->cmd_done);
|
||||
|
||||
rwtm->mbox_client.dev = dev;
|
||||
rwtm->mbox_client.rx_callback = mox_rwtm_rx_callback;
|
||||
|
|
@ -512,8 +513,6 @@ static int turris_mox_rwtm_probe(struct platform_device *pdev)
|
|||
goto remove_files;
|
||||
}
|
||||
|
||||
init_completion(&rwtm->cmd_done);
|
||||
|
||||
ret = mox_get_board_info(rwtm);
|
||||
if (ret < 0)
|
||||
dev_warn(dev, "Cannot read board information: %i\n", ret);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue