^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1) /* SPDX-License-Identifier: GPL-2.0-or-later */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 2) /*
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 3) * S5K6AAFX camera sensor driver header
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 4) *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 5) * Copyright (C) 2011 Samsung Electronics Co., Ltd.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 6) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 7)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 8) #ifndef S5K6AA_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 9) #define S5K6AA_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) #include <media/v4l2-mediabus.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) /**
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) * struct s5k6aa_gpio - data structure describing a GPIO
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) * @gpio: GPIO number
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) * @level: indicates active state of the @gpio
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) struct s5k6aa_gpio {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) int gpio;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) int level;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) /**
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) * struct s5k6aa_platform_data - s5k6aa driver platform data
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) * @set_power: an additional callback to the board code, called
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) * after enabling the regulators and before switching
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) * the sensor off
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) * @mclk_frequency: sensor's master clock frequency in Hz
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) * @gpio_reset: GPIO driving RESET pin
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) * @gpio_stby: GPIO driving STBY pin
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) * @nlanes: maximum number of MIPI-CSI lanes used
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) * @horiz_flip: default horizontal image flip value, non zero to enable
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) * @vert_flip: default vertical image flip value, non zero to enable
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) struct s5k6aa_platform_data {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) int (*set_power)(int enable);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) unsigned long mclk_frequency;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) struct s5k6aa_gpio gpio_reset;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) struct s5k6aa_gpio gpio_stby;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) enum v4l2_mbus_type bus_type;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) u8 nlanes;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) u8 horiz_flip;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) u8 vert_flip;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) #endif /* S5K6AA_H */