mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-26 02:39:48 +00:00
drm/exynos: support extended screen coordinate of fimd
The fimd of exynos5 SoC supports extended screen coordinate. Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com>
This commit is contained in:
parent
f56aad3a69
commit
ca555e5ab7
1 changed files with 12 additions and 4 deletions
|
@ -243,7 +243,9 @@ static void fimd_commit(struct device *dev)
|
||||||
|
|
||||||
/* setup horizontal and vertical display size. */
|
/* setup horizontal and vertical display size. */
|
||||||
val = VIDTCON2_LINEVAL(timing->yres - 1) |
|
val = VIDTCON2_LINEVAL(timing->yres - 1) |
|
||||||
VIDTCON2_HOZVAL(timing->xres - 1);
|
VIDTCON2_HOZVAL(timing->xres - 1) |
|
||||||
|
VIDTCON2_LINEVAL_E(timing->yres - 1) |
|
||||||
|
VIDTCON2_HOZVAL_E(timing->xres - 1);
|
||||||
writel(val, ctx->regs + driver_data->timing_base + VIDTCON2);
|
writel(val, ctx->regs + driver_data->timing_base + VIDTCON2);
|
||||||
|
|
||||||
/* setup clock source, clock divider, enable dma. */
|
/* setup clock source, clock divider, enable dma. */
|
||||||
|
@ -518,12 +520,16 @@ static void fimd_win_commit(struct device *dev, int zpos)
|
||||||
|
|
||||||
/* buffer size */
|
/* buffer size */
|
||||||
val = VIDW_BUF_SIZE_OFFSET(win_data->buf_offsize) |
|
val = VIDW_BUF_SIZE_OFFSET(win_data->buf_offsize) |
|
||||||
VIDW_BUF_SIZE_PAGEWIDTH(win_data->line_size);
|
VIDW_BUF_SIZE_PAGEWIDTH(win_data->line_size) |
|
||||||
|
VIDW_BUF_SIZE_OFFSET_E(win_data->buf_offsize) |
|
||||||
|
VIDW_BUF_SIZE_PAGEWIDTH_E(win_data->line_size);
|
||||||
writel(val, ctx->regs + VIDWx_BUF_SIZE(win, 0));
|
writel(val, ctx->regs + VIDWx_BUF_SIZE(win, 0));
|
||||||
|
|
||||||
/* OSD position */
|
/* OSD position */
|
||||||
val = VIDOSDxA_TOPLEFT_X(win_data->offset_x) |
|
val = VIDOSDxA_TOPLEFT_X(win_data->offset_x) |
|
||||||
VIDOSDxA_TOPLEFT_Y(win_data->offset_y);
|
VIDOSDxA_TOPLEFT_Y(win_data->offset_y) |
|
||||||
|
VIDOSDxA_TOPLEFT_X_E(win_data->offset_x) |
|
||||||
|
VIDOSDxA_TOPLEFT_Y_E(win_data->offset_y);
|
||||||
writel(val, ctx->regs + VIDOSD_A(win));
|
writel(val, ctx->regs + VIDOSD_A(win));
|
||||||
|
|
||||||
last_x = win_data->offset_x + win_data->ovl_width;
|
last_x = win_data->offset_x + win_data->ovl_width;
|
||||||
|
@ -533,7 +539,9 @@ static void fimd_win_commit(struct device *dev, int zpos)
|
||||||
if (last_y)
|
if (last_y)
|
||||||
last_y--;
|
last_y--;
|
||||||
|
|
||||||
val = VIDOSDxB_BOTRIGHT_X(last_x) | VIDOSDxB_BOTRIGHT_Y(last_y);
|
val = VIDOSDxB_BOTRIGHT_X(last_x) | VIDOSDxB_BOTRIGHT_Y(last_y) |
|
||||||
|
VIDOSDxB_BOTRIGHT_X_E(last_x) | VIDOSDxB_BOTRIGHT_Y_E(last_y);
|
||||||
|
|
||||||
writel(val, ctx->regs + VIDOSD_B(win));
|
writel(val, ctx->regs + VIDOSD_B(win));
|
||||||
|
|
||||||
DRM_DEBUG_KMS("osd pos: tx = %d, ty = %d, bx = %d, by = %d\n",
|
DRM_DEBUG_KMS("osd pos: tx = %d, ty = %d, bx = %d, by = %d\n",
|
||||||
|
|
Loading…
Reference in a new issue