MLK-19343: ISI: add memory to memory support for qm and qxp
authorGuoniu.Zhou <guoniu.zhou@nxp.com>
Mon, 27 Aug 2018 10:28:23 +0000 (18:28 +0800)
committerLeonard Crestez <leonard.crestez@nxp.com>
Wed, 17 Apr 2019 23:51:34 +0000 (02:51 +0300)
Add memory to memory support for qm and qxp. Because only
ISI channel0 can support memory to memory feature so this
feature only support one channel. User can use channel 0
as other function when it isn't used for m2m.

Signed-off-by: Guoniu.Zhou <guoniu.zhou@nxp.com>
Reviewed-by: Sandor.yu <sandor.yu@nxp.com>
drivers/media/platform/imx8/mxc-isi-core.h

index 852f598..0780267 100644 (file)
@@ -235,6 +235,20 @@ struct mxc_isi_m2m_dev {
 
        struct mxc_isi_frame    src_f;
        struct mxc_isi_frame    dst_f;
+
+       unsigned int    vflip:1;
+       unsigned int    hflip:1;
+       unsigned int    alphaen:1;
+
+       unsigned int aborting;
+       unsigned int read_done;
+
+       u8 alpha;
+};
+
+struct mxc_isi_ctx {
+       struct mxc_isi_dev *isi_dev;
+       struct v4l2_fh          fh;
 };
 
 struct mxc_isi_cap_dev {
@@ -290,6 +304,7 @@ struct mxc_isi_dev {
        unsigned int            crop:1;
        unsigned int            deinterlace:1;
        unsigned int            parallel_csi:1;
+       unsigned int            is_m2m:1;
 
        struct mxc_isi_ctrls ctrls;
        u8                      alpha;          /* goable alpha */