1SPI_BUS_LOCK(9) Serial Peripheral Interface (S SPI_BUS_LOCK(9)
2
3
4
6 spi_bus_lock - obtain a lock for exclusive SPI bus usage
7
9 int spi_bus_lock(struct spi_master * master);
10
12 master
13 SPI bus master that should be locked for exclusive bus access
14
16 can sleep
17
19 This call may only be used from a context that may sleep. The sleep is
20 non-interruptible, and has no timeout.
21
22 This call should be used by drivers that require exclusive access to
23 the SPI bus. The SPI bus must be released by a spi_bus_unlock call when
24 the exclusive access is over. Data transfer must be done by
25 spi_sync_locked and spi_async_locked calls when the SPI bus lock is
26 held.
27
28 It returns zero on success, else a negative error code.
29
31Kernel Hackers Manual 3.10 June 2019 SPI_BUS_LOCK(9)