diff options
-rw-r--r-- | drivers/net/wireless/wl12xx/spi.h | 9 | ||||
-rw-r--r-- | drivers/net/wireless/wl12xx/wl12xx.h | 2 |
2 files changed, 6 insertions, 5 deletions
diff --git a/drivers/net/wireless/wl12xx/spi.h b/drivers/net/wireless/wl12xx/spi.h index fd3227e904a8..f3f18958657c 100644 --- a/drivers/net/wireless/wl12xx/spi.h +++ b/drivers/net/wireless/wl12xx/spi.h | |||
@@ -94,16 +94,15 @@ void wl12xx_set_partition(struct wl12xx *wl, | |||
94 | 94 | ||
95 | static inline u32 wl12xx_read32(struct wl12xx *wl, int addr) | 95 | static inline u32 wl12xx_read32(struct wl12xx *wl, int addr) |
96 | { | 96 | { |
97 | u32 response; | 97 | wl12xx_spi_read(wl, addr, &wl->buffer_32, sizeof(wl->buffer_32)); |
98 | 98 | ||
99 | wl12xx_spi_read(wl, addr, &response, sizeof(u32)); | 99 | return wl->buffer_32; |
100 | |||
101 | return response; | ||
102 | } | 100 | } |
103 | 101 | ||
104 | static inline void wl12xx_write32(struct wl12xx *wl, int addr, u32 val) | 102 | static inline void wl12xx_write32(struct wl12xx *wl, int addr, u32 val) |
105 | { | 103 | { |
106 | wl12xx_spi_write(wl, addr, &val, sizeof(u32)); | 104 | wl->buffer_32 = val; |
105 | wl12xx_spi_write(wl, addr, &wl->buffer_32, sizeof(wl->buffer_32)); | ||
107 | } | 106 | } |
108 | 107 | ||
109 | #endif /* __WL12XX_SPI_H__ */ | 108 | #endif /* __WL12XX_SPI_H__ */ |
diff --git a/drivers/net/wireless/wl12xx/wl12xx.h b/drivers/net/wireless/wl12xx/wl12xx.h index 48641437414b..f252a1189254 100644 --- a/drivers/net/wireless/wl12xx/wl12xx.h +++ b/drivers/net/wireless/wl12xx/wl12xx.h | |||
@@ -382,6 +382,8 @@ struct wl12xx { | |||
382 | 382 | ||
383 | struct wl12xx_stats stats; | 383 | struct wl12xx_stats stats; |
384 | struct wl12xx_debugfs debugfs; | 384 | struct wl12xx_debugfs debugfs; |
385 | |||
386 | u32 buffer_32; | ||
385 | }; | 387 | }; |
386 | 388 | ||
387 | int wl12xx_plt_start(struct wl12xx *wl); | 389 | int wl12xx_plt_start(struct wl12xx *wl); |