aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/arm/mach-shmobile/board-ag5evm.c4
-rw-r--r--arch/arm/mach-shmobile/board-ap4evb.c4
-rw-r--r--arch/arm/mach-shmobile/board-bonito.c4
-rw-r--r--arch/arm/mach-shmobile/board-mackerel.c4
-rw-r--r--arch/sh/boards/mach-ap325rxa/setup.c4
-rw-r--r--arch/sh/boards/mach-ecovec24/setup.c8
-rw-r--r--arch/sh/boards/mach-kfr2r09/setup.c4
-rw-r--r--arch/sh/boards/mach-migor/setup.c8
-rw-r--r--arch/sh/boards/mach-se/7724/setup.c8
-rw-r--r--drivers/video/sh_mipi_dsi.c38
-rw-r--r--drivers/video/sh_mobile_lcdcfb.c20
-rw-r--r--include/video/sh_mobile_lcdc.h4
12 files changed, 55 insertions, 55 deletions
diff --git a/arch/arm/mach-shmobile/board-ag5evm.c b/arch/arm/mach-shmobile/board-ag5evm.c
index 199b3b958f42..33dad1da9310 100644
--- a/arch/arm/mach-shmobile/board-ag5evm.c
+++ b/arch/arm/mach-shmobile/board-ag5evm.c
@@ -253,8 +253,8 @@ static struct sh_mobile_lcdc_info lcdc0_info = {
253 .clock_divider = 1, 253 .clock_divider = 1,
254 .flags = LCDC_FLAGS_DWPOL, 254 .flags = LCDC_FLAGS_DWPOL,
255 .fourcc = V4L2_PIX_FMT_RGB565, 255 .fourcc = V4L2_PIX_FMT_RGB565,
256 .lcd_cfg = lcdc0_modes, 256 .lcd_modes = lcdc0_modes,
257 .num_cfg = ARRAY_SIZE(lcdc0_modes), 257 .num_modes = ARRAY_SIZE(lcdc0_modes),
258 .panel_cfg = { 258 .panel_cfg = {
259 .width = 44, 259 .width = 44,
260 .height = 79, 260 .height = 79,
diff --git a/arch/arm/mach-shmobile/board-ap4evb.c b/arch/arm/mach-shmobile/board-ap4evb.c
index 2cb6c39dd62a..80b943029815 100644
--- a/arch/arm/mach-shmobile/board-ap4evb.c
+++ b/arch/arm/mach-shmobile/board-ap4evb.c
@@ -593,8 +593,8 @@ static struct sh_mobile_lcdc_info lcdc_info = {
593 .ch[0] = { 593 .ch[0] = {
594 .chan = LCDC_CHAN_MAINLCD, 594 .chan = LCDC_CHAN_MAINLCD,
595 .fourcc = V4L2_PIX_FMT_RGB565, 595 .fourcc = V4L2_PIX_FMT_RGB565,
596 .lcd_cfg = ap4evb_lcdc_modes, 596 .lcd_modes = ap4evb_lcdc_modes,
597 .num_cfg = ARRAY_SIZE(ap4evb_lcdc_modes), 597 .num_modes = ARRAY_SIZE(ap4evb_lcdc_modes),
598 .meram_cfg = &lcd_meram_cfg, 598 .meram_cfg = &lcd_meram_cfg,
599#ifdef CONFIG_AP4EVB_QHD 599#ifdef CONFIG_AP4EVB_QHD
600 .tx_dev = &mipidsi0_device, 600 .tx_dev = &mipidsi0_device,
diff --git a/arch/arm/mach-shmobile/board-bonito.c b/arch/arm/mach-shmobile/board-bonito.c
index 9cd9408b851b..fb90f0898d9c 100644
--- a/arch/arm/mach-shmobile/board-bonito.c
+++ b/arch/arm/mach-shmobile/board-bonito.c
@@ -245,8 +245,8 @@ static struct sh_mobile_lcdc_info lcdc0_info = {
245 .interface_type = RGB24, 245 .interface_type = RGB24,
246 .clock_divider = 5, 246 .clock_divider = 5,
247 .flags = 0, 247 .flags = 0,
248 .lcd_cfg = &lcdc0_mode, 248 .lcd_modes = &lcdc0_mode,
249 .num_cfg = 1, 249 .num_modes = 1,
250 .panel_cfg = { 250 .panel_cfg = {
251 .width = 152, 251 .width = 152,
252 .height = 91, 252 .height = 91,
diff --git a/arch/arm/mach-shmobile/board-mackerel.c b/arch/arm/mach-shmobile/board-mackerel.c
index 9228cc555b46..aff7df8ccc30 100644
--- a/arch/arm/mach-shmobile/board-mackerel.c
+++ b/arch/arm/mach-shmobile/board-mackerel.c
@@ -384,8 +384,8 @@ static struct sh_mobile_lcdc_info lcdc_info = {
384 .ch[0] = { 384 .ch[0] = {
385 .chan = LCDC_CHAN_MAINLCD, 385 .chan = LCDC_CHAN_MAINLCD,
386 .fourcc = V4L2_PIX_FMT_RGB565, 386 .fourcc = V4L2_PIX_FMT_RGB565,
387 .lcd_cfg = mackerel_lcdc_modes, 387 .lcd_modes = mackerel_lcdc_modes,
388 .num_cfg = ARRAY_SIZE(mackerel_lcdc_modes), 388 .num_modes = ARRAY_SIZE(mackerel_lcdc_modes),
389 .interface_type = RGB24, 389 .interface_type = RGB24,
390 .clock_divider = 3, 390 .clock_divider = 3,
391 .flags = 0, 391 .flags = 0,
diff --git a/arch/sh/boards/mach-ap325rxa/setup.c b/arch/sh/boards/mach-ap325rxa/setup.c
index a87b7f42f120..8cf02e343333 100644
--- a/arch/sh/boards/mach-ap325rxa/setup.c
+++ b/arch/sh/boards/mach-ap325rxa/setup.c
@@ -211,8 +211,8 @@ static struct sh_mobile_lcdc_info lcdc_info = {
211 .fourcc = V4L2_PIX_FMT_RGB565, 211 .fourcc = V4L2_PIX_FMT_RGB565,
212 .interface_type = RGB18, 212 .interface_type = RGB18,
213 .clock_divider = 1, 213 .clock_divider = 1,
214 .lcd_cfg = ap325rxa_lcdc_modes, 214 .lcd_modes = ap325rxa_lcdc_modes,
215 .num_cfg = ARRAY_SIZE(ap325rxa_lcdc_modes), 215 .num_modes = ARRAY_SIZE(ap325rxa_lcdc_modes),
216 .panel_cfg = { 216 .panel_cfg = {
217 .width = 152, /* 7.0 inch */ 217 .width = 152, /* 7.0 inch */
218 .height = 91, 218 .height = 91,
diff --git a/arch/sh/boards/mach-ecovec24/setup.c b/arch/sh/boards/mach-ecovec24/setup.c
index 41767451ead1..0b08230546e7 100644
--- a/arch/sh/boards/mach-ecovec24/setup.c
+++ b/arch/sh/boards/mach-ecovec24/setup.c
@@ -1114,8 +1114,8 @@ static int __init arch_setup(void)
1114 /* DVI */ 1114 /* DVI */
1115 lcdc_info.clock_source = LCDC_CLK_EXTERNAL; 1115 lcdc_info.clock_source = LCDC_CLK_EXTERNAL;
1116 lcdc_info.ch[0].clock_divider = 1; 1116 lcdc_info.ch[0].clock_divider = 1;
1117 lcdc_info.ch[0].lcd_cfg = ecovec_dvi_modes; 1117 lcdc_info.ch[0].lcd_modes = ecovec_dvi_modes;
1118 lcdc_info.ch[0].num_cfg = ARRAY_SIZE(ecovec_dvi_modes); 1118 lcdc_info.ch[0].num_modes = ARRAY_SIZE(ecovec_dvi_modes);
1119 1119
1120 gpio_set_value(GPIO_PTA2, 1); 1120 gpio_set_value(GPIO_PTA2, 1);
1121 gpio_set_value(GPIO_PTU1, 1); 1121 gpio_set_value(GPIO_PTU1, 1);
@@ -1123,8 +1123,8 @@ static int __init arch_setup(void)
1123 /* Panel */ 1123 /* Panel */
1124 lcdc_info.clock_source = LCDC_CLK_PERIPHERAL; 1124 lcdc_info.clock_source = LCDC_CLK_PERIPHERAL;
1125 lcdc_info.ch[0].clock_divider = 2; 1125 lcdc_info.ch[0].clock_divider = 2;
1126 lcdc_info.ch[0].lcd_cfg = ecovec_lcd_modes; 1126 lcdc_info.ch[0].lcd_modes = ecovec_lcd_modes;
1127 lcdc_info.ch[0].num_cfg = ARRAY_SIZE(ecovec_lcd_modes); 1127 lcdc_info.ch[0].num_modes = ARRAY_SIZE(ecovec_lcd_modes);
1128 1128
1129 gpio_set_value(GPIO_PTR1, 1); 1129 gpio_set_value(GPIO_PTR1, 1);
1130 1130
diff --git a/arch/sh/boards/mach-kfr2r09/setup.c b/arch/sh/boards/mach-kfr2r09/setup.c
index 77d5a60d64fd..d04a55d3b877 100644
--- a/arch/sh/boards/mach-kfr2r09/setup.c
+++ b/arch/sh/boards/mach-kfr2r09/setup.c
@@ -148,8 +148,8 @@ static struct sh_mobile_lcdc_info kfr2r09_sh_lcdc_info = {
148 .interface_type = SYS18, 148 .interface_type = SYS18,
149 .clock_divider = 6, 149 .clock_divider = 6,
150 .flags = LCDC_FLAGS_DWPOL, 150 .flags = LCDC_FLAGS_DWPOL,
151 .lcd_cfg = kfr2r09_lcdc_modes, 151 .lcd_modes = kfr2r09_lcdc_modes,
152 .num_cfg = ARRAY_SIZE(kfr2r09_lcdc_modes), 152 .num_modes = ARRAY_SIZE(kfr2r09_lcdc_modes),
153 .panel_cfg = { 153 .panel_cfg = {
154 .width = 35, 154 .width = 35,
155 .height = 58, 155 .height = 58,
diff --git a/arch/sh/boards/mach-migor/setup.c b/arch/sh/boards/mach-migor/setup.c
index 93a1c9109abc..ff6f69c6906e 100644
--- a/arch/sh/boards/mach-migor/setup.c
+++ b/arch/sh/boards/mach-migor/setup.c
@@ -246,8 +246,8 @@ static struct sh_mobile_lcdc_info sh_mobile_lcdc_info = {
246 .fourcc = V4L2_PIX_FMT_RGB565, 246 .fourcc = V4L2_PIX_FMT_RGB565,
247 .interface_type = RGB16, 247 .interface_type = RGB16,
248 .clock_divider = 2, 248 .clock_divider = 2,
249 .lcd_cfg = migor_lcd_modes, 249 .lcd_modes = migor_lcd_modes,
250 .num_cfg = ARRAY_SIZE(migor_lcd_modes), 250 .num_modes = ARRAY_SIZE(migor_lcd_modes),
251 .panel_cfg = { /* 7.0 inch */ 251 .panel_cfg = { /* 7.0 inch */
252 .width = 152, 252 .width = 152,
253 .height = 91, 253 .height = 91,
@@ -260,8 +260,8 @@ static struct sh_mobile_lcdc_info sh_mobile_lcdc_info = {
260 .fourcc = V4L2_PIX_FMT_RGB565, 260 .fourcc = V4L2_PIX_FMT_RGB565,
261 .interface_type = SYS16A, 261 .interface_type = SYS16A,
262 .clock_divider = 10, 262 .clock_divider = 10,
263 .lcd_cfg = migor_lcd_modes, 263 .lcd_modes = migor_lcd_modes,
264 .num_cfg = ARRAY_SIZE(migor_lcd_modes), 264 .num_modes = ARRAY_SIZE(migor_lcd_modes),
265 .panel_cfg = { 265 .panel_cfg = {
266 .width = 49, /* 2.4 inch */ 266 .width = 49, /* 2.4 inch */
267 .height = 37, 267 .height = 37,
diff --git a/arch/sh/boards/mach-se/7724/setup.c b/arch/sh/boards/mach-se/7724/setup.c
index a468398bfb34..9bf528b4ae21 100644
--- a/arch/sh/boards/mach-se/7724/setup.c
+++ b/arch/sh/boards/mach-se/7724/setup.c
@@ -886,12 +886,12 @@ static int __init devices_setup(void)
886 886
887 if (sw & SW41_B) { 887 if (sw & SW41_B) {
888 /* 720p */ 888 /* 720p */
889 lcdc_info.ch[0].lcd_cfg = lcdc_720p_modes; 889 lcdc_info.ch[0].lcd_modes = lcdc_720p_modes;
890 lcdc_info.ch[0].num_cfg = ARRAY_SIZE(lcdc_720p_modes); 890 lcdc_info.ch[0].num_modes = ARRAY_SIZE(lcdc_720p_modes);
891 } else { 891 } else {
892 /* VGA */ 892 /* VGA */
893 lcdc_info.ch[0].lcd_cfg = lcdc_vga_modes; 893 lcdc_info.ch[0].lcd_modes = lcdc_vga_modes;
894 lcdc_info.ch[0].num_cfg = ARRAY_SIZE(lcdc_vga_modes); 894 lcdc_info.ch[0].num_modes = ARRAY_SIZE(lcdc_vga_modes);
895 } 895 }
896 896
897 if (sw & SW41_A) { 897 if (sw & SW41_A) {
diff --git a/drivers/video/sh_mipi_dsi.c b/drivers/video/sh_mipi_dsi.c
index 5ff3742aeb08..42ad0f707e88 100644
--- a/drivers/video/sh_mipi_dsi.c
+++ b/drivers/video/sh_mipi_dsi.c
@@ -147,77 +147,77 @@ static int __init sh_mipi_setup(struct sh_mipi *mipi,
147 pctype = 0; 147 pctype = 0;
148 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_24; 148 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_24;
149 pixfmt = MIPI_DCS_PIXEL_FMT_24BIT; 149 pixfmt = MIPI_DCS_PIXEL_FMT_24BIT;
150 linelength = ch->lcd_cfg[0].xres * 3; 150 linelength = ch->lcd_modes[0].xres * 3;
151 yuv = false; 151 yuv = false;
152 break; 152 break;
153 case MIPI_RGB565: 153 case MIPI_RGB565:
154 pctype = 1; 154 pctype = 1;
155 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_16; 155 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_16;
156 pixfmt = MIPI_DCS_PIXEL_FMT_16BIT; 156 pixfmt = MIPI_DCS_PIXEL_FMT_16BIT;
157 linelength = ch->lcd_cfg[0].xres * 2; 157 linelength = ch->lcd_modes[0].xres * 2;
158 yuv = false; 158 yuv = false;
159 break; 159 break;
160 case MIPI_RGB666_LP: 160 case MIPI_RGB666_LP:
161 pctype = 2; 161 pctype = 2;
162 datatype = MIPI_DSI_PIXEL_STREAM_3BYTE_18; 162 datatype = MIPI_DSI_PIXEL_STREAM_3BYTE_18;
163 pixfmt = MIPI_DCS_PIXEL_FMT_24BIT; 163 pixfmt = MIPI_DCS_PIXEL_FMT_24BIT;
164 linelength = ch->lcd_cfg[0].xres * 3; 164 linelength = ch->lcd_modes[0].xres * 3;
165 yuv = false; 165 yuv = false;
166 break; 166 break;
167 case MIPI_RGB666: 167 case MIPI_RGB666:
168 pctype = 3; 168 pctype = 3;
169 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_18; 169 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_18;
170 pixfmt = MIPI_DCS_PIXEL_FMT_18BIT; 170 pixfmt = MIPI_DCS_PIXEL_FMT_18BIT;
171 linelength = (ch->lcd_cfg[0].xres * 18 + 7) / 8; 171 linelength = (ch->lcd_modes[0].xres * 18 + 7) / 8;
172 yuv = false; 172 yuv = false;
173 break; 173 break;
174 case MIPI_BGR888: 174 case MIPI_BGR888:
175 pctype = 8; 175 pctype = 8;
176 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_24; 176 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_24;
177 pixfmt = MIPI_DCS_PIXEL_FMT_24BIT; 177 pixfmt = MIPI_DCS_PIXEL_FMT_24BIT;
178 linelength = ch->lcd_cfg[0].xres * 3; 178 linelength = ch->lcd_modes[0].xres * 3;
179 yuv = false; 179 yuv = false;
180 break; 180 break;
181 case MIPI_BGR565: 181 case MIPI_BGR565:
182 pctype = 9; 182 pctype = 9;
183 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_16; 183 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_16;
184 pixfmt = MIPI_DCS_PIXEL_FMT_16BIT; 184 pixfmt = MIPI_DCS_PIXEL_FMT_16BIT;
185 linelength = ch->lcd_cfg[0].xres * 2; 185 linelength = ch->lcd_modes[0].xres * 2;
186 yuv = false; 186 yuv = false;
187 break; 187 break;
188 case MIPI_BGR666_LP: 188 case MIPI_BGR666_LP:
189 pctype = 0xa; 189 pctype = 0xa;
190 datatype = MIPI_DSI_PIXEL_STREAM_3BYTE_18; 190 datatype = MIPI_DSI_PIXEL_STREAM_3BYTE_18;
191 pixfmt = MIPI_DCS_PIXEL_FMT_24BIT; 191 pixfmt = MIPI_DCS_PIXEL_FMT_24BIT;
192 linelength = ch->lcd_cfg[0].xres * 3; 192 linelength = ch->lcd_modes[0].xres * 3;
193 yuv = false; 193 yuv = false;
194 break; 194 break;
195 case MIPI_BGR666: 195 case MIPI_BGR666:
196 pctype = 0xb; 196 pctype = 0xb;
197 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_18; 197 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_18;
198 pixfmt = MIPI_DCS_PIXEL_FMT_18BIT; 198 pixfmt = MIPI_DCS_PIXEL_FMT_18BIT;
199 linelength = (ch->lcd_cfg[0].xres * 18 + 7) / 8; 199 linelength = (ch->lcd_modes[0].xres * 18 + 7) / 8;
200 yuv = false; 200 yuv = false;
201 break; 201 break;
202 case MIPI_YUYV: 202 case MIPI_YUYV:
203 pctype = 4; 203 pctype = 4;
204 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_YCBCR16; 204 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_YCBCR16;
205 pixfmt = MIPI_DCS_PIXEL_FMT_16BIT; 205 pixfmt = MIPI_DCS_PIXEL_FMT_16BIT;
206 linelength = ch->lcd_cfg[0].xres * 2; 206 linelength = ch->lcd_modes[0].xres * 2;
207 yuv = true; 207 yuv = true;
208 break; 208 break;
209 case MIPI_UYVY: 209 case MIPI_UYVY:
210 pctype = 5; 210 pctype = 5;
211 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_YCBCR16; 211 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_YCBCR16;
212 pixfmt = MIPI_DCS_PIXEL_FMT_16BIT; 212 pixfmt = MIPI_DCS_PIXEL_FMT_16BIT;
213 linelength = ch->lcd_cfg[0].xres * 2; 213 linelength = ch->lcd_modes[0].xres * 2;
214 yuv = true; 214 yuv = true;
215 break; 215 break;
216 case MIPI_YUV420_L: 216 case MIPI_YUV420_L:
217 pctype = 6; 217 pctype = 6;
218 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_YCBCR12; 218 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_YCBCR12;
219 pixfmt = MIPI_DCS_PIXEL_FMT_12BIT; 219 pixfmt = MIPI_DCS_PIXEL_FMT_12BIT;
220 linelength = (ch->lcd_cfg[0].xres * 12 + 7) / 8; 220 linelength = (ch->lcd_modes[0].xres * 12 + 7) / 8;
221 yuv = true; 221 yuv = true;
222 break; 222 break;
223 case MIPI_YUV420: 223 case MIPI_YUV420:
@@ -225,7 +225,7 @@ static int __init sh_mipi_setup(struct sh_mipi *mipi,
225 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_YCBCR12; 225 datatype = MIPI_DSI_PACKED_PIXEL_STREAM_YCBCR12;
226 pixfmt = MIPI_DCS_PIXEL_FMT_12BIT; 226 pixfmt = MIPI_DCS_PIXEL_FMT_12BIT;
227 /* Length of U/V line */ 227 /* Length of U/V line */
228 linelength = (ch->lcd_cfg[0].xres + 1) / 2; 228 linelength = (ch->lcd_modes[0].xres + 1) / 2;
229 yuv = true; 229 yuv = true;
230 break; 230 break;
231 default: 231 default:
@@ -294,7 +294,7 @@ static int __init sh_mipi_setup(struct sh_mipi *mipi,
294 */ 294 */
295 iowrite32(0x00000006, mipi->linkbase + DTCTR); 295 iowrite32(0x00000006, mipi->linkbase + DTCTR);
296 /* VSYNC width = 2 (<< 17) */ 296 /* VSYNC width = 2 (<< 17) */
297 iowrite32((ch->lcd_cfg[0].vsync_len << pdata->vsynw_offset) | 297 iowrite32((ch->lcd_modes[0].vsync_len << pdata->vsynw_offset) |
298 (pdata->clksrc << 16) | (pctype << 12) | datatype, 298 (pdata->clksrc << 16) | (pctype << 12) | datatype,
299 mipi->linkbase + VMCTR1); 299 mipi->linkbase + VMCTR1);
300 300
@@ -328,7 +328,7 @@ static int __init sh_mipi_setup(struct sh_mipi *mipi,
328 top = linelength << 16; /* RGBLEN */ 328 top = linelength << 16; /* RGBLEN */
329 bottom = 0x00000001; 329 bottom = 0x00000001;
330 if (pdata->flags & SH_MIPI_DSI_HSABM) /* HSALEN */ 330 if (pdata->flags & SH_MIPI_DSI_HSABM) /* HSALEN */
331 bottom = (pdata->lane * ch->lcd_cfg[0].hsync_len) - 10; 331 bottom = (pdata->lane * ch->lcd_modes[0].hsync_len) - 10;
332 iowrite32(top | bottom , mipi->linkbase + VMLEN1); 332 iowrite32(top | bottom , mipi->linkbase + VMLEN1);
333 333
334 /* 334 /*
@@ -348,18 +348,18 @@ static int __init sh_mipi_setup(struct sh_mipi *mipi,
348 div = 2; 348 div = 2;
349 349
350 if (pdata->flags & SH_MIPI_DSI_HFPBM) { /* HBPLEN */ 350 if (pdata->flags & SH_MIPI_DSI_HFPBM) { /* HBPLEN */
351 top = ch->lcd_cfg[0].hsync_len + ch->lcd_cfg[0].left_margin; 351 top = ch->lcd_modes[0].hsync_len + ch->lcd_modes[0].left_margin;
352 top = ((pdata->lane * top / div) - 10) << 16; 352 top = ((pdata->lane * top / div) - 10) << 16;
353 } 353 }
354 if (pdata->flags & SH_MIPI_DSI_HBPBM) { /* HFPLEN */ 354 if (pdata->flags & SH_MIPI_DSI_HBPBM) { /* HFPLEN */
355 bottom = ch->lcd_cfg[0].right_margin; 355 bottom = ch->lcd_modes[0].right_margin;
356 bottom = (pdata->lane * bottom / div) - 12; 356 bottom = (pdata->lane * bottom / div) - 12;
357 } 357 }
358 358
359 bpp = linelength / ch->lcd_cfg[0].xres; /* byte / pixel */ 359 bpp = linelength / ch->lcd_modes[0].xres; /* byte / pixel */
360 if ((pdata->lane / div) > bpp) { 360 if ((pdata->lane / div) > bpp) {
361 tmp = ch->lcd_cfg[0].xres / bpp; /* output cycle */ 361 tmp = ch->lcd_modes[0].xres / bpp; /* output cycle */
362 tmp = ch->lcd_cfg[0].xres - tmp; /* (input - output) cycle */ 362 tmp = ch->lcd_modes[0].xres - tmp; /* (input - output) cycle */
363 delay = (pdata->lane * tmp); 363 delay = (pdata->lane * tmp);
364 } 364 }
365 365
diff --git a/drivers/video/sh_mobile_lcdcfb.c b/drivers/video/sh_mobile_lcdcfb.c
index 422fcfd3cf28..ab7b17975846 100644
--- a/drivers/video/sh_mobile_lcdcfb.c
+++ b/drivers/video/sh_mobile_lcdcfb.c
@@ -1191,8 +1191,8 @@ static int sh_mobile_check_var(struct fb_var_screeninfo *var, struct fb_info *in
1191 * distance between two modes is defined as the size of the 1191 * distance between two modes is defined as the size of the
1192 * non-overlapping parts of the two rectangles. 1192 * non-overlapping parts of the two rectangles.
1193 */ 1193 */
1194 for (i = 0; i < ch->cfg.num_cfg; ++i) { 1194 for (i = 0; i < ch->cfg.num_modes; ++i) {
1195 const struct fb_videomode *mode = &ch->cfg.lcd_cfg[i]; 1195 const struct fb_videomode *mode = &ch->cfg.lcd_modes[i];
1196 unsigned int dist; 1196 unsigned int dist;
1197 1197
1198 /* We can only round up. */ 1198 /* We can only round up. */
@@ -1211,7 +1211,7 @@ static int sh_mobile_check_var(struct fb_var_screeninfo *var, struct fb_info *in
1211 } 1211 }
1212 1212
1213 /* If no available mode can be used, return an error. */ 1213 /* If no available mode can be used, return an error. */
1214 if (ch->cfg.num_cfg != 0) { 1214 if (ch->cfg.num_modes != 0) {
1215 if (best_dist == (unsigned int)-1) 1215 if (best_dist == (unsigned int)-1)
1216 return -EINVAL; 1216 return -EINVAL;
1217 1217
@@ -1671,7 +1671,7 @@ sh_mobile_lcdc_channel_init(struct sh_mobile_lcdc_priv *priv,
1671 struct fb_var_screeninfo *var; 1671 struct fb_var_screeninfo *var;
1672 struct fb_info *info; 1672 struct fb_info *info;
1673 unsigned int max_size; 1673 unsigned int max_size;
1674 int num_cfg; 1674 int num_modes;
1675 void *buf; 1675 void *buf;
1676 int ret; 1676 int ret;
1677 int i; 1677 int i;
@@ -1698,7 +1698,7 @@ sh_mobile_lcdc_channel_init(struct sh_mobile_lcdc_priv *priv,
1698 max_mode = NULL; 1698 max_mode = NULL;
1699 max_size = 0; 1699 max_size = 0;
1700 1700
1701 for (i = 0, mode = cfg->lcd_cfg; i < cfg->num_cfg; i++, mode++) { 1701 for (i = 0, mode = cfg->lcd_modes; i < cfg->num_modes; i++, mode++) {
1702 unsigned int size = mode->yres * mode->xres; 1702 unsigned int size = mode->yres * mode->xres;
1703 1703
1704 /* NV12/NV21 buffers must have even number of lines */ 1704 /* NV12/NV21 buffers must have even number of lines */
@@ -1722,15 +1722,15 @@ sh_mobile_lcdc_channel_init(struct sh_mobile_lcdc_priv *priv,
1722 max_mode->xres, max_mode->yres); 1722 max_mode->xres, max_mode->yres);
1723 1723
1724 /* Create the mode list. */ 1724 /* Create the mode list. */
1725 if (cfg->lcd_cfg == NULL) { 1725 if (cfg->lcd_modes == NULL) {
1726 mode = &default_720p; 1726 mode = &default_720p;
1727 num_cfg = 1; 1727 num_modes = 1;
1728 } else { 1728 } else {
1729 mode = cfg->lcd_cfg; 1729 mode = cfg->lcd_modes;
1730 num_cfg = cfg->num_cfg; 1730 num_modes = cfg->num_modes;
1731 } 1731 }
1732 1732
1733 fb_videomode_to_modelist(mode, num_cfg, &info->modelist); 1733 fb_videomode_to_modelist(mode, num_modes, &info->modelist);
1734 1734
1735 /* Initialize the transmitter device if present. */ 1735 /* Initialize the transmitter device if present. */
1736 if (cfg->tx_dev) { 1736 if (cfg->tx_dev) {
diff --git a/include/video/sh_mobile_lcdc.h b/include/video/sh_mobile_lcdc.h
index 4f0fb559ea87..484b0a2d7b2f 100644
--- a/include/video/sh_mobile_lcdc.h
+++ b/include/video/sh_mobile_lcdc.h
@@ -173,8 +173,8 @@ struct sh_mobile_lcdc_chan_cfg {
173 int interface_type; /* selects RGBn or SYSn I/F, see above */ 173 int interface_type; /* selects RGBn or SYSn I/F, see above */
174 int clock_divider; 174 int clock_divider;
175 unsigned long flags; /* LCDC_FLAGS_... */ 175 unsigned long flags; /* LCDC_FLAGS_... */
176 const struct fb_videomode *lcd_cfg; 176 const struct fb_videomode *lcd_modes;
177 int num_cfg; 177 int num_modes;
178 struct sh_mobile_lcdc_panel_cfg panel_cfg; 178 struct sh_mobile_lcdc_panel_cfg panel_cfg;
179 struct sh_mobile_lcdc_bl_info bl_info; 179 struct sh_mobile_lcdc_bl_info bl_info;
180 struct sh_mobile_lcdc_sys_bus_cfg sys_bus_cfg; /* only for SYSn I/F */ 180 struct sh_mobile_lcdc_sys_bus_cfg sys_bus_cfg; /* only for SYSn I/F */