mirror of
https://github.com/brain-hackers/u-boot-brain
synced 2024-09-28 23:50:26 +09:00
spi: dw: Rearrange struct dw_spi_priv
This should reduce the size of the struct, and also groups more similar fields together. Signed-off-by: Sean Anderson <seanga2@gmail.com> Tested-by Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
This commit is contained in:
parent
934beab882
commit
ddd3450f39
@ -95,27 +95,26 @@ struct dw_spi_platdata {
|
|||||||
};
|
};
|
||||||
|
|
||||||
struct dw_spi_priv {
|
struct dw_spi_priv {
|
||||||
void __iomem *regs;
|
|
||||||
unsigned int freq; /* Default frequency */
|
|
||||||
unsigned int mode;
|
|
||||||
struct clk clk;
|
struct clk clk;
|
||||||
unsigned long bus_clk_rate;
|
struct reset_ctl_bulk resets;
|
||||||
|
|
||||||
struct gpio_desc cs_gpio; /* External chip-select gpio */
|
struct gpio_desc cs_gpio; /* External chip-select gpio */
|
||||||
|
|
||||||
int bits_per_word;
|
void __iomem *regs;
|
||||||
u8 cs; /* chip select pin */
|
unsigned long bus_clk_rate;
|
||||||
u8 tmode; /* TR/TO/RO/EEPROM */
|
unsigned int freq; /* Default frequency */
|
||||||
u8 type; /* SPI/SSP/MicroWire */
|
unsigned int mode;
|
||||||
int len;
|
|
||||||
|
|
||||||
u32 fifo_len; /* depth of the FIFO buffer */
|
const void *tx;
|
||||||
void *tx;
|
const void *tx_end;
|
||||||
void *tx_end;
|
|
||||||
void *rx;
|
void *rx;
|
||||||
void *rx_end;
|
void *rx_end;
|
||||||
|
u32 fifo_len; /* depth of the FIFO buffer */
|
||||||
|
|
||||||
struct reset_ctl_bulk resets;
|
int bits_per_word;
|
||||||
|
int len;
|
||||||
|
u8 cs; /* chip select pin */
|
||||||
|
u8 tmode; /* TR/TO/RO/EEPROM */
|
||||||
|
u8 type; /* SPI/SSP/MicroWire */
|
||||||
};
|
};
|
||||||
|
|
||||||
static inline u32 dw_read(struct dw_spi_priv *priv, u32 offset)
|
static inline u32 dw_read(struct dw_spi_priv *priv, u32 offset)
|
||||||
|
Loading…
Reference in New Issue
Block a user