[PATCH v6 0/3] staging: iio: adc: ad7816: Fix SPI read race condition and DMA safety

Abdelnasser Hussein posted 3 patches 1 week, 5 days ago
drivers/staging/iio/adc/ad7816.c | 27 ++++++++++++++++++---------
1 file changed, 18 insertions(+), 9 deletions(-)
[PATCH v6 0/3] staging: iio: adc: ad7816: Fix SPI read race condition and DMA safety
Posted by Abdelnasser Hussein 1 week, 5 days ago
This series addresses two separate issues in the ad7816 driver:
1. A race condition during SPI reads where multiple threads could
   disrupt the GPIO state.
2. A DMA safety issue caused by using a stack-allocated buffer for
   SPI transfers.

Changes in v6:
- Separated the alphabetical sorting of include headers into a dedicated
  precursor patch (Patch 1).
- Kept the mutex addition strictly focused on serializing the read
  operations without modifying the sizeof() argument (Patch 2).
- Moved the sizeof() argument fix to the DMA-safe buffer patch where
  it logically belongs (Patch 3).

Changes in v5:
- Split the changes into separate patches for bisectability.
- Replaced stack buffer with a dedicated rx_buf aligned with
  IIO_DMA_MINALIGN.
Abdelnasser Hussein (3):
  staging: iio: adc: ad7816: Sort headers alphabetically
  staging: iio: adc: ad7816: Serialize SPI read operations
  staging: iio: adc: ad7816: Use DMA-safe buffer for SPI read

 drivers/staging/iio/adc/ad7816.c | 27 ++++++++++++++++++---------
 1 file changed, 18 insertions(+), 9 deletions(-)

-- 
2.54.0