.. | .. |
---|
9 | 9 | #define _PHY_ROCKCHIP_CSI2_DPHY_COMMON_H_ |
---|
10 | 10 | |
---|
11 | 11 | #include <linux/rk-camera-module.h> |
---|
| 12 | +#include <linux/rkcif-config.h> |
---|
12 | 13 | |
---|
13 | 14 | #define PHY_MAX 16 |
---|
14 | 15 | #define MAX_DEV_NAME_LEN 32 |
---|
| 16 | + |
---|
| 17 | +#define MAX_SAMSUNG_PHY_NUM 2 |
---|
| 18 | + |
---|
| 19 | +#define MAX_INNO_PHY_NUM 2 |
---|
15 | 20 | |
---|
16 | 21 | /* add new chip id in tail by time order */ |
---|
17 | 22 | enum csi2_dphy_chip_id { |
---|
.. | .. |
---|
59 | 64 | |
---|
60 | 65 | struct dphy_drv_data { |
---|
61 | 66 | const char dev_name[MAX_DEV_NAME_LEN]; |
---|
62 | | - enum csi2_dphy_vendor vendor; |
---|
| 67 | + enum csi2_dphy_chip_id chip_id; |
---|
| 68 | + char num_inno_phy; |
---|
| 69 | + char num_samsung_phy; |
---|
63 | 70 | }; |
---|
64 | 71 | |
---|
65 | 72 | struct csi2_dphy { |
---|
66 | 73 | struct device *dev; |
---|
67 | 74 | struct list_head list; |
---|
68 | 75 | struct csi2_dphy_hw *dphy_hw; |
---|
| 76 | + struct csi2_dphy_hw *dphy_hw_group[MAX_INNO_PHY_NUM]; |
---|
69 | 77 | struct samsung_mipi_dcphy *samsung_phy; |
---|
| 78 | + struct samsung_mipi_dcphy *samsung_phy_group[MAX_SAMSUNG_PHY_NUM]; |
---|
70 | 79 | struct v4l2_async_notifier notifier; |
---|
71 | 80 | struct v4l2_subdev sd; |
---|
72 | 81 | struct mutex mutex; /* lock for updating protection */ |
---|
.. | .. |
---|
75 | 84 | u64 data_rate_mbps; |
---|
76 | 85 | int num_sensors; |
---|
77 | 86 | int phy_index; |
---|
| 87 | + struct rkcif_csi_info csi_info; |
---|
| 88 | + void *phy_hw[RKMODULE_MULTI_DEV_NUM]; |
---|
78 | 89 | bool is_streaming; |
---|
79 | | - enum csi2_dphy_lane_mode lane_mode; |
---|
| 90 | + int lane_mode; |
---|
80 | 91 | const struct dphy_drv_data *drv_data; |
---|
81 | 92 | struct rkmodule_csi_dphy_param dphy_param; |
---|
82 | 93 | }; |
---|