#include <linux/bitops.h>
#include <linux/gpio/driver.h>
#include <linux/kernel.h>
#include <linux/mod_devicetable.h>
#include <linux/module.h>
#include <linux/mutex.h>
#include <linux/seq_file.h>
#include <linux/spi/spi.h>
#include <linux/regmap.h>
#define XRA_GSR …
#define XRA_OCR …
#define XRA_PIR …
#define XRA_GCR …
#define XRA_PUR …
#define XRA_IER …
#define XRA_TSCR …
#define XRA_ISR …
#define XRA_REIR …
#define XRA_FEIR …
#define XRA_IFR …
#define XRA_LAST …
struct xra1403 { … };
static const struct regmap_config xra1403_regmap_cfg = …;
static unsigned int to_reg(unsigned int reg, unsigned int offset)
{ … }
static int xra1403_direction_input(struct gpio_chip *chip, unsigned int offset)
{ … }
static int xra1403_direction_output(struct gpio_chip *chip, unsigned int offset,
int value)
{ … }
static int xra1403_get_direction(struct gpio_chip *chip, unsigned int offset)
{ … }
static int xra1403_get(struct gpio_chip *chip, unsigned int offset)
{ … }
static void xra1403_set(struct gpio_chip *chip, unsigned int offset, int value)
{ … }
#ifdef CONFIG_DEBUG_FS
static void xra1403_dbg_show(struct seq_file *s, struct gpio_chip *chip)
{ … }
#else
#define xra1403_dbg_show …
#endif
static int xra1403_probe(struct spi_device *spi)
{ … }
static const struct spi_device_id xra1403_ids[] = …;
MODULE_DEVICE_TABLE(spi, xra1403_ids);
static const struct of_device_id xra1403_spi_of_match[] = …;
MODULE_DEVICE_TABLE(of, xra1403_spi_of_match);
static struct spi_driver xra1403_driver = …;
module_spi_driver(…) …;
MODULE_AUTHOR(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;