Commit 272876d5 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull spi fixes from Mark Brown:
 "A few more device specific fixes plus one trivial quirk.

  There's a couple of patches for Tegra which avoid some fairly
  spectacular log spam if the hardware breaks in ways which were
  actually seen in production, plus a fix for the i.MX driver to
  propagate errors properly when setting up the hardware.

  We also have a trivial patch marking the sun4i driver as being
  compatible with GPIO chip selects"

* tag 'spi-fix-v6.15-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi:
  spi: spi-imx: Add check for spi_imx_setupxfer()
  spi: tegra210-quad: add rate limiting and simplify timeout error message
  spi: tegra210-quad: use WARN_ON_ONCE instead of WARN_ON for timeouts
  spi: sun4i: add support for GPIO chip select lines
parents b5c6891b 951a04ab
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -1695,9 +1695,12 @@ static int spi_imx_transfer_one(struct spi_controller *controller,
				struct spi_device *spi,
				struct spi_transfer *transfer)
{
	int ret;
	struct spi_imx_data *spi_imx = spi_controller_get_devdata(spi->controller);

	spi_imx_setupxfer(spi, transfer);
	ret = spi_imx_setupxfer(spi, transfer);
	if (ret < 0)
		return ret;
	transfer->effective_speed_hz = spi_imx->spi_bus_clk;

	/* flush rxfifo before transfer */
+1 −0
Original line number Diff line number Diff line
@@ -462,6 +462,7 @@ static int sun4i_spi_probe(struct platform_device *pdev)
	sspi->host = host;
	host->max_speed_hz = 100 * 1000 * 1000;
	host->min_speed_hz = 3 * 1000;
	host->use_gpio_descriptors = true;
	host->set_cs = sun4i_spi_set_cs;
	host->transfer_one = sun4i_spi_transfer_one;
	host->num_chipselect = 4;
+3 −3
Original line number Diff line number Diff line
@@ -1117,9 +1117,9 @@ static int tegra_qspi_combined_seq_xfer(struct tegra_qspi *tqspi,
					(&tqspi->xfer_completion,
					QSPI_DMA_TIMEOUT);

			if (WARN_ON(ret == 0)) {
				dev_err(tqspi->dev, "QSPI Transfer failed with timeout: %d\n",
					ret);
			if (WARN_ON_ONCE(ret == 0)) {
				dev_err_ratelimited(tqspi->dev,
						    "QSPI Transfer failed with timeout\n");
				if (tqspi->is_curr_dma_xfer &&
				    (tqspi->cur_direction & DATA_DIR_TX))
					dmaengine_terminate_all