Skip to main content
The Serial Peripheral Interface (SPI) is a synchronous, full-duplex, 4-wire serial bus.

Signals

Transfer Modes by Subsystem

Interface Components

Device Tree Sources

APIs

Software Configuration

Linux Device Tree Example

GPIO pinctrl:

QUPAC Access Control

Configuration Steps

1

Enable kernel configurations

Edit kernel_platform/kernel/arch/arm64/configs/qcom_defconfig:
2

Enable SPI node in device tree

3

Compile and flash

Compile the kernel and device tree changes, then load images to the device.

Verification

1

Transfer spidev_test to device

2

Run test

Expected output:

Debugging

Enable Debug Logs

To disable:

Troubleshooting

  • Verify SPI node status is "okay" in device tree
  • Verify QUPAC_Access.c sets QUPV3_PROTOCOL_SPI, AC_HLOS, bLoad=TRUE
  • Check GPIO drive strength and pull configuration in pinctrl
  • Verify clock phase and polarity match the target device
  • Use oscilloscope to check signal integrity
  • Verify CONFIG_QCOM_GPI_DMA=m is enabled
  • Check dmas and dma-names properties in device tree
  • Verify QUPAC_Access.c sets QUPV3_MODE_GSI and bAllowFifo=FALSE
Verify all CS pins are configured in pinctrl. Check device tree reg property:
Test explicitly:
  • Verify QUP wrapper node status is "okay" and serial engine node is "disabled"
  • Confirm FIFO_MODE = /bits/ 8 <1> (GSI not supported in boot)
  • Check protocol_supported includes SPI_SUPPORTED
  • Verify QUPAC_Access.c settings match boot requirements

Quick Diagnostic Commands

Resources