diff options
author | liuxl0327 <liuxl0327@starfivetech.com> | 2022-03-21 10:20:43 +0300 |
---|---|---|
committer | mason.huo <mason.huo@starfivetech.com> | 2022-07-01 10:05:38 +0300 |
commit | a58e75705ace00642d6411ce501a425982ee6c4c (patch) | |
tree | dec8b97f7cfee81cea74b77b2b4b872d28934aa9 /drivers/media/platform/starfive/v4l2_driver/stf_isp.h | |
parent | 009c4abdd7a22556d3ee04a7358f5c9ba21afbe7 (diff) | |
download | linux-a58e75705ace00642d6411ce501a425982ee6c4c.tar.xz |
v4l2: starfive ISP add private ioctl
Signed-off-by: mason.huo <mason.huo@starfivetech.com>
Diffstat (limited to 'drivers/media/platform/starfive/v4l2_driver/stf_isp.h')
-rw-r--r--[-rwxr-xr-x] | drivers/media/platform/starfive/v4l2_driver/stf_isp.h | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/drivers/media/platform/starfive/v4l2_driver/stf_isp.h b/drivers/media/platform/starfive/v4l2_driver/stf_isp.h index e4938f841a50..65b467d05571 100755..100644 --- a/drivers/media/platform/starfive/v4l2_driver/stf_isp.h +++ b/drivers/media/platform/starfive/v4l2_driver/stf_isp.h @@ -11,13 +11,13 @@ #include <media/media-entity.h> #include <video/stf-vin.h> +#define STF_ISP_NAME "stf_isp" #define STF_ISP_PAD_SINK 0 #define STF_ISP_PAD_SRC 1 #define STF_ISP_PADS_NUM 2 #define STF_ISP0_SETFILE "stf_isp0_fw.bin" #define STF_ISP1_SETFILE "stf_isp1_fw.bin" -#define FILENAME_MAX_LEN 30 #define SCALER_RATIO_MAX 1 // no compose function #define STF_ISP_REG_OFFSET_MAX 0x0FFF @@ -28,13 +28,6 @@ #define ISP_REG_DUMP_CFG_1 0x00000028 #define ISP_REG_IESHD_ADDR 0x00000A50 -struct stfisp_fw_info { - char __user filename[FILENAME_MAX_LEN]; -}; - -#define VIDIOC_STFISP_LOAD_FW \ - _IOW('V', BASE_VIDIOC_PRIVATE + 1, struct stfisp_fw_info) - struct isp_format { u32 code; u8 bpp; @@ -64,6 +57,9 @@ struct isp_hw_ops { struct v4l2_rect *crop, u32 mcode); // u32 width, u32 height); int (*isp_stream_set)(struct stf_isp_dev *isp_dev, int on); + int (*isp_reg_read)(struct stf_isp_dev *isp_dev, void *arg); + int (*isp_reg_write)(struct stf_isp_dev *isp_dev, void *arg); + int (*isp_shadow_trigger)(struct stf_isp_dev *isp_dev); }; struct isp_ctrls { @@ -114,6 +110,7 @@ struct stf_isp_dev { struct isp_hw_ops *hw_ops; struct mutex stream_lock; int stream_count; + atomic_t shadow_count; struct isp_ctrls ctrls; struct mutex setfile_lock; |