Skip to content

Commit 215737e

Browse files
Andy Yanmmind
authored andcommitted
drm/rockchip: vop2: rename window formats to show window type using them
formats_win_full_10bit is for cluster window, formats_win_full_10bit_yuyv is for rk356x esmart, rk3588 esmart window will support more format. formats_win_lite is for smart window. Rename it based the windows type may let meaning is clearer Signed-off-by: Andy Yan <andy.yan@rock-chips.com> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Heiko Stuebner <heiko@sntech.de> Link: https://patchwork.freedesktop.org/patch/msgid/20231018094339.2476142-1-andyshrk@163.com
1 parent bfd8a5c commit 215737e

1 file changed

Lines changed: 15 additions & 15 deletions

File tree

drivers/gpu/drm/rockchip/rockchip_vop2_reg.c

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
#include "rockchip_drm_vop2.h"
1717

18-
static const uint32_t formats_win_full_10bit[] = {
18+
static const uint32_t formats_cluster[] = {
1919
DRM_FORMAT_XRGB2101010,
2020
DRM_FORMAT_ARGB2101010,
2121
DRM_FORMAT_XBGR2101010,
@@ -34,7 +34,7 @@ static const uint32_t formats_win_full_10bit[] = {
3434
DRM_FORMAT_Y210, /* yuv422_10bit non-Linear mode only */
3535
};
3636

37-
static const uint32_t formats_win_full_10bit_yuyv[] = {
37+
static const uint32_t formats_rk356x_esmart[] = {
3838
DRM_FORMAT_XRGB8888,
3939
DRM_FORMAT_ARGB8888,
4040
DRM_FORMAT_XBGR8888,
@@ -54,7 +54,7 @@ static const uint32_t formats_win_full_10bit_yuyv[] = {
5454
DRM_FORMAT_VYUY, /* yuv422_8bit[VYUY] linear mode */
5555
};
5656

57-
static const uint32_t formats_win_lite[] = {
57+
static const uint32_t formats_smart[] = {
5858
DRM_FORMAT_XRGB8888,
5959
DRM_FORMAT_ARGB8888,
6060
DRM_FORMAT_XBGR8888,
@@ -153,8 +153,8 @@ static const struct vop2_win_data rk3568_vop_win_data[] = {
153153
.name = "Smart0-win0",
154154
.phys_id = ROCKCHIP_VOP2_SMART0,
155155
.base = 0x1c00,
156-
.formats = formats_win_lite,
157-
.nformats = ARRAY_SIZE(formats_win_lite),
156+
.formats = formats_smart,
157+
.nformats = ARRAY_SIZE(formats_smart),
158158
.format_modifiers = format_modifiers,
159159
.layer_sel_id = 3,
160160
.supported_rotations = DRM_MODE_REFLECT_Y,
@@ -165,8 +165,8 @@ static const struct vop2_win_data rk3568_vop_win_data[] = {
165165
}, {
166166
.name = "Smart1-win0",
167167
.phys_id = ROCKCHIP_VOP2_SMART1,
168-
.formats = formats_win_lite,
169-
.nformats = ARRAY_SIZE(formats_win_lite),
168+
.formats = formats_smart,
169+
.nformats = ARRAY_SIZE(formats_smart),
170170
.format_modifiers = format_modifiers,
171171
.base = 0x1e00,
172172
.layer_sel_id = 7,
@@ -178,8 +178,8 @@ static const struct vop2_win_data rk3568_vop_win_data[] = {
178178
}, {
179179
.name = "Esmart1-win0",
180180
.phys_id = ROCKCHIP_VOP2_ESMART1,
181-
.formats = formats_win_full_10bit_yuyv,
182-
.nformats = ARRAY_SIZE(formats_win_full_10bit_yuyv),
181+
.formats = formats_rk356x_esmart,
182+
.nformats = ARRAY_SIZE(formats_rk356x_esmart),
183183
.format_modifiers = format_modifiers,
184184
.base = 0x1a00,
185185
.layer_sel_id = 6,
@@ -191,8 +191,8 @@ static const struct vop2_win_data rk3568_vop_win_data[] = {
191191
}, {
192192
.name = "Esmart0-win0",
193193
.phys_id = ROCKCHIP_VOP2_ESMART0,
194-
.formats = formats_win_full_10bit_yuyv,
195-
.nformats = ARRAY_SIZE(formats_win_full_10bit_yuyv),
194+
.formats = formats_rk356x_esmart,
195+
.nformats = ARRAY_SIZE(formats_rk356x_esmart),
196196
.format_modifiers = format_modifiers,
197197
.base = 0x1800,
198198
.layer_sel_id = 2,
@@ -205,8 +205,8 @@ static const struct vop2_win_data rk3568_vop_win_data[] = {
205205
.name = "Cluster0-win0",
206206
.phys_id = ROCKCHIP_VOP2_CLUSTER0,
207207
.base = 0x1000,
208-
.formats = formats_win_full_10bit,
209-
.nformats = ARRAY_SIZE(formats_win_full_10bit),
208+
.formats = formats_cluster,
209+
.nformats = ARRAY_SIZE(formats_cluster),
210210
.format_modifiers = format_modifiers_afbc,
211211
.layer_sel_id = 0,
212212
.supported_rotations = DRM_MODE_ROTATE_90 | DRM_MODE_ROTATE_270 |
@@ -220,8 +220,8 @@ static const struct vop2_win_data rk3568_vop_win_data[] = {
220220
.name = "Cluster1-win0",
221221
.phys_id = ROCKCHIP_VOP2_CLUSTER1,
222222
.base = 0x1200,
223-
.formats = formats_win_full_10bit,
224-
.nformats = ARRAY_SIZE(formats_win_full_10bit),
223+
.formats = formats_cluster,
224+
.nformats = ARRAY_SIZE(formats_cluster),
225225
.format_modifiers = format_modifiers_afbc,
226226
.layer_sel_id = 1,
227227
.supported_rotations = DRM_MODE_ROTATE_90 | DRM_MODE_ROTATE_270 |

0 commit comments

Comments
 (0)