media: platform: rockchip: cif: support YUYV for y swap in bt1120

Signed-off-by: Allon Huang <allon.huang@rock-chips.com>
Change-Id: I7a38f3a881be0689f3bf37736944cd7563c644ea
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
This commit is contained in:
Allon Huang
2021-01-20 10:11:27 +08:00
committed by Zefa Chen
parent de6d5e60bd
commit dd88cbecb3
2 changed files with 2 additions and 2 deletions

View File

@@ -2251,7 +2251,7 @@ static int rkcif_stream_start(struct rkcif_stream *stream)
xfer_mode = BT1120_TRANSMIT_PROGRESS;
else
xfer_mode = BT1120_TRANSMIT_INTERFACE;
if (!CIF_FETCH_IS_Y_FIRST(stream->cif_fmt_in->dvp_fmt_val))
if (CIF_FETCH_IS_Y_FIRST(stream->cif_fmt_in->dvp_fmt_val))
yc_swap = BT1120_YC_SWAP;
}

View File

@@ -206,7 +206,7 @@ enum cif_reg_index {
#define CIF_FETCH_Y_LAST_LINE(val) ((val) & 0x1fff)
/* Check if swap y and c in bt1120 mode */
#define CIF_FETCH_IS_Y_FIRST(val) ((val) & 0xf)
#define CIF_FETCH_IS_Y_FIRST(val) ((val >> 5) & 0x3)
#define CIF_RAW_STORED_BIT_WIDTH (16U)
#define CIF_YUV_STORED_BIT_WIDTH (8U)