Skip to content

Commit 8aadd77

Browse files
committed
mtd: spi-nor: Uniformize the return value in spi_nor_*_ready()
spi_nor_ready() returns 1 if ready, 0 if not ready and -errno on errors. Do the same in all the spi_nor_*_ready() children. Signed-off-by: Tudor Ambarus <[email protected]> Reviewed-by: Vignesh Raghavendra <[email protected]>
1 parent f80ff13 commit 8aadd77

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/mtd/spi-nor/core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -640,7 +640,7 @@ static int spi_nor_fsr_ready(struct spi_nor *nor)
640640
return -EIO;
641641
}
642642

643-
return nor->bouncebuf[0] & FSR_READY;
643+
return !!(nor->bouncebuf[0] & FSR_READY);
644644
}
645645

646646
/**

0 commit comments

Comments
 (0)