#include <linux/unaligned.h>
#include <linux/delay.h>
#include <linux/i2c.h>
#include "ccs.h"
#include "ccs-limits.h"
static u32 float_to_u32_mul_1000000(struct i2c_client *client, u32 phloat)
{ … }
static u32 ireal32_to_u32_mul_1000000(struct i2c_client *client, u32 val)
{ … }
u32 ccs_reg_conv(struct ccs_sensor *sensor, u32 reg, u32 val)
{ … }
static int __ccs_read_addr(struct ccs_sensor *sensor, u32 reg, u32 *val,
bool only8, bool conv)
{ … }
static int __ccs_static_data_read_ro_reg(struct ccs_reg *regs, size_t num_regs,
u32 reg, u32 *val)
{ … }
static int
ccs_static_data_read_ro_reg(struct ccs_sensor *sensor, u32 reg, u32 *val)
{ … }
static int ccs_read_addr_raw(struct ccs_sensor *sensor, u32 reg, u32 *val,
bool force8, bool quirk, bool conv, bool data)
{ … }
int ccs_read_addr(struct ccs_sensor *sensor, u32 reg, u32 *val)
{ … }
int ccs_read_addr_8only(struct ccs_sensor *sensor, u32 reg, u32 *val)
{ … }
int ccs_read_addr_noconv(struct ccs_sensor *sensor, u32 reg, u32 *val)
{ … }
int ccs_write_addr(struct ccs_sensor *sensor, u32 reg, u32 val)
{ … }
#define MAX_WRITE_LEN …
int ccs_write_data_regs(struct ccs_sensor *sensor, struct ccs_reg *regs,
size_t num_regs)
{ … }