Skip to content

Commit 555140a

Browse files
author
Kyle Kearney
committed
Change qspi_inst_t typdef to int
Existing code may a dependency on the old behavior of "-1" to mean "no instruction". Therefore, update the typedef, and the value of QSPI_NO_INST, to avoid breaking those uses.
1 parent 52332f9 commit 555140a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/QSPI.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828

2929
#define ONE_MHZ 1000000
3030

31-
#define QSPI_NO_INST 0x00
31+
#define QSPI_NO_INST (-1)
3232

3333
namespace mbed {
3434
/** \defgroup drivers-public-api-spi SPI
@@ -43,7 +43,7 @@ namespace mbed {
4343

4444
/** Type representing a QSPI instruction
4545
*/
46-
typedef char qspi_inst_t;
46+
typedef int qspi_inst_t;
4747

4848
/** A QSPI Driver, used for communicating with QSPI slave devices
4949
*

0 commit comments

Comments
 (0)