Commit d947dddf authored by Dan Carpenter's avatar Dan Carpenter Committed by Greg Kroah-Hartman

staging: pi433: eliminate a temporary variable

We can just get rid of the "spi_address".  It's not clear what the
"address" part of the name means, and the type should have been a u8.
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 5b394b2d
...@@ -853,7 +853,6 @@ int rf69_write_fifo(struct spi_device *spi, u8 *buffer, unsigned int size) ...@@ -853,7 +853,6 @@ int rf69_write_fifo(struct spi_device *spi, u8 *buffer, unsigned int size)
#ifdef DEBUG_FIFO_ACCESS #ifdef DEBUG_FIFO_ACCESS
int i; int i;
#endif #endif
char spi_address = REG_FIFO | WRITE_BIT;
u8 local_buffer[FIFO_SIZE + 1]; u8 local_buffer[FIFO_SIZE + 1];
if (size > FIFO_SIZE) { if (size > FIFO_SIZE) {
...@@ -862,7 +861,7 @@ int rf69_write_fifo(struct spi_device *spi, u8 *buffer, unsigned int size) ...@@ -862,7 +861,7 @@ int rf69_write_fifo(struct spi_device *spi, u8 *buffer, unsigned int size)
return -EMSGSIZE; return -EMSGSIZE;
} }
local_buffer[0] = spi_address; local_buffer[0] = REG_FIFO | WRITE_BIT;
memcpy(&local_buffer[1], buffer, size); memcpy(&local_buffer[1], buffer, size);
#ifdef DEBUG_FIFO_ACCESS #ifdef DEBUG_FIFO_ACCESS
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment