#include <linux/mod_devicetable.h>
#include <linux/module.h>
#include <linux/regmap.h>
#include <linux/spi/spi.h>
#include "bme680.h"
struct bme680_spi_bus_context { … };
static int bme680_regmap_spi_select_page(
struct bme680_spi_bus_context *ctx, u8 reg)
{ … }
static int bme680_regmap_spi_write(void *context, const void *data,
size_t count)
{ … }
static int bme680_regmap_spi_read(void *context, const void *reg,
size_t reg_size, void *val, size_t val_size)
{ … }
static struct regmap_bus bme680_regmap_bus = …;
static int bme680_spi_probe(struct spi_device *spi)
{ … }
static const struct spi_device_id bme680_spi_id[] = …;
MODULE_DEVICE_TABLE(spi, bme680_spi_id);
static const struct of_device_id bme680_of_spi_match[] = …;
MODULE_DEVICE_TABLE(of, bme680_of_spi_match);
static struct spi_driver bme680_spi_driver = …;
module_spi_driver(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;
MODULE_IMPORT_NS(…);