summaryrefslogtreecommitdiffstats
path: root/drivers/spi
Commit message (Collapse)AuthorAgeFilesLines
* spi: Merge up old fixMark Brown2023-09-191-4/+8
|\ | | | | | | | | This fix was originally queued at the end of the 6.4 cycle but as it was minor it never actually got sent.
| * spi: zynqmp-gqspi: fix clock imbalance on probe failureJohan Hovold2023-06-221-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Make sure that the device is not runtime suspended before explicitly disabling the clocks on probe failure and on driver unbind to avoid a clock enable-count imbalance. Fixes: 9e3a000362ae ("spi: zynqmp: Add pm runtime support") Cc: stable@vger.kernel.org # 4.19 Cc: Naga Sureshkumar Relli <naga.sureshkumar.relli@xilinx.com> Cc: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Signed-off-by: Johan Hovold <johan+linaro@kernel.org> Link: https://lore.kernel.org/r/Message-Id: <20230622082435.7873-1-johan+linaro@kernel.org> Signed-off-by: Mark Brown <broonie@kernel.org>
* | spi: imx: Take in account bits per word instead of assuming 8-bitsStefan Moring2023-09-181-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | The IMX spi driver has a hardcoded 8, breaking the driver for word lengths other than 8. Signed-off-by: Stefan Moring <stefanmoring@gmail.com> Reported-by: Sebastian Reichel <sre@kernel.org> Fixes: 15a6af94a277 ("spi: Increase imx51 ecspi burst length based on transfer length") Tested-by: Sebastian Reichel <sre@kernel.org> Link: https://lore.kernel.org/r/20230917164037.29284-1-stefanmoring@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
* | spi: intel-pci: Add support for Granite Rapids SPI serial flashMika Westerberg2023-09-111-0/+1
| | | | | | | | | | | | | | | | | | | | Intel Granite Rapids has a flash controller that is compatible with the other Cannon Lake derivatives. Add Granite Rapids PCI ID to the driver list of supported devices. Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com> Link: https://lore.kernel.org/r/20230911074616.3473347-1-mika.westerberg@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
* | spi: stm32: add a delay before SPI disableValentin Caron2023-09-111-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As explained in errata sheet, in section "2.14.5 Truncation of SPI output signals after EOT event": On STM32MP1x, EOT interrupt can be thrown before the true end of communication. So we add a delay of a half period to wait the real end of the transmission. Link: https://www.st.com/resource/en/errata_sheet/es0539-stm32mp131x3x5x-device-errata-stmicroelectronics.pdf Signed-off-by: Valentin Caron <valentin.caron@foss.st.com> Link: https://lore.kernel.org/r/20230906132735.748174-1-valentin.caron@foss.st.com Signed-off-by: Mark Brown <broonie@kernel.org>
* | spi: nxp-fspi: reset the FLSHxCR1 registersHan Xu2023-09-111-0/+7
| | | | | | | | | | | | | | | | | | Reset the FLSHxCR1 registers to default value. ROM may set the register value and it affects the SPI NAND normal functions. Signed-off-by: Han Xu <han.xu@nxp.com> Link: https://lore.kernel.org/r/20230906183254.235847-1-han.xu@nxp.com Signed-off-by: Mark Brown <broonie@kernel.org>
* | Merge tag 'spi-fix-v6.6-merge-window' of ↵Linus Torvalds2023-09-071-2/+29
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi Pull spi fixes from Mark Brown: "A couple of fixes for the sun6i driver. The patch to reduce DMA RX to single byte width all the time is *hopefully* excessively cautious but it's unclear which SoCs are affected so the fix just covers everything for safety" * tag 'spi-fix-v6.6-merge-window' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi: spi: sun6i: fix race between DMA RX transfer completion and RX FIFO drain spi: sun6i: reduce DMA RX transfer width to single byte
| * | spi: sun6i: fix race between DMA RX transfer completion and RX FIFO drainTobias Schramm2023-09-041-1/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously the transfer complete IRQ immediately drained to RX FIFO to read any data remaining in FIFO to the RX buffer. This behaviour is correct when dealing with SPI in interrupt mode. However in DMA mode the transfer complete interrupt still fires as soon as all bytes to be transferred have been stored in the FIFO. At that point data in the FIFO still needs to be picked up by the DMA engine. Thus the drain procedure and DMA engine end up racing to read from RX FIFO, corrupting any data read. Additionally the RX buffer pointer is never adjusted according to DMA progress in DMA mode, thus calling the RX FIFO drain procedure in DMA mode is a bug. Fix corruptions in DMA RX mode by draining RX FIFO only in interrupt mode. Also wait for completion of RX DMA when in DMA mode before returning to ensure all data has been copied to the supplied memory buffer. Signed-off-by: Tobias Schramm <t.schramm@manjaro.org> Link: https://lore.kernel.org/r/20230827152558.5368-3-t.schramm@manjaro.org Signed-off-by: Mark Brown <broonie@kernel.org>
| * | spi: sun6i: reduce DMA RX transfer width to single byteTobias Schramm2023-09-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Through empirical testing it has been determined that sometimes RX SPI transfers with DMA enabled return corrupted data. This is down to single or even multiple bytes lost during DMA transfer from SPI peripheral to memory. It seems the RX FIFO within the SPI peripheral can become confused when performing bus read accesses wider than a single byte to it during an active SPI transfer. This patch reduces the width of individual DMA read accesses to the RX FIFO to a single byte to mitigate that issue. Signed-off-by: Tobias Schramm <t.schramm@manjaro.org> Link: https://lore.kernel.org/r/20230827152558.5368-2-t.schramm@manjaro.org Signed-off-by: Mark Brown <broonie@kernel.org>
* | | Merge tag 'spi-v6.6' of ↵Linus Torvalds2023-08-29118-2327/+3115
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi Pull spi updates from Mark Brown: "There's been quite a lot of generic activity here, but more administrative than featuers. We also have a bunch of new drivers, including one that's part of a MFD so we pulled in the core parts of that: - Lots of work from both Yang Yingliang and Andy Shevchenko on moving to host/device/controller based terminology for devices. - QuadSPI SPI support for Allwinner sun6i. - New device support Cirrus Logic CS43L43, Longsoon, Qualcomm GENI QuPv3 and StarFive JH7110 QSPI" * tag 'spi-v6.6' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi: (151 commits) spi: at91-usart: Use PTR_ERR_OR_ZERO() to simplify code spi: spi-sn-f-ospi: switch to use modern name spi: sifive: switch to use modern name spi: sh: switch to use modern name spi: sh-sci: switch to use modern name spi: sh-msiof: switch to use modern name spi: sh-hspi: switch to use modern name spi: sc18is602: switch to use modern name spi: s3c64xx: switch to use modern name spi: rzv2m-csi: switch to use devm_spi_alloc_host() spi: rspi: switch to use spi_alloc_host() spi: rockchip: switch to use modern name spi: rockchip-sfc: switch to use modern name spi: realtek-rtl: switch to use devm_spi_alloc_host() spi: rb4xx: switch to use modern name spi: qup: switch to use modern name spi: spi-qcom-qspi: switch to use modern name spi: pxa2xx: switch to use modern name spi: ppc4xx: switch to use modern name spi: spl022: switch to use modern name ...
| * | spi: at91-usart: Use PTR_ERR_OR_ZERO() to simplify codeJinjie Ruan2023-08-221-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Return PTR_ERR_OR_ZERO() instead of return 0 or PTR_ERR() to simplify code. Signed-off-by: Jinjie Ruan <ruanjinjie@huawei.com> Link: https://lore.kernel.org/r/20230822124643.987079-1-ruanjinjie@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| * | spi: switch to use modern name (part4)Mark Brown2023-08-2223-627/+627
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge series from Yang Yingliang <yangyingliang@huawei.com>: I'm trying to rename the legacy name to modern name used in SPI drivers, this is part4 patchset. After introducing devm_spi_alloc_host/spi_alloc_host(), the legacy named function devm_spi_alloc_master/spi_alloc_master() can be replaced. And also change other legacy name master/slave to modern name host/target or controller. Each patch compile test passed.
| | * | spi: spi-sn-f-ospi: switch to use modern nameYang Yingliang2023-08-211-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-24-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: sifive: switch to use modern nameYang Yingliang2023-08-211-40/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-23-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: sh: switch to use modern nameYang Yingliang2023-08-211-17/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Link: https://lore.kernel.org/r/20230818093154.1183529-22-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: sh-sci: switch to use modern nameYang Yingliang2023-08-211-12/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Link: https://lore.kernel.org/r/20230818093154.1183529-21-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: sh-msiof: switch to use modern nameYang Yingliang2023-08-211-25/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master/slave to modern name host/target. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Link: https://lore.kernel.org/r/20230818093154.1183529-20-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: sh-hspi: switch to use modern nameYang Yingliang2023-08-211-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Link: https://lore.kernel.org/r/20230818093154.1183529-19-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: sc18is602: switch to use modern nameYang Yingliang2023-08-211-25/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-18-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: s3c64xx: switch to use modern nameYang Yingliang2023-08-211-63/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master/slave to modern name host/target or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-17-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: rzv2m-csi: switch to use devm_spi_alloc_host()Yang Yingliang2023-08-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Switch to use modern name function devm_spi_alloc_host(). No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Link: https://lore.kernel.org/r/20230818093154.1183529-16-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: rspi: switch to use spi_alloc_host()Yang Yingliang2023-08-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Switch to use modern name function spi_alloc_host(). No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Link: https://lore.kernel.org/r/20230818093154.1183529-15-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: rockchip: switch to use modern nameYang Yingliang2023-08-211-29/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master/slave to modern name host/target or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Acked-by: Heiko Stuebner <heiko@sntech.e> Link: https://lore.kernel.org/r/20230818093154.1183529-14-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: rockchip-sfc: switch to use modern nameYang Yingliang2023-08-211-15/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-13-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: realtek-rtl: switch to use devm_spi_alloc_host()Yang Yingliang2023-08-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Switch to use modern name function devm_spi_alloc_host(). No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-12-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: rb4xx: switch to use modern nameYang Yingliang2023-08-211-18/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-11-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: qup: switch to use modern nameYang Yingliang2023-08-211-83/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-10-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: spi-qcom-qspi: switch to use modern nameYang Yingliang2023-08-211-40/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-9-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: pxa2xx: switch to use modern nameYang Yingliang2023-08-211-12/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master/slave to modern name host/target or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-8-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: ppc4xx: switch to use modern nameYang Yingliang2023-08-211-22/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-7-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: spl022: switch to use modern nameYang Yingliang2023-08-211-47/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-6-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: pic32: switch to use modern nameYang Yingliang2023-08-211-77/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-5-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: pic32-sqi: switch to use modern nameYang Yingliang2023-08-211-43/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-4-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: mchp-pci1xxxx: switch to use modern nameYang Yingliang2023-08-211-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-3-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | spi: orion: switch to use modern nameYang Yingliang2023-08-211-45/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230818093154.1183529-2-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| * | | spi: bcm-qspi: Simplify logic by using devm_platform_ioremap_resource_byname()Zhang Zekun2023-08-211-6/+3
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | platform_get_resource_byname() and devm_ioremap_resource() can be replaced by devm_platform_ioremap_resource_byname(), which can simplify the code logic a bit, No functional change here. Signed-off-by: Zhang Zekun <zhangzekun11@huawei.com> Link: https://lore.kernel.org/r/20230810131650.71916-1-zhangzekun11@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| * | Add cs42l43 PC focused SoundWire CODECMark Brown2023-08-183-0/+292
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | Merge series from Charles Keepax <ckeepax@opensource.cirrus.com>: This patch chain adds support for the Cirrus Logic cs42l43 PC focused SoundWire CODEC.
| | * | spi: cs42l43: Add SPI controller supportLucas Tanure2023-08-183-0/+292
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The CS42L43 is an audio CODEC with integrated MIPI SoundWire interface (Version 1.2.1 compliant), I2C, SPI, and I2S/TDM interfaces designed for portable applications. It provides a high dynamic range, stereo DAC for headphone output, two integrated Class D amplifiers for loudspeakers, and two ADCs for wired headset microphone input or stereo line input. PDM inputs are provided for digital microphones. The SPI component incorporates a SPI controller interface for communication with other peripheral components. Signed-off-by: Lucas Tanure <tanureal@opensource.cirrus.com> Signed-off-by: Maciej Strozek <mstrozek@opensource.cirrus.com> Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20230804104602.395892-6-ckeepax@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
| * | | spi: rpc-if: switch to use devm_spi_alloc_host()Yang Yingliang2023-08-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Switch to use modern name function devm_spi_alloc_host(). No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Link: https://lore.kernel.org/r/20230816094013.1275068-15-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| * | | spi: dw-mmio: keep old name same as documentationYang Yingliang2023-08-161-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The documentation has not use the new name(host/target), so keep the comment words same as documentation used. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230816093938.1274806-1-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| * | | spi: tegra114: Remove unnecessary NULL-pointer checksAlexander Danilenko2023-08-151-11/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | cs_setup, cs_hold and cs_inactive points to fields of spi_device struct, so there is no sense in checking them for NULL. Found by Linux Verification Center (linuxtesting.org) with SVACE. Fixes: 04e6bb0d6bb1 ("spi: modify set_cs_timing parameter") Signed-off-by: Alexander Danilenko <al.b.danilenko@gmail.com> Link: https://lore.kernel.org/r/20230815092058.4083-1-al.b.danilenko@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
| * | | spi: switch to use modern name (part2)Mark Brown2023-08-1420-552/+552
| |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge series from Yang Yingliang <yangyingliang@huawei.com>: I'm trying to rename the legacy name to modern name used in SPI drivers, this is part2 patchset. After introducing devm_spi_alloc_host/spi_alloc_host(), the legacy named function devm_spi_alloc_master/spi_alloc_master() can be replaced. And also change other legacy name master/slave to modern name host/target or controller. All compile test passed. Yang Yingliang (20): spi: amlogic-spifc-a1: switch to use devm_spi_alloc_host() spi: au1550: switch to use modern name spi: ep93xx: switch to use modern name spi: falcon: switch to use modern name spi: fsi: switch to use spi_alloc_host() spi: fsl-dspi: switch to use modern name spi: fsl-espi: switch to use modern name spi: fsl-lpspi: switch to use modern name spi: fsl-qspi: switch to use modern name spi: fsl-spi: switch to use modern name spi: gpio: switch to use modern name spi: gxp: switch to use modern name spi: bcmbca-hsspi: switch to use modern name spi: hisi-sfc-v3xx: switch to use modern name spi: img-spfi: switch to use modern name spi: imx: switch to use modern name spi: ingenic: switch to use devm_spi_alloc_host() spi: intel: switch to use modern name spi: jcore: switch to use modern name spi: lantiq: switch to use modern name drivers/spi/spi-amlogic-spifc-a1.c | 2 +- drivers/spi/spi-au1550.c | 74 ++++++------ drivers/spi/spi-bcmbca-hsspi.c | 66 +++++------ drivers/spi/spi-ep93xx.c | 174 ++++++++++++++--------------- drivers/spi/spi-falcon.c | 34 +++--- drivers/spi/spi-fsi.c | 2 +- drivers/spi/spi-fsl-dspi.c | 24 ++-- drivers/spi/spi-fsl-espi.c | 76 ++++++------- drivers/spi/spi-fsl-lpspi.c | 54 ++++----- drivers/spi/spi-fsl-qspi.c | 10 +- drivers/spi/spi-fsl-spi.c | 76 ++++++------- drivers/spi/spi-gpio.c | 72 ++++++------ drivers/spi/spi-gxp.c | 6 +- drivers/spi/spi-hisi-sfc-v3xx.c | 18 +-- drivers/spi/spi-img-spfi.c | 118 +++++++++---------- drivers/spi/spi-imx.c | 114 +++++++++---------- drivers/spi/spi-ingenic.c | 2 +- drivers/spi/spi-intel.c | 42 +++---- drivers/spi/spi-jcore.c | 44 ++++---- drivers/spi/spi-lantiq-ssc.c | 96 ++++++++-------- 20 files changed, 552 insertions(+), 552 deletions(-) -- 2.25.1
| | * | | spi: lantiq: switch to use modern nameYang Yingliang2023-08-141-48/+48
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master/slave to modern name host/target or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230807124105.3429709-21-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | spi: jcore: switch to use modern nameYang Yingliang2023-08-141-22/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230807124105.3429709-20-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | spi: intel: switch to use modern nameYang Yingliang2023-08-141-21/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230807124105.3429709-19-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | spi: ingenic: switch to use devm_spi_alloc_host()Yang Yingliang2023-08-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Switch to use modern name function devm_spi_alloc_host(). No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230807124105.3429709-18-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | spi: imx: switch to use modern nameYang Yingliang2023-08-141-57/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master/slave to modern name host/target. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230807124105.3429709-17-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | spi: img-spfi: switch to use modern nameYang Yingliang2023-08-141-59/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230807124105.3429709-16-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | spi: hisi-sfc-v3xx: switch to use modern nameYang Yingliang2023-08-141-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230807124105.3429709-15-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
| | * | | spi: bcmbca-hsspi: switch to use modern nameYang Yingliang2023-08-141-33/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change legacy name master to modern name host or controller. No functional changed. Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/r/20230807124105.3429709-14-yangyingliang@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>