Skip to content

Commit cddb050

Browse files
Locus Wei-Han ChenLeo Yu-Chi Liang
authored andcommitted
andes: spi: Fixed the bug that mutex is used without init (torvalds#259)
Fixed the bug that mutex is used without init. Signed-off-by: Locus Wei-Han Chen <[email protected]> Reviewed-on: https://gitea.andestech.com/RD-SW/linux/pulls/259 Reviewed-by: Tim Shih-Ting OuYang <[email protected]> Reviewed-by: Alex Chun-Ju Lin <[email protected]> Co-authored-by: Locus Wei-Han Chen <[email protected]> Co-committed-by: Locus Wei-Han Chen <[email protected]>
1 parent a1f2c9b commit cddb050

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/spi/spi-atcspi200.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -610,6 +610,7 @@ static int atcspi200_spi_probe(struct platform_device *pdev)
610610
num_cs = NSPI_MAX_CS_NUM;
611611
}
612612

613+
mutex_init(&spi->mutex_lock);
613614
/* Define our controller */
614615
controller->bus_num = pdev->id;
615616
controller->mode_bits = SPI_CPOL | SPI_CPHA | SPI_RX_QUAD | SPI_TX_QUAD;

0 commit comments

Comments
 (0)