include/linux/iio/common/st_sensors.h

Source file repositories/reference/linux-study-clean/include/linux/iio/common/st_sensors.h

File Facts

System
Linux kernel
Corpus path
include/linux/iio/common/st_sensors.h
Extension
.h
Size
9672 bytes
Lines
339
Domain
Core OS
Bucket
Core Kernel Interface
Inferred role
Core OS: implementation source
Status
source implementation candidate

Why This File Exists

Core operating-system implementation surface: boot, tasks, memory, VFS, syscall-facing interfaces, synchronization, credentials, and isolation.

Dependency Surface

Detected Declarations

Annotated Snippet

struct st_sensor_odr_avl {
	unsigned int hz;
	u8 value;
};

struct st_sensor_odr {
	u8 addr;
	u8 mask;
	struct st_sensor_odr_avl odr_avl[ST_SENSORS_ODR_LIST_MAX];
};

struct st_sensor_power {
	u8 addr;
	u8 mask;
	u8 value_off;
	u8 value_on;
};

struct st_sensor_axis {
	u8 addr;
	u8 mask;
};

struct st_sensor_fullscale_avl {
	unsigned int num;
	u8 value;
	unsigned int gain;
	unsigned int gain2;
};

struct st_sensor_fullscale {
	u8 addr;
	u8 mask;
	struct st_sensor_fullscale_avl fs_avl[ST_SENSORS_FULLSCALE_AVL_MAX];
};

struct st_sensor_sim {
	u8 addr;
	u8 value;
};

/**
 * struct st_sensor_bdu - ST sensor device block data update
 * @addr: address of the register.
 * @mask: mask to write the block data update flag.
 */
struct st_sensor_bdu {
	u8 addr;
	u8 mask;
};

/**
 * struct st_sensor_das - ST sensor device data alignment selection
 * @addr: address of the register.
 * @mask: mask to write the das flag for left alignment.
 */
struct st_sensor_das {
	u8 addr;
	u8 mask;
};

/**
 * struct st_sensor_int_drdy - ST sensor device drdy line parameters
 * @addr: address of INT drdy register.
 * @mask: mask to enable drdy line.
 * @addr_od: address to enable/disable Open Drain on the INT line.
 * @mask_od: mask to enable/disable Open Drain on the INT line.
 */
struct st_sensor_int_drdy {
	u8 addr;
	u8 mask;
	u8 addr_od;
	u8 mask_od;
};

/**
 * struct st_sensor_data_ready_irq - ST sensor device data-ready interrupt
 * @int1: data-ready configuration register for INT1 pin.
 * @int2: data-ready configuration register for INT2 pin.
 * @addr_ihl: address to enable/disable active low on the INT lines.
 * @mask_ihl: mask to enable/disable active low on the INT lines.
 * @stat_drdy: status register of DRDY (data ready) interrupt.
 * @ig1: represents the Interrupt Generator 1 of sensors.
 * @en_addr: address of the enable ig1 register.
 * @en_mask: mask to write the on/off value for enable.
 */
struct st_sensor_data_ready_irq {
	struct st_sensor_int_drdy int1;
	struct st_sensor_int_drdy int2;
	u8 addr_ihl;

Annotation

Implementation Notes