cachepc-linux

Fork of AMDESE/linux with modifications for CachePC side-channel attack
git clone https://git.sinitax.com/sinitax/cachepc-linux
Log | Files | Refs | README | LICENSE | sfeed.txt

fimc-is-sensor.h (1316B)


      1/* SPDX-License-Identifier: GPL-2.0-only */
      2/*
      3 * Samsung EXYNOS4x12 FIMC-IS (Imaging Subsystem) driver
      4 *
      5 * Copyright (C) 2013 Samsung Electronics Co., Ltd.
      6 *
      7 * Authors:  Sylwester Nawrocki <s.nawrocki@samsung.com>
      8 *	     Younghwan Joo <yhwan.joo@samsung.com>
      9 */
     10#ifndef FIMC_IS_SENSOR_H_
     11#define FIMC_IS_SENSOR_H_
     12
     13#include <linux/of.h>
     14#include <linux/types.h>
     15
     16#define S5K6A3_OPEN_TIMEOUT		2000 /* ms */
     17#define S5K6A3_SENSOR_WIDTH		1392
     18#define S5K6A3_SENSOR_HEIGHT		1392
     19
     20enum fimc_is_sensor_id {
     21	FIMC_IS_SENSOR_ID_S5K3H2 = 1,
     22	FIMC_IS_SENSOR_ID_S5K6A3,
     23	FIMC_IS_SENSOR_ID_S5K4E5,
     24	FIMC_IS_SENSOR_ID_S5K3H7,
     25	FIMC_IS_SENSOR_ID_CUSTOM,
     26	FIMC_IS_SENSOR_ID_END
     27};
     28
     29#define IS_SENSOR_CTRL_BUS_I2C0		0
     30#define IS_SENSOR_CTRL_BUS_I2C1		1
     31
     32struct sensor_drv_data {
     33	enum fimc_is_sensor_id id;
     34	/* sensor open timeout in ms */
     35	unsigned short open_timeout;
     36};
     37
     38/**
     39 * struct fimc_is_sensor - fimc-is sensor data structure
     40 * @drvdata: a pointer to the sensor's parameters data structure
     41 * @i2c_bus: ISP I2C bus index (0...1)
     42 * @test_pattern: true to enable video test pattern
     43 */
     44struct fimc_is_sensor {
     45	const struct sensor_drv_data *drvdata;
     46	unsigned int i2c_bus;
     47	u8 test_pattern;
     48};
     49
     50const struct sensor_drv_data *fimc_is_sensor_get_drvdata(
     51				struct device_node *node);
     52
     53#endif /* FIMC_IS_SENSOR_H_ */