16 #include <linux/module.h>
23 return spi_write(spi, data, count);
26 static int regmap_spi_gather_write(
void *
context,
27 const void *
reg,
size_t reg_len,
28 const void *
val,
size_t val_len)
34 { .tx_buf =
val, .len = val_len, }, };
37 spi_message_add_tail(&t[0], &
m);
38 spi_message_add_tail(&t[1], &
m);
43 static int regmap_spi_read(
void *
context,
44 const void *
reg,
size_t reg_size,
45 void *
val,
size_t val_size)
53 static struct regmap_bus regmap_spi = {
54 .write = regmap_spi_write,
55 .gather_write = regmap_spi_gather_write,
56 .read = regmap_spi_read,
57 .read_flag_mask = 0x80,
70 const struct regmap_config *
config)
87 const struct regmap_config *
config)