drivers: spi: Add support for half-duplex (3-wire) SPI

Add support for half-duplex (3-wire) SPI operation using the Raspberry
Pi Pico PIO.  To allow control of the size of the driver, including
half-duplex support is optional, under the control of Kconfig options.

The original PIO source code is also included as a reference.

Corrected 3-wire tx/rx counts.

Enable half-duplex code based on DTS configuration

Replace runtime checks with static BUILD_ASSERT()

Remove too-fussy Kconfig options

Removed PIO source per review request

Signed-off-by: Steve Boylan <stephen.boylan@beechwoods.com>
This commit is contained in:
Steve Boylan 2024-02-29 10:45:08 -05:00 committed by Carles Cufí
commit 5b72665c47
2 changed files with 588 additions and 107 deletions

View file

@ -24,5 +24,12 @@ properties:
description: |
Input pin for Master In Slave Out.
sio-gpios:
type: phandle-array
description: |
Single I/O gpio info
GPIO input/output pin for 3-wire mode.
clocks:
required: true