.. | .. |
---|
8 | 8 | #define _UAPI_RKMODULE_CAMERA_H |
---|
9 | 9 | |
---|
10 | 10 | #include <linux/types.h> |
---|
| 11 | +#include <linux/rk-video-format.h> |
---|
11 | 12 | |
---|
12 | 13 | #define RKMODULE_API_VERSION KERNEL_VERSION(0, 1, 0x2) |
---|
13 | 14 | |
---|
14 | 15 | /* using for rk3588 dual isp unite */ |
---|
15 | | -#define RKMOUDLE_UNITE_EXTEND_PIXEL 32 |
---|
| 16 | +#define RKMOUDLE_UNITE_EXTEND_PIXEL 128 |
---|
16 | 17 | /* using for rv1109 and rv1126 */ |
---|
17 | 18 | #define RKMODULE_EXTEND_LINE 24 |
---|
18 | 19 | |
---|
.. | .. |
---|
169 | 170 | #define RKMODULE_GET_READOUT_LINE_CNT_PER_LINE \ |
---|
170 | 171 | _IOR('V', BASE_VIDIOC_PRIVATE + 36, __u32) |
---|
171 | 172 | |
---|
| 173 | +#define RKMODULE_GET_GROUP_ID \ |
---|
| 174 | + _IOR('V', BASE_VIDIOC_PRIVATE + 37, __u32) |
---|
| 175 | + |
---|
| 176 | +#define RKMODULE_SET_GROUP_ID \ |
---|
| 177 | + _IOW('V', BASE_VIDIOC_PRIVATE + 38, __u32) |
---|
| 178 | + |
---|
172 | 179 | struct rkmodule_i2cdev_info { |
---|
173 | | - u8 slave_addr; |
---|
| 180 | + __u8 slave_addr; |
---|
174 | 181 | } __attribute__ ((packed)); |
---|
175 | 182 | |
---|
176 | 183 | struct rkmodule_dev_info { |
---|
177 | 184 | union { |
---|
178 | 185 | struct rkmodule_i2cdev_info i2c_dev; |
---|
179 | | - u32 reserved[8]; |
---|
| 186 | + __u32 reserved[8]; |
---|
180 | 187 | }; |
---|
181 | 188 | } __attribute__ ((packed)); |
---|
182 | 189 | |
---|
.. | .. |
---|
653 | 660 | } __attribute__ ((packed)); |
---|
654 | 661 | |
---|
655 | 662 | /* |
---|
| 663 | + * link to vicap |
---|
| 664 | + * linear mode: pad0~pad3 for id0~id3; |
---|
| 665 | + * |
---|
| 666 | + * HDR_X2: id0 fiexd to vc0 for long frame |
---|
| 667 | + * id1 fixed to vc1 for short frame; |
---|
| 668 | + * id2~id3 reserved, can config by PAD2~PAD3 |
---|
| 669 | + * |
---|
| 670 | + * HDR_X3: id0 fiexd to vc0 for long frame |
---|
| 671 | + * id1 fixed to vc1 for middle frame |
---|
| 672 | + * id2 fixed to vc2 for short frame; |
---|
| 673 | + * id3 reserved, can config by PAD3 |
---|
| 674 | + * |
---|
| 675 | + * link to isp, the connection relationship is as follows |
---|
| 676 | + */ |
---|
| 677 | +enum rkmodule_max_pad { |
---|
| 678 | + PAD0, /* link to isp */ |
---|
| 679 | + PAD1, /* link to csi wr0 | hdr x2:L x3:M */ |
---|
| 680 | + PAD2, /* link to csi wr1 | hdr x3:L */ |
---|
| 681 | + PAD3, /* link to csi wr2 | hdr x2:M x3:S */ |
---|
| 682 | + PAD_MAX, |
---|
| 683 | +}; |
---|
| 684 | + |
---|
| 685 | +/* |
---|
656 | 686 | * sensor exposure sync mode |
---|
657 | 687 | */ |
---|
658 | 688 | enum rkmodule_sync_mode { |
---|
.. | .. |
---|
663 | 693 | }; |
---|
664 | 694 | |
---|
665 | 695 | struct rkmodule_mclk_data { |
---|
666 | | - u32 enable; |
---|
667 | | - u32 mclk_index; |
---|
668 | | - u32 mclk_rate; |
---|
669 | | - u32 reserved[8]; |
---|
| 696 | + __u32 enable; |
---|
| 697 | + __u32 mclk_index; |
---|
| 698 | + __u32 mclk_rate; |
---|
| 699 | + __u32 reserved[8]; |
---|
670 | 700 | }; |
---|
671 | 701 | |
---|
672 | 702 | /* |
---|
.. | .. |
---|
716 | 746 | }; |
---|
717 | 747 | |
---|
718 | 748 | struct rkmodule_csi_dphy_param { |
---|
719 | | - u32 vendor; |
---|
720 | | - u32 lp_vol_ref; |
---|
721 | | - u32 lp_hys_sw[DPHY_MAX_LANE]; |
---|
722 | | - u32 lp_escclk_pol_sel[DPHY_MAX_LANE]; |
---|
723 | | - u32 skew_data_cal_clk[DPHY_MAX_LANE]; |
---|
724 | | - u32 clk_hs_term_sel; |
---|
725 | | - u32 data_hs_term_sel[DPHY_MAX_LANE]; |
---|
726 | | - u32 reserved[32]; |
---|
| 749 | + __u32 vendor; |
---|
| 750 | + __u32 lp_vol_ref; |
---|
| 751 | + __u32 lp_hys_sw[DPHY_MAX_LANE]; |
---|
| 752 | + __u32 lp_escclk_pol_sel[DPHY_MAX_LANE]; |
---|
| 753 | + __u32 skew_data_cal_clk[DPHY_MAX_LANE]; |
---|
| 754 | + __u32 clk_hs_term_sel; |
---|
| 755 | + __u32 data_hs_term_sel[DPHY_MAX_LANE]; |
---|
| 756 | + __u32 reserved[32]; |
---|
727 | 757 | }; |
---|
728 | 758 | |
---|
729 | 759 | struct rkmodule_sensor_fmt { |
---|