Commit d9424d6d authored by Mark Brown's avatar Mark Brown

Merge branch 'spi-5.2' into spi-5.3

parents 0e896f38 f3440d9a
......@@ -415,7 +415,7 @@ int spi_bitbang_start(struct spi_bitbang *bitbang)
if (ret)
spi_master_put(master);
return 0;
return ret;
}
EXPORT_SYMBOL_GPL(spi_bitbang_start);
......
......@@ -432,7 +432,6 @@ static int fsl_spi_do_one_msg(struct spi_master *master,
}
m->status = status;
spi_finalize_current_message(master);
if (status || !cs_change) {
ndelay(nsecs);
......@@ -440,6 +439,7 @@ static int fsl_spi_do_one_msg(struct spi_master *master,
}
fsl_spi_setup_transfer(spi, NULL);
spi_finalize_current_message(master);
return 0;
}
......
......@@ -1229,10 +1229,10 @@ static int spi_transfer_one_message(struct spi_controller *ctlr,
if (msg->status && ctlr->handle_err)
ctlr->handle_err(ctlr, msg);
spi_finalize_current_message(ctlr);
spi_res_release(ctlr, msg);
spi_finalize_current_message(ctlr);
return ret;
}
......@@ -1355,10 +1355,15 @@ static void __spi_pump_messages(struct spi_controller *ctlr, bool in_kthread)
ret = ctlr->prepare_transfer_hardware(ctlr);
if (ret) {
dev_err(&ctlr->dev,
"failed to prepare transfer hardware\n");
"failed to prepare transfer hardware: %d\n",
ret);
if (ctlr->auto_runtime_pm)
pm_runtime_put(ctlr->dev.parent);
ctlr->cur_msg->status = ret;
spi_finalize_current_message(ctlr);
mutex_unlock(&ctlr->io_mutex);
return;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment