Commit fd9bf7bd authored by Glen Lee's avatar Glen Lee Committed by Greg Kroah-Hartman

staging: wilc1000: remove function pointer spi_trx

This patch removes function pointer spi_trx and call linux_spi_write_read
directly.
Signed-off-by: default avatarGlen Lee <glen.lee@atmel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent b4b87a0b
...@@ -14,7 +14,6 @@ ...@@ -14,7 +14,6 @@
typedef struct { typedef struct {
void *os_context; void *os_context;
int (*spi_trx)(u8 *, u8 *, u32);
int (*spi_max_speed)(void); int (*spi_max_speed)(void);
wilc_debug_func dPrint; wilc_debug_func dPrint;
int crc_off; int crc_off;
...@@ -408,7 +407,7 @@ static int spi_cmd_complete(u8 cmd, u32 adr, u8 *b, u32 sz, u8 clockless) ...@@ -408,7 +407,7 @@ static int spi_cmd_complete(u8 cmd, u32 adr, u8 *b, u32 sz, u8 clockless)
} }
rix = len; rix = len;
if (!g_spi.spi_trx(wb, rb, len2)) { if (!linux_spi_write_read(wb, rb, len2)) {
PRINT_ER("[wilc spi]: Failed cmd write, bus error...\n"); PRINT_ER("[wilc spi]: Failed cmd write, bus error...\n");
result = N_FAIL; result = N_FAIL;
return result; return result;
...@@ -976,7 +975,6 @@ static int wilc_spi_init(wilc_wlan_inp_t *inp, wilc_debug_func func) ...@@ -976,7 +975,6 @@ static int wilc_spi_init(wilc_wlan_inp_t *inp, wilc_debug_func func)
} else { } else {
return 0; return 0;
} }
g_spi.spi_trx = inp->io_func.u.spi.spi_trx;
g_spi.spi_max_speed = inp->io_func.u.spi.spi_max_speed; g_spi.spi_max_speed = inp->io_func.u.spi.spi_max_speed;
/** /**
......
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