xref: /linux/drivers/media/platform/mediatek/mdp3/mdp_reg_rdma.h (revision be239684b18e1cdcafcf8c7face4a2f562c745ad)
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 /*
3  * Copyright (c) 2022 MediaTek Inc.
4  * Author: Ping-Hsun Wu <ping-hsun.wu@mediatek.com>
5  */
6 
7 #ifndef __MDP_REG_RDMA_H__
8 #define __MDP_REG_RDMA_H__
9 
10 #define MDP_RDMA_EN                     0x000
11 #define MDP_RDMA_RESET                  0x008
12 #define MDP_RDMA_CON                    0x020
13 #define MDP_RDMA_GMCIF_CON              0x028
14 #define MDP_RDMA_SRC_CON                0x030
15 #define MDP_RDMA_MF_BKGD_SIZE_IN_BYTE   0x060
16 #define MDP_RDMA_MF_BKGD_SIZE_IN_PXL    0x068
17 #define MDP_RDMA_MF_SRC_SIZE            0x070
18 #define MDP_RDMA_MF_CLIP_SIZE           0x078
19 #define MDP_RDMA_MF_OFFSET_1            0x080
20 #define MDP_RDMA_SF_BKGD_SIZE_IN_BYTE   0x090
21 #define MDP_RDMA_SRC_END_0              0x100
22 #define MDP_RDMA_SRC_END_1              0x108
23 #define MDP_RDMA_SRC_END_2              0x110
24 #define MDP_RDMA_SRC_OFFSET_0           0x118
25 #define MDP_RDMA_SRC_OFFSET_1           0x120
26 #define MDP_RDMA_SRC_OFFSET_2           0x128
27 #define MDP_RDMA_SRC_OFFSET_0_P         0x148
28 #define MDP_RDMA_TRANSFORM_0            0x200
29 #define MDP_RDMA_RESV_DUMMY_0           0x2a0
30 #define MDP_RDMA_MON_STA_1              0x408
31 #define MDP_RDMA_SRC_BASE_0             0xf00
32 #define MDP_RDMA_SRC_BASE_1             0xf08
33 #define MDP_RDMA_SRC_BASE_2             0xf10
34 #define MDP_RDMA_UFO_DEC_LENGTH_BASE_Y  0xf20
35 #define MDP_RDMA_UFO_DEC_LENGTH_BASE_C  0xf28
36 
37 /* MASK */
38 #define MDP_RDMA_EN_MASK                    0x00000001
39 #define MDP_RDMA_RESET_MASK                 0x00000001
40 #define MDP_RDMA_CON_MASK                   0x00001110
41 #define MDP_RDMA_GMCIF_CON_MASK             0xfffb3771
42 #define MDP_RDMA_SRC_CON_MASK               0xf3ffffff
43 #define MDP_RDMA_MF_BKGD_SIZE_IN_BYTE_MASK  0x001fffff
44 #define MDP_RDMA_MF_BKGD_SIZE_IN_PXL_MASK   0x001fffff
45 #define MDP_RDMA_MF_SRC_SIZE_MASK           0x1fff1fff
46 #define MDP_RDMA_MF_CLIP_SIZE_MASK          0x1fff1fff
47 #define MDP_RDMA_MF_OFFSET_1_MASK           0x003f001f
48 #define MDP_RDMA_SF_BKGD_SIZE_IN_BYTE_MASK  0x001fffff
49 #define MDP_RDMA_SRC_END_0_MASK             0xffffffff
50 #define MDP_RDMA_SRC_END_1_MASK             0xffffffff
51 #define MDP_RDMA_SRC_END_2_MASK             0xffffffff
52 #define MDP_RDMA_SRC_OFFSET_0_MASK          0xffffffff
53 #define MDP_RDMA_SRC_OFFSET_1_MASK          0xffffffff
54 #define MDP_RDMA_SRC_OFFSET_2_MASK          0xffffffff
55 #define MDP_RDMA_SRC_OFFSET_0_P_MASK        0xffffffff
56 #define MDP_RDMA_TRANSFORM_0_MASK           0xff110777
57 #define MDP_RDMA_RESV_DUMMY_0_MASK          0xffffffff
58 #define MDP_RDMA_MON_STA_1_MASK             0xffffffff
59 #define MDP_RDMA_SRC_BASE_0_MASK            0xffffffff
60 #define MDP_RDMA_SRC_BASE_1_MASK            0xffffffff
61 #define MDP_RDMA_SRC_BASE_2_MASK            0xffffffff
62 #define MDP_RDMA_UFO_DEC_LENGTH_BASE_Y_MASK 0xffffffff
63 #define MDP_RDMA_UFO_DEC_LENGTH_BASE_C_MASK 0xffffffff
64 
65 #endif  // __MDP_REG_RDMA_H__
66