Linux kernel mirror (for testing)
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel
os
linux
1/* SPDX-License-Identifier: GPL-2.0 */
2/*
3 * PKUnity UNIGFX Registers
4 */
5
6#define UDE_BASE (PKUNITY_UNIGFX_BASE + 0x1400)
7#define UGE_BASE (PKUNITY_UNIGFX_BASE + 0x0000)
8
9/*
10 * command reg for UNIGFX DE
11 */
12/*
13 * control reg UDE_CFG
14 */
15#define UDE_CFG (UDE_BASE + 0x0000)
16/*
17 * framebuffer start address reg UDE_FSA
18 */
19#define UDE_FSA (UDE_BASE + 0x0004)
20/*
21 * line size reg UDE_LS
22 */
23#define UDE_LS (UDE_BASE + 0x0008)
24/*
25 * pitch size reg UDE_PS
26 */
27#define UDE_PS (UDE_BASE + 0x000C)
28/*
29 * horizontal active time reg UDE_HAT
30 */
31#define UDE_HAT (UDE_BASE + 0x0010)
32/*
33 * horizontal blank time reg UDE_HBT
34 */
35#define UDE_HBT (UDE_BASE + 0x0014)
36/*
37 * horizontal sync time reg UDE_HST
38 */
39#define UDE_HST (UDE_BASE + 0x0018)
40/*
41 * vertival active time reg UDE_VAT
42 */
43#define UDE_VAT (UDE_BASE + 0x001C)
44/*
45 * vertival blank time reg UDE_VBT
46 */
47#define UDE_VBT (UDE_BASE + 0x0020)
48/*
49 * vertival sync time reg UDE_VST
50 */
51#define UDE_VST (UDE_BASE + 0x0024)
52/*
53 * cursor position UDE_CXY
54 */
55#define UDE_CXY (UDE_BASE + 0x0028)
56/*
57 * cursor front color UDE_CC0
58 */
59#define UDE_CC0 (UDE_BASE + 0x002C)
60/*
61 * cursor background color UDE_CC1
62 */
63#define UDE_CC1 (UDE_BASE + 0x0030)
64/*
65 * video position UDE_VXY
66 */
67#define UDE_VXY (UDE_BASE + 0x0034)
68/*
69 * video start address reg UDE_VSA
70 */
71#define UDE_VSA (UDE_BASE + 0x0040)
72/*
73 * video size reg UDE_VS
74 */
75#define UDE_VS (UDE_BASE + 0x004C)
76
77/*
78 * command reg for UNIGFX GE
79 */
80/*
81 * src xy reg UGE_SRCXY
82 */
83#define UGE_SRCXY (UGE_BASE + 0x0000)
84/*
85 * dst xy reg UGE_DSTXY
86 */
87#define UGE_DSTXY (UGE_BASE + 0x0004)
88/*
89 * pitch reg UGE_PITCH
90 */
91#define UGE_PITCH (UGE_BASE + 0x0008)
92/*
93 * src start reg UGE_SRCSTART
94 */
95#define UGE_SRCSTART (UGE_BASE + 0x000C)
96/*
97 * dst start reg UGE_DSTSTART
98 */
99#define UGE_DSTSTART (UGE_BASE + 0x0010)
100/*
101 * width height reg UGE_WIDHEIGHT
102 */
103#define UGE_WIDHEIGHT (UGE_BASE + 0x0014)
104/*
105 * rop alpah reg UGE_ROPALPHA
106 */
107#define UGE_ROPALPHA (UGE_BASE + 0x0018)
108/*
109 * front color UGE_FCOLOR
110 */
111#define UGE_FCOLOR (UGE_BASE + 0x001C)
112/*
113 * background color UGE_BCOLOR
114 */
115#define UGE_BCOLOR (UGE_BASE + 0x0020)
116/*
117 * src color key for high value UGE_SCH
118 */
119#define UGE_SCH (UGE_BASE + 0x0024)
120/*
121 * dst color key for high value UGE_DCH
122 */
123#define UGE_DCH (UGE_BASE + 0x0028)
124/*
125 * src color key for low value UGE_SCL
126 */
127#define UGE_SCL (UGE_BASE + 0x002C)
128/*
129 * dst color key for low value UGE_DCL
130 */
131#define UGE_DCL (UGE_BASE + 0x0030)
132/*
133 * clip 0 reg UGE_CLIP0
134 */
135#define UGE_CLIP0 (UGE_BASE + 0x0034)
136/*
137 * clip 1 reg UGE_CLIP1
138 */
139#define UGE_CLIP1 (UGE_BASE + 0x0038)
140/*
141 * command reg UGE_COMMAND
142 */
143#define UGE_COMMAND (UGE_BASE + 0x003C)
144/*
145 * pattern 0 UGE_P0
146 */
147#define UGE_P0 (UGE_BASE + 0x0040)
148#define UGE_P1 (UGE_BASE + 0x0044)
149#define UGE_P2 (UGE_BASE + 0x0048)
150#define UGE_P3 (UGE_BASE + 0x004C)
151#define UGE_P4 (UGE_BASE + 0x0050)
152#define UGE_P5 (UGE_BASE + 0x0054)
153#define UGE_P6 (UGE_BASE + 0x0058)
154#define UGE_P7 (UGE_BASE + 0x005C)
155#define UGE_P8 (UGE_BASE + 0x0060)
156#define UGE_P9 (UGE_BASE + 0x0064)
157#define UGE_P10 (UGE_BASE + 0x0068)
158#define UGE_P11 (UGE_BASE + 0x006C)
159#define UGE_P12 (UGE_BASE + 0x0070)
160#define UGE_P13 (UGE_BASE + 0x0074)
161#define UGE_P14 (UGE_BASE + 0x0078)
162#define UGE_P15 (UGE_BASE + 0x007C)
163#define UGE_P16 (UGE_BASE + 0x0080)
164#define UGE_P17 (UGE_BASE + 0x0084)
165#define UGE_P18 (UGE_BASE + 0x0088)
166#define UGE_P19 (UGE_BASE + 0x008C)
167#define UGE_P20 (UGE_BASE + 0x0090)
168#define UGE_P21 (UGE_BASE + 0x0094)
169#define UGE_P22 (UGE_BASE + 0x0098)
170#define UGE_P23 (UGE_BASE + 0x009C)
171#define UGE_P24 (UGE_BASE + 0x00A0)
172#define UGE_P25 (UGE_BASE + 0x00A4)
173#define UGE_P26 (UGE_BASE + 0x00A8)
174#define UGE_P27 (UGE_BASE + 0x00AC)
175#define UGE_P28 (UGE_BASE + 0x00B0)
176#define UGE_P29 (UGE_BASE + 0x00B4)
177#define UGE_P30 (UGE_BASE + 0x00B8)
178#define UGE_P31 (UGE_BASE + 0x00BC)
179
180#define UDE_CFG_DST_MASK FMASK(2, 8)
181#define UDE_CFG_DST8 FIELD(0x0, 2, 8)
182#define UDE_CFG_DST16 FIELD(0x1, 2, 8)
183#define UDE_CFG_DST24 FIELD(0x2, 2, 8)
184#define UDE_CFG_DST32 FIELD(0x3, 2, 8)
185
186/*
187 * GDEN enable UDE_CFG_GDEN_ENABLE
188 */
189#define UDE_CFG_GDEN_ENABLE FIELD(1, 1, 3)
190/*
191 * VDEN enable UDE_CFG_VDEN_ENABLE
192 */
193#define UDE_CFG_VDEN_ENABLE FIELD(1, 1, 4)
194/*
195 * CDEN enable UDE_CFG_CDEN_ENABLE
196 */
197#define UDE_CFG_CDEN_ENABLE FIELD(1, 1, 5)
198/*
199 * TIMEUP enable UDE_CFG_TIMEUP_ENABLE
200 */
201#define UDE_CFG_TIMEUP_ENABLE FIELD(1, 1, 6)