spi/stmicro: fix debug() display of cmd
Subsystems (2)
PATCH 1/1 spi/stmicro: fix debug() display of cmd
The stmicro_wait_ready() func tries to show the actual opcode that was sent to the device, but instead it displays the array pointer. Fix it to pull out the opcode from the start of the array.
Signed-off-by Mike Frysinger <[email protected]>
--- drivers/mtd/spi/stmicro.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/mtd/spi/stmicro.c +1 -1
@@ -137,7 +137,7 @@ static int stmicro_wait_ready(struct spi_flash *flash, unsigned long timeout) ret =spi_xfer (spi,32 , &cmd[0 ],NULL ,SPI_XFER_BEGIN );if (ret) { -debug ("SF: Failed to send command %02x: %d\n" , cmd, ret); +debug ("SF: Failed to send command %02x: %d\n" , cmd[0 ], ret);return ret; }
Signature · 1 line
1.6.0.4
Wolfgang Denk
AppliedPATCH 1/1 spi/stmicro: fix debug() display of cmd
Dear Mike Frysinger,
Quoted 8 lines · In message <[email protected]> you wrote:
The
stmicro_wait_ready()func tries to show the actual opcode that was sent to the device, but instead it displays the array pointer. Fix it to pull out the opcode from the start of the array.Signed-off-by Mike Frysinger <[email protected]>--- drivers/mtd/spi/stmicro.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
Applied, thanks.
Best regards,
Wolfgang Denk
Signature · 4 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de I've got a bad feeling about this.