Tom Rini | 10e4779 | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0+ |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 2 | /* |
| 3 | * Copyright (c) 2015 Google, Inc |
| 4 | * (C) Copyright 2015 |
| 5 | * Bernecker & Rainer Industrieelektronik GmbH - http://www.br-automation.com |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 6 | * (C) Copyright 2023 Dzmitry Sankouski <dsankouski@gmail.com> |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 7 | */ |
| 8 | |
| 9 | #include <common.h> |
| 10 | #include <dm.h> |
| 11 | #include <video.h> |
| 12 | #include <video_console.h> |
| 13 | #include <video_font.h> /* Get font data, width and height */ |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 14 | #include "vidconsole_internal.h" |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 15 | |
| 16 | static int console_set_row_1(struct udevice *dev, uint row, int clr) |
| 17 | { |
| 18 | struct video_priv *vid_priv = dev_get_uclass_priv(dev->parent); |
| 19 | int pbytes = VNBYTES(vid_priv->bpix); |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 20 | void *start, *dst, *line; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 21 | int i, j; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 22 | int ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 23 | |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 24 | start = vid_priv->fb + vid_priv->line_length - |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 25 | (row + 1) * VIDEO_FONT_HEIGHT * pbytes; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 26 | line = start; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 27 | for (j = 0; j < vid_priv->ysize; j++) { |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 28 | dst = line; |
| 29 | for (i = 0; i < VIDEO_FONT_HEIGHT; i++) |
| 30 | fill_pixel_and_goto_next(&dst, clr, pbytes, pbytes); |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 31 | line += vid_priv->line_length; |
| 32 | } |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 33 | ret = vidconsole_sync_copy(dev, start, line); |
| 34 | if (ret) |
| 35 | return ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 36 | |
| 37 | return 0; |
| 38 | } |
| 39 | |
| 40 | static int console_move_rows_1(struct udevice *dev, uint rowdst, uint rowsrc, |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 41 | uint count) |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 42 | { |
| 43 | struct video_priv *vid_priv = dev_get_uclass_priv(dev->parent); |
Simon Glass | 80daa3f | 2020-07-02 21:12:16 -0600 | [diff] [blame] | 44 | int pbytes = VNBYTES(vid_priv->bpix); |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 45 | void *dst; |
| 46 | void *src; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 47 | int j, ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 48 | |
| 49 | dst = vid_priv->fb + vid_priv->line_length - |
| 50 | (rowdst + count) * VIDEO_FONT_HEIGHT * pbytes; |
| 51 | src = vid_priv->fb + vid_priv->line_length - |
| 52 | (rowsrc + count) * VIDEO_FONT_HEIGHT * pbytes; |
| 53 | |
| 54 | for (j = 0; j < vid_priv->ysize; j++) { |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 55 | ret = vidconsole_memmove(dev, dst, src, |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 56 | VIDEO_FONT_HEIGHT * pbytes * count); |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 57 | if (ret) |
| 58 | return ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 59 | src += vid_priv->line_length; |
| 60 | dst += vid_priv->line_length; |
| 61 | } |
| 62 | |
| 63 | return 0; |
| 64 | } |
| 65 | |
Simon Glass | 52c10c5 | 2016-01-14 18:10:37 -0700 | [diff] [blame] | 66 | static int console_putc_xy_1(struct udevice *dev, uint x_frac, uint y, char ch) |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 67 | { |
Simon Glass | 52c10c5 | 2016-01-14 18:10:37 -0700 | [diff] [blame] | 68 | struct vidconsole_priv *vc_priv = dev_get_uclass_priv(dev); |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 69 | struct udevice *vid = dev->parent; |
| 70 | struct video_priv *vid_priv = dev_get_uclass_priv(vid); |
| 71 | int pbytes = VNBYTES(vid_priv->bpix); |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 72 | int x, linenum, ret; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 73 | void *start, *line; |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 74 | uchar *pfont = video_fontdata + (u8)ch * VIDEO_FONT_HEIGHT; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 75 | |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 76 | if (x_frac + VID_TO_POS(vc_priv->x_charsize) > vc_priv->xsize_frac) |
| 77 | return -EAGAIN; |
Simon Glass | 80daa3f | 2020-07-02 21:12:16 -0600 | [diff] [blame] | 78 | linenum = VID_TO_PIXEL(x_frac) + 1; |
| 79 | x = y + 1; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 80 | start = vid_priv->fb + linenum * vid_priv->line_length - x * pbytes; |
| 81 | line = start; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 82 | |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 83 | ret = fill_char_horizontally(pfont, &line, vid_priv, FLIPPED_DIRECTION); |
| 84 | if (ret) |
| 85 | return ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 86 | |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 87 | /* We draw backwards from 'start, so account for the first line */ |
| 88 | ret = vidconsole_sync_copy(dev, start - vid_priv->line_length, line); |
| 89 | if (ret) |
| 90 | return ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 91 | |
Simon Glass | 52c10c5 | 2016-01-14 18:10:37 -0700 | [diff] [blame] | 92 | return VID_TO_POS(VIDEO_FONT_WIDTH); |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 93 | } |
| 94 | |
| 95 | |
| 96 | static int console_set_row_2(struct udevice *dev, uint row, int clr) |
| 97 | { |
| 98 | struct video_priv *vid_priv = dev_get_uclass_priv(dev->parent); |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 99 | void *start, *line, *dst, *end; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 100 | int pixels = VIDEO_FONT_HEIGHT * vid_priv->xsize; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 101 | int i, ret; |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 102 | int pbytes = VNBYTES(vid_priv->bpix); |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 103 | |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 104 | start = vid_priv->fb + vid_priv->ysize * vid_priv->line_length - |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 105 | (row + 1) * VIDEO_FONT_HEIGHT * vid_priv->line_length; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 106 | line = start; |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 107 | dst = line; |
| 108 | for (i = 0; i < pixels; i++) |
| 109 | fill_pixel_and_goto_next(&dst, clr, pbytes, pbytes); |
| 110 | end = dst; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 111 | ret = vidconsole_sync_copy(dev, start, end); |
| 112 | if (ret) |
| 113 | return ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 114 | |
| 115 | return 0; |
| 116 | } |
| 117 | |
| 118 | static int console_move_rows_2(struct udevice *dev, uint rowdst, uint rowsrc, |
| 119 | uint count) |
| 120 | { |
| 121 | struct video_priv *vid_priv = dev_get_uclass_priv(dev->parent); |
| 122 | void *dst; |
| 123 | void *src; |
| 124 | void *end; |
| 125 | |
| 126 | end = vid_priv->fb + vid_priv->ysize * vid_priv->line_length; |
| 127 | dst = end - (rowdst + count) * VIDEO_FONT_HEIGHT * |
| 128 | vid_priv->line_length; |
| 129 | src = end - (rowsrc + count) * VIDEO_FONT_HEIGHT * |
| 130 | vid_priv->line_length; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 131 | vidconsole_memmove(dev, dst, src, |
| 132 | VIDEO_FONT_HEIGHT * vid_priv->line_length * count); |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 133 | |
| 134 | return 0; |
| 135 | } |
| 136 | |
Simon Glass | 52c10c5 | 2016-01-14 18:10:37 -0700 | [diff] [blame] | 137 | static int console_putc_xy_2(struct udevice *dev, uint x_frac, uint y, char ch) |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 138 | { |
Simon Glass | 52c10c5 | 2016-01-14 18:10:37 -0700 | [diff] [blame] | 139 | struct vidconsole_priv *vc_priv = dev_get_uclass_priv(dev); |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 140 | struct udevice *vid = dev->parent; |
| 141 | struct video_priv *vid_priv = dev_get_uclass_priv(vid); |
Simon Glass | 80daa3f | 2020-07-02 21:12:16 -0600 | [diff] [blame] | 142 | int pbytes = VNBYTES(vid_priv->bpix); |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 143 | int linenum, x, ret; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 144 | void *start, *line; |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 145 | uchar *pfont = video_fontdata + (u8)ch * VIDEO_FONT_HEIGHT; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 146 | |
Simon Glass | 52c10c5 | 2016-01-14 18:10:37 -0700 | [diff] [blame] | 147 | if (x_frac + VID_TO_POS(vc_priv->x_charsize) > vc_priv->xsize_frac) |
| 148 | return -EAGAIN; |
Simon Glass | 80daa3f | 2020-07-02 21:12:16 -0600 | [diff] [blame] | 149 | linenum = vid_priv->ysize - y - 1; |
Simon Glass | f50a6b9 | 2020-07-02 21:12:17 -0600 | [diff] [blame] | 150 | x = vid_priv->xsize - VID_TO_PIXEL(x_frac) - 1; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 151 | start = vid_priv->fb + linenum * vid_priv->line_length + x * pbytes; |
| 152 | line = start; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 153 | |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 154 | ret = fill_char_vertically(pfont, &line, vid_priv, FLIPPED_DIRECTION); |
| 155 | if (ret) |
| 156 | return ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 157 | |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 158 | /* Add 4 bytes to allow for the first pixel writen */ |
| 159 | ret = vidconsole_sync_copy(dev, start + 4, line); |
| 160 | if (ret) |
| 161 | return ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 162 | |
Simon Glass | 52c10c5 | 2016-01-14 18:10:37 -0700 | [diff] [blame] | 163 | return VID_TO_POS(VIDEO_FONT_WIDTH); |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 164 | } |
| 165 | |
| 166 | static int console_set_row_3(struct udevice *dev, uint row, int clr) |
| 167 | { |
| 168 | struct video_priv *vid_priv = dev_get_uclass_priv(dev->parent); |
| 169 | int pbytes = VNBYTES(vid_priv->bpix); |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 170 | void *start, *dst, *line; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 171 | int i, j, ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 172 | |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 173 | start = vid_priv->fb + row * VIDEO_FONT_HEIGHT * pbytes; |
| 174 | line = start; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 175 | for (j = 0; j < vid_priv->ysize; j++) { |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 176 | dst = line; |
| 177 | for (i = 0; i < VIDEO_FONT_HEIGHT; i++) |
| 178 | fill_pixel_and_goto_next(&dst, clr, pbytes, pbytes); |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 179 | line += vid_priv->line_length; |
| 180 | } |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 181 | ret = vidconsole_sync_copy(dev, start, line); |
| 182 | if (ret) |
| 183 | return ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 184 | |
| 185 | return 0; |
| 186 | } |
| 187 | |
| 188 | static int console_move_rows_3(struct udevice *dev, uint rowdst, uint rowsrc, |
| 189 | uint count) |
| 190 | { |
| 191 | struct video_priv *vid_priv = dev_get_uclass_priv(dev->parent); |
Simon Glass | 80daa3f | 2020-07-02 21:12:16 -0600 | [diff] [blame] | 192 | int pbytes = VNBYTES(vid_priv->bpix); |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 193 | void *dst; |
| 194 | void *src; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 195 | int j, ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 196 | |
| 197 | dst = vid_priv->fb + rowdst * VIDEO_FONT_HEIGHT * pbytes; |
| 198 | src = vid_priv->fb + rowsrc * VIDEO_FONT_HEIGHT * pbytes; |
| 199 | |
| 200 | for (j = 0; j < vid_priv->ysize; j++) { |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 201 | ret = vidconsole_memmove(dev, dst, src, |
| 202 | VIDEO_FONT_HEIGHT * pbytes * count); |
| 203 | if (ret) |
| 204 | return ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 205 | src += vid_priv->line_length; |
| 206 | dst += vid_priv->line_length; |
| 207 | } |
| 208 | |
| 209 | return 0; |
| 210 | } |
| 211 | |
Simon Glass | 52c10c5 | 2016-01-14 18:10:37 -0700 | [diff] [blame] | 212 | static int console_putc_xy_3(struct udevice *dev, uint x_frac, uint y, char ch) |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 213 | { |
Simon Glass | 52c10c5 | 2016-01-14 18:10:37 -0700 | [diff] [blame] | 214 | struct vidconsole_priv *vc_priv = dev_get_uclass_priv(dev); |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 215 | struct udevice *vid = dev->parent; |
| 216 | struct video_priv *vid_priv = dev_get_uclass_priv(vid); |
| 217 | int pbytes = VNBYTES(vid_priv->bpix); |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 218 | int linenum, x, ret; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 219 | void *start, *line; |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 220 | uchar *pfont = video_fontdata + (u8)ch * VIDEO_FONT_HEIGHT; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 221 | |
Simon Glass | 52c10c5 | 2016-01-14 18:10:37 -0700 | [diff] [blame] | 222 | if (x_frac + VID_TO_POS(vc_priv->x_charsize) > vc_priv->xsize_frac) |
| 223 | return -EAGAIN; |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 224 | x = y; |
| 225 | linenum = vid_priv->ysize - VID_TO_PIXEL(x_frac) - 1; |
| 226 | start = vid_priv->fb + linenum * vid_priv->line_length + y * pbytes; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 227 | line = start; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 228 | |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 229 | ret = fill_char_horizontally(pfont, &line, vid_priv, NORMAL_DIRECTION); |
| 230 | if (ret) |
| 231 | return ret; |
Simon Glass | 42301da | 2020-07-02 21:12:26 -0600 | [diff] [blame] | 232 | /* Add a line to allow for the first pixels writen */ |
| 233 | ret = vidconsole_sync_copy(dev, start + vid_priv->line_length, line); |
| 234 | if (ret) |
| 235 | return ret; |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 236 | |
Simon Glass | 52c10c5 | 2016-01-14 18:10:37 -0700 | [diff] [blame] | 237 | return VID_TO_POS(VIDEO_FONT_WIDTH); |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 238 | } |
| 239 | |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 240 | struct vidconsole_ops console_ops_1 = { |
| 241 | .putc_xy = console_putc_xy_1, |
| 242 | .move_rows = console_move_rows_1, |
| 243 | .set_row = console_set_row_1, |
| 244 | }; |
| 245 | |
| 246 | struct vidconsole_ops console_ops_2 = { |
| 247 | .putc_xy = console_putc_xy_2, |
| 248 | .move_rows = console_move_rows_2, |
| 249 | .set_row = console_set_row_2, |
| 250 | }; |
| 251 | |
| 252 | struct vidconsole_ops console_ops_3 = { |
| 253 | .putc_xy = console_putc_xy_3, |
| 254 | .move_rows = console_move_rows_3, |
| 255 | .set_row = console_set_row_3, |
| 256 | }; |
| 257 | |
| 258 | U_BOOT_DRIVER(vidconsole_1) = { |
| 259 | .name = "vidconsole1", |
| 260 | .id = UCLASS_VIDEO_CONSOLE, |
| 261 | .ops = &console_ops_1, |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 262 | .probe = console_probe, |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 263 | }; |
| 264 | |
| 265 | U_BOOT_DRIVER(vidconsole_2) = { |
| 266 | .name = "vidconsole2", |
| 267 | .id = UCLASS_VIDEO_CONSOLE, |
| 268 | .ops = &console_ops_2, |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 269 | .probe = console_probe, |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 270 | }; |
| 271 | |
| 272 | U_BOOT_DRIVER(vidconsole_3) = { |
| 273 | .name = "vidconsole3", |
| 274 | .id = UCLASS_VIDEO_CONSOLE, |
| 275 | .ops = &console_ops_3, |
Dzmitry Sankouski | aea2d2d | 2023-03-07 13:21:11 +0300 | [diff] [blame^] | 276 | .probe = console_probe, |
Simon Glass | 87aae88 | 2016-01-18 19:52:19 -0700 | [diff] [blame] | 277 | }; |