On Fri, May 22, 2020 at 4:48 AM Dan Robertson <dan@xxxxxxxxxxxxxxx> wrote: > > Add basic support for the Bosch Sensortec BMA400 3-axes ultra-low power > accelerometer when configured to use SPI. ... > tristate "Bosch BMA400 3-Axis Accelerometer Driver" > select REGMAP > select BMA400_I2C if I2C > + select BMA400_SPI if I2C This is not right. ... > +#include <linux/module.h> > +#include <linux/spi/spi.h> What's the point of dups (see below)? > +#include <linux/spi/spi.h> > +#include <linux/mod_devicetable.h> > +#include <linux/module.h> > +#include <linux/regmap.h> Keep them ordered? ... > +#define BMA400_SPI_READ_BUFFER_SIZE (BMA400_MAX_SPI_READ + 1) Do wee need separate macro? It seems longer than explicit use. Do we need the original macro either? ... > + /* > + * TODO(dlrobertson): What is a reasonable length to cap > + * this at. > + */ Either drop this or fulfill. There is no way to leave such in the non-staging code. ... > + .read_flag_mask = BIT(7), #include <linux/bits.h> ... > +static struct spi_driver bma400_spi_driver = { > + .driver = { > + .name = "bma400", > + .of_match_table = bma400_of_spi_match, > + }, > + .probe = bma400_spi_probe, > + .remove = bma400_spi_remove, > + .id_table = bma400_spi_ids, > +}; > + This blank line is not needed. > +module_spi_driver(bma400_spi_driver); -- With Best Regards, Andy Shevchenko