drivers/media/rc/img-ir/img-ir.h

Source file repositories/reference/linux-study-clean/drivers/media/rc/img-ir/img-ir.h

File Facts

System
Linux kernel
Corpus path
drivers/media/rc/img-ir/img-ir.h
Extension
.h
Size
4780 bytes
Lines
170
Domain
Driver Families
Bucket
drivers/media
Inferred role
Driver Families: implementation source
Status
source implementation candidate

Why This File Exists

Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.

Dependency Surface

Detected Declarations

Annotated Snippet

struct img_ir_priv {
	struct device		*dev;
	int			irq;
	struct clk		*clk;
	struct clk		*sys_clk;
	void __iomem		*reg_base;
	spinlock_t		lock;

	struct img_ir_priv_raw	raw;
	struct img_ir_priv_hw	hw;
};

/* Hardware access */

static inline void img_ir_write(struct img_ir_priv *priv,
				unsigned int reg_offs, unsigned int data)
{
	iowrite32(data, priv->reg_base + reg_offs);
}

static inline unsigned int img_ir_read(struct img_ir_priv *priv,
				       unsigned int reg_offs)
{
	return ioread32(priv->reg_base + reg_offs);
}

#endif /* _IMG_IR_H_ */

Annotation

Implementation Notes