Hi All.
This patch set fixed some issue and cleanup code. please check my commit and let me know about your comment.
- This patch set fixes the following: * fixed vflip, hflip case at the same time: we use vflip, hflip set at the same time for 180 degree supporting. so, we added this case. * fixed warnning in GSC build: we don't use directly readl, but this code remained. so, we changed it. * fixed unnormal interrupt in m2m operation : m2m operation called reset function at every time. but we don't disable dma start. so, we added dma stop and capture stop operation.
- And code clean like bellow: * cleanup current command name : we use 'cmd' in property structure and so on. so, this naming make some confusion. we changed 'cmd' to 'c_node' for avoid confusion. * removed error handling about property : property could't be NULL. so, we removed error handling about NULL. * cleanup comment of abbreviation : we changed comments for right grammar. * cleanup needless parenthesis : we missed changing of fimc side. so, I added it. * removed color bar pattern display : we don't use color display at writeback. so, removed it.
Thank's BR Eunchul Kim
Eunchul Kim (6): drm/exynos: cleanup current command name. drm/exynos: removed needless error handling about property. drm/exynos: fixed vflip, hflip case at the same time. drm/exynos: fixed warnning in GSC build. drm/exynos: cleanup comment of abbreviation. drm/exynos: cleanup needless parenthesis.
Jinyoung Jeon (1): drm/exynos: fixed unnormal interrupt in m2m operation.
JoongMock Shin (1): drm/exynos: removed color bar pattern display.
drivers/gpu/drm/exynos/exynos_drm_fimc.c | 47 +++++++++++++-------------- drivers/gpu/drm/exynos/exynos_drm_gsc.c | 24 +++---------- drivers/gpu/drm/exynos/exynos_drm_ipp.c | 13 ++----- drivers/gpu/drm/exynos/exynos_drm_ipp.h | 4 +- drivers/gpu/drm/exynos/exynos_drm_rotator.c | 3 +- 5 files changed, 37 insertions(+), 54 deletions(-)
This patch changed current command name from cmd to c_node. because we already use cmd for command control ioctl in another structure. so, this name make some confusion.
Signed-off-by: Eunchul Kim chulspro.kim@samsung.com --- drivers/gpu/drm/exynos/exynos_drm_fimc.c | 8 ++++---- drivers/gpu/drm/exynos/exynos_drm_gsc.c | 8 ++++---- drivers/gpu/drm/exynos/exynos_drm_ipp.c | 6 +++--- drivers/gpu/drm/exynos/exynos_drm_ipp.h | 4 ++-- drivers/gpu/drm/exynos/exynos_drm_rotator.c | 2 +- 5 files changed, 14 insertions(+), 14 deletions(-)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c b/drivers/gpu/drm/exynos/exynos_drm_fimc.c index 61ea242..7a3e460 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c @@ -695,7 +695,7 @@ static int fimc_src_set_addr(struct device *dev, { struct fimc_context *ctx = get_fimc_context(dev); struct exynos_drm_ippdrv *ippdrv = &ctx->ippdrv; - struct drm_exynos_ipp_cmd_node *c_node = ippdrv->cmd; + struct drm_exynos_ipp_cmd_node *c_node = ippdrv->c_node; struct drm_exynos_ipp_property *property; struct drm_exynos_ipp_config *config;
@@ -1231,7 +1231,7 @@ static int fimc_dst_set_addr(struct device *dev, { struct fimc_context *ctx = get_fimc_context(dev); struct exynos_drm_ippdrv *ippdrv = &ctx->ippdrv; - struct drm_exynos_ipp_cmd_node *c_node = ippdrv->cmd; + struct drm_exynos_ipp_cmd_node *c_node = ippdrv->c_node; struct drm_exynos_ipp_property *property; struct drm_exynos_ipp_config *config;
@@ -1317,7 +1317,7 @@ static irqreturn_t fimc_irq_handler(int irq, void *dev_id) { struct fimc_context *ctx = dev_id; struct exynos_drm_ippdrv *ippdrv = &ctx->ippdrv; - struct drm_exynos_ipp_cmd_node *c_node = ippdrv->cmd; + struct drm_exynos_ipp_cmd_node *c_node = ippdrv->c_node; struct drm_exynos_ipp_event_work *event_work = c_node->event_work; int buf_id; @@ -1557,7 +1557,7 @@ static int fimc_ippdrv_start(struct device *dev, enum drm_exynos_ipp_cmd cmd) { struct fimc_context *ctx = get_fimc_context(dev); struct exynos_drm_ippdrv *ippdrv = &ctx->ippdrv; - struct drm_exynos_ipp_cmd_node *c_node = ippdrv->cmd; + struct drm_exynos_ipp_cmd_node *c_node = ippdrv->c_node; struct drm_exynos_ipp_property *property; struct drm_exynos_ipp_config *config; struct drm_exynos_pos img_pos[EXYNOS_DRM_OPS_MAX]; diff --git a/drivers/gpu/drm/exynos/exynos_drm_gsc.c b/drivers/gpu/drm/exynos/exynos_drm_gsc.c index 5639353..c443c3b 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_gsc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_gsc.c @@ -711,7 +711,7 @@ static int gsc_src_set_addr(struct device *dev, { struct gsc_context *ctx = get_gsc_context(dev); struct exynos_drm_ippdrv *ippdrv = &ctx->ippdrv; - struct drm_exynos_ipp_cmd_node *c_node = ippdrv->cmd; + struct drm_exynos_ipp_cmd_node *c_node = ippdrv->c_node; struct drm_exynos_ipp_property *property;
if (!c_node) { @@ -1171,7 +1171,7 @@ static int gsc_dst_set_addr(struct device *dev, { struct gsc_context *ctx = get_gsc_context(dev); struct exynos_drm_ippdrv *ippdrv = &ctx->ippdrv; - struct drm_exynos_ipp_cmd_node *c_node = ippdrv->cmd; + struct drm_exynos_ipp_cmd_node *c_node = ippdrv->c_node; struct drm_exynos_ipp_property *property;
if (!c_node) { @@ -1312,7 +1312,7 @@ static irqreturn_t gsc_irq_handler(int irq, void *dev_id) { struct gsc_context *ctx = dev_id; struct exynos_drm_ippdrv *ippdrv = &ctx->ippdrv; - struct drm_exynos_ipp_cmd_node *c_node = ippdrv->cmd; + struct drm_exynos_ipp_cmd_node *c_node = ippdrv->c_node; struct drm_exynos_ipp_event_work *event_work = c_node->event_work; u32 status; @@ -1549,7 +1549,7 @@ static int gsc_ippdrv_start(struct device *dev, enum drm_exynos_ipp_cmd cmd) { struct gsc_context *ctx = get_gsc_context(dev); struct exynos_drm_ippdrv *ippdrv = &ctx->ippdrv; - struct drm_exynos_ipp_cmd_node *c_node = ippdrv->cmd; + struct drm_exynos_ipp_cmd_node *c_node = ippdrv->c_node; struct drm_exynos_ipp_property *property; struct drm_exynos_ipp_config *config; struct drm_exynos_pos img_pos[EXYNOS_DRM_OPS_MAX]; diff --git a/drivers/gpu/drm/exynos/exynos_drm_ipp.c b/drivers/gpu/drm/exynos/exynos_drm_ipp.c index 49eebe9..ba45f9a 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_ipp.c +++ b/drivers/gpu/drm/exynos/exynos_drm_ipp.c @@ -1292,7 +1292,7 @@ static int ipp_start_property(struct exynos_drm_ippdrv *ippdrv, DRM_DEBUG_KMS("%s:prop_id[%d]\n", __func__, property->prop_id);
/* store command info in ippdrv */ - ippdrv->cmd = c_node; + ippdrv->c_node = c_node;
if (!ipp_check_mem_list(c_node)) { DRM_DEBUG_KMS("%s:empty memory.\n", __func__); @@ -1303,7 +1303,7 @@ static int ipp_start_property(struct exynos_drm_ippdrv *ippdrv, ret = ipp_set_property(ippdrv, property); if (ret) { DRM_ERROR("failed to set property.\n"); - ippdrv->cmd = NULL; + ippdrv->c_node = NULL; return ret; }
@@ -1704,7 +1704,7 @@ void ipp_sched_event(struct work_struct *work) return; }
- c_node = ippdrv->cmd; + c_node = ippdrv->c_node; if (!c_node) { DRM_ERROR("failed to get command node.\n"); return; diff --git a/drivers/gpu/drm/exynos/exynos_drm_ipp.h b/drivers/gpu/drm/exynos/exynos_drm_ipp.h index 28ffac9..5e5a0d6 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_ipp.h +++ b/drivers/gpu/drm/exynos/exynos_drm_ipp.h @@ -160,7 +160,7 @@ struct exynos_drm_ipp_ops { * @dedicated: dedicated ipp device. * @ops: source, destination operations. * @event_workq: event work queue. - * @cmd: current command information. + * @c_node: current command information. * @cmd_list: list head for command information. * @prop_list: property informations of current ipp driver. * @check_property: check property about format, size, buffer. @@ -178,7 +178,7 @@ struct exynos_drm_ippdrv { bool dedicated; struct exynos_drm_ipp_ops *ops[EXYNOS_DRM_OPS_MAX]; struct workqueue_struct *event_workq; - struct drm_exynos_ipp_cmd_node *cmd; + struct drm_exynos_ipp_cmd_node *c_node; struct list_head cmd_list; struct drm_exynos_ipp_prop_list *prop_list;
diff --git a/drivers/gpu/drm/exynos/exynos_drm_rotator.c b/drivers/gpu/drm/exynos/exynos_drm_rotator.c index 1c23660..17e4474 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_rotator.c +++ b/drivers/gpu/drm/exynos/exynos_drm_rotator.c @@ -139,7 +139,7 @@ static irqreturn_t rotator_irq_handler(int irq, void *arg) { struct rot_context *rot = arg; struct exynos_drm_ippdrv *ippdrv = &rot->ippdrv; - struct drm_exynos_ipp_cmd_node *c_node = ippdrv->cmd; + struct drm_exynos_ipp_cmd_node *c_node = ippdrv->c_node; struct drm_exynos_ipp_event_work *event_work = c_node->event_work; enum rot_irq_status irq_status; u32 val;
This patch removed property error handling. property couldn't be NULL. so, I removed it.
Signed-off-by: Eunchul Kim chulspro.kim@samsung.com --- drivers/gpu/drm/exynos/exynos_drm_fimc.c | 12 ------------ drivers/gpu/drm/exynos/exynos_drm_gsc.c | 12 ------------ drivers/gpu/drm/exynos/exynos_drm_ipp.c | 5 ----- 3 files changed, 0 insertions(+), 29 deletions(-)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c b/drivers/gpu/drm/exynos/exynos_drm_fimc.c index 7a3e460..5dc0251 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c @@ -705,10 +705,6 @@ static int fimc_src_set_addr(struct device *dev, }
property = &c_node->property; - if (!property) { - DRM_ERROR("failed to get property.\n"); - return -EINVAL; - }
DRM_DEBUG_KMS("%s:prop_id[%d]buf_id[%d]buf_type[%d]\n", __func__, property->prop_id, buf_id, buf_type); @@ -1241,10 +1237,6 @@ static int fimc_dst_set_addr(struct device *dev, }
property = &c_node->property; - if (!property) { - DRM_ERROR("failed to get property.\n"); - return -EINVAL; - }
DRM_DEBUG_KMS("%s:prop_id[%d]buf_id[%d]buf_type[%d]\n", __func__, property->prop_id, buf_id, buf_type); @@ -1573,10 +1565,6 @@ static int fimc_ippdrv_start(struct device *dev, enum drm_exynos_ipp_cmd cmd) }
property = &c_node->property; - if (!property) { - DRM_ERROR("failed to get property.\n"); - return -EINVAL; - }
fimc_handle_irq(ctx, true, false, true);
diff --git a/drivers/gpu/drm/exynos/exynos_drm_gsc.c b/drivers/gpu/drm/exynos/exynos_drm_gsc.c index c443c3b..ba5fefd 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_gsc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_gsc.c @@ -720,10 +720,6 @@ static int gsc_src_set_addr(struct device *dev, }
property = &c_node->property; - if (!property) { - DRM_ERROR("failed to get property.\n"); - return -EFAULT; - }
DRM_DEBUG_KMS("%s:prop_id[%d]buf_id[%d]buf_type[%d]\n", __func__, property->prop_id, buf_id, buf_type); @@ -1180,10 +1176,6 @@ static int gsc_dst_set_addr(struct device *dev, }
property = &c_node->property; - if (!property) { - DRM_ERROR("failed to get property.\n"); - return -EFAULT; - }
DRM_DEBUG_KMS("%s:prop_id[%d]buf_id[%d]buf_type[%d]\n", __func__, property->prop_id, buf_id, buf_type); @@ -1565,10 +1557,6 @@ static int gsc_ippdrv_start(struct device *dev, enum drm_exynos_ipp_cmd cmd) }
property = &c_node->property; - if (!property) { - DRM_ERROR("failed to get property.\n"); - return -EINVAL; - }
gsc_handle_irq(ctx, true, false, true);
diff --git a/drivers/gpu/drm/exynos/exynos_drm_ipp.c b/drivers/gpu/drm/exynos/exynos_drm_ipp.c index ba45f9a..cac94fe 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_ipp.c +++ b/drivers/gpu/drm/exynos/exynos_drm_ipp.c @@ -1487,11 +1487,6 @@ void ipp_sched_cmd(struct work_struct *work) mutex_lock(&c_node->cmd_lock);
property = &c_node->property; - if (!property) { - DRM_ERROR("failed to get property:prop_id[%d]\n", - c_node->property.prop_id); - goto err_unlock; - }
switch (cmd_work->ctrl) { case IPP_CTRL_PLAY:
This patch fixed vflip, hflip at the same time. If we want to change 180 degree about buffer, then we can use h,vflip or 180 degree. we supports 180 degree using h,vflip. but we make error handling in this case. so, fixed it.
Signed-off-by: Eunchul Kim chulspro.kim@samsung.com --- drivers/gpu/drm/exynos/exynos_drm_fimc.c | 1 + drivers/gpu/drm/exynos/exynos_drm_rotator.c | 1 + 2 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c b/drivers/gpu/drm/exynos/exynos_drm_fimc.c index 5dc0251..4c4078c 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c @@ -1387,6 +1387,7 @@ static inline bool fimc_check_drm_flip(enum drm_exynos_flip flip) case EXYNOS_DRM_FLIP_NONE: case EXYNOS_DRM_FLIP_VERTICAL: case EXYNOS_DRM_FLIP_HORIZONTAL: + case EXYNOS_DRM_FLIP_VERTICAL | EXYNOS_DRM_FLIP_HORIZONTAL: return true; default: DRM_DEBUG_KMS("%s:invalid flip\n", __func__); diff --git a/drivers/gpu/drm/exynos/exynos_drm_rotator.c b/drivers/gpu/drm/exynos/exynos_drm_rotator.c index 17e4474..09830ad 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_rotator.c +++ b/drivers/gpu/drm/exynos/exynos_drm_rotator.c @@ -513,6 +513,7 @@ static inline bool rotator_check_drm_flip(enum drm_exynos_flip flip) case EXYNOS_DRM_FLIP_NONE: case EXYNOS_DRM_FLIP_VERTICAL: case EXYNOS_DRM_FLIP_HORIZONTAL: + case EXYNOS_DRM_FLIP_VERTICAL | EXYNOS_DRM_FLIP_HORIZONTAL: return true; default: DRM_DEBUG_KMS("%s:invalid flip\n", __func__);
-----Original Message----- From: Eunchul Kim [mailto:chulspro.kim@samsung.com] Sent: Thursday, December 20, 2012 6:32 PM To: dri-devel@lists.freedesktop.org; inki.dae@samsung.com Cc: jy0.jeon@samsung.com; yj44.cho@samsung.com; jmock.shin@samsung.com; jaejoon.seo@samsung.com; kyungmin.park@samsung.com; jy0922.shim@samsung.com; sw0312.kim@samsung.com; th908.kim@samsung.com; lsmin.lee@samsung.com; chulspro.kim@samsung.com Subject: [PATCH 3/8] drm/exynos: fixed vflip, hflip case at the same time.
This patch fixed vflip, hflip at the same time. If we want to change 180 degree about buffer, then we can use h,vflip or 180 degree. we supports 180 degree using h,vflip. but we make error handling in this case. so, fixed it.
Signed-off-by: Eunchul Kim chulspro.kim@samsung.com
drivers/gpu/drm/exynos/exynos_drm_fimc.c | 1 + drivers/gpu/drm/exynos/exynos_drm_rotator.c | 1 + 2 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c b/drivers/gpu/drm/exynos/exynos_drm_fimc.c index 5dc0251..4c4078c 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c @@ -1387,6 +1387,7 @@ static inline bool fimc_check_drm_flip(enum drm_exynos_flip flip) case EXYNOS_DRM_FLIP_NONE: case EXYNOS_DRM_FLIP_VERTICAL: case EXYNOS_DRM_FLIP_HORIZONTAL:
- case EXYNOS_DRM_FLIP_VERTICAL | EXYNOS_DRM_FLIP_HORIZONTAL:
This code induces build warning because the value of 'VERTICAL | HORIZONTAL' is out of range. Add a new enumeration value to enum drm_exynos_flip. i.e. EXYNOS_DRM_FLIP_BOTH = EXYNOS_DRM_FLIP_VERTICAL | EXYNOS_DRM_FLIP_HORIZONTAL and use it.
return true;
default: DRM_DEBUG_KMS("%s:invalid flip\n", __func__); diff --git a/drivers/gpu/drm/exynos/exynos_drm_rotator.c b/drivers/gpu/drm/exynos/exynos_drm_rotator.c index 17e4474..09830ad 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_rotator.c +++ b/drivers/gpu/drm/exynos/exynos_drm_rotator.c @@ -513,6 +513,7 @@ static inline bool rotator_check_drm_flip(enum drm_exynos_flip flip) case EXYNOS_DRM_FLIP_NONE: case EXYNOS_DRM_FLIP_VERTICAL: case EXYNOS_DRM_FLIP_HORIZONTAL:
- case EXYNOS_DRM_FLIP_VERTICAL | EXYNOS_DRM_FLIP_HORIZONTAL:
Ditto.
return true;
default: DRM_DEBUG_KMS("%s:invalid flip\n", __func__); -- 1.7.0.4
Thank's for comment.
Oops, sorry that is my fault. I will resend it.
BR Eunchul Kim
On 12/20/2012 06:48 PM, Inki Dae wrote:
-----Original Message----- From: Eunchul Kim [mailto:chulspro.kim@samsung.com] Sent: Thursday, December 20, 2012 6:32 PM To: dri-devel@lists.freedesktop.org; inki.dae@samsung.com Cc: jy0.jeon@samsung.com; yj44.cho@samsung.com; jmock.shin@samsung.com; jaejoon.seo@samsung.com; kyungmin.park@samsung.com; jy0922.shim@samsung.com; sw0312.kim@samsung.com; th908.kim@samsung.com; lsmin.lee@samsung.com; chulspro.kim@samsung.com Subject: [PATCH 3/8] drm/exynos: fixed vflip, hflip case at the same time.
This patch fixed vflip, hflip at the same time. If we want to change 180 degree about buffer, then we can use h,vflip or 180 degree. we supports 180 degree using h,vflip. but we make error handling in this case. so, fixed it.
Signed-off-by: Eunchul Kim chulspro.kim@samsung.com
drivers/gpu/drm/exynos/exynos_drm_fimc.c | 1 + drivers/gpu/drm/exynos/exynos_drm_rotator.c | 1 + 2 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c b/drivers/gpu/drm/exynos/exynos_drm_fimc.c index 5dc0251..4c4078c 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c @@ -1387,6 +1387,7 @@ static inline bool fimc_check_drm_flip(enum drm_exynos_flip flip) case EXYNOS_DRM_FLIP_NONE: case EXYNOS_DRM_FLIP_VERTICAL: case EXYNOS_DRM_FLIP_HORIZONTAL:
- case EXYNOS_DRM_FLIP_VERTICAL | EXYNOS_DRM_FLIP_HORIZONTAL:
This code induces build warning because the value of 'VERTICAL | HORIZONTAL' is out of range. Add a new enumeration value to enum drm_exynos_flip. i.e. EXYNOS_DRM_FLIP_BOTH = EXYNOS_DRM_FLIP_VERTICAL | EXYNOS_DRM_FLIP_HORIZONTAL and use it.
- thank's I guess why not occured warnning. but It's the better. I will resend it.
return true;
default: DRM_DEBUG_KMS("%s:invalid flip\n", __func__); diff --git a/drivers/gpu/drm/exynos/exynos_drm_rotator.c b/drivers/gpu/drm/exynos/exynos_drm_rotator.c index 17e4474..09830ad 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_rotator.c +++ b/drivers/gpu/drm/exynos/exynos_drm_rotator.c @@ -513,6 +513,7 @@ static inline bool rotator_check_drm_flip(enum drm_exynos_flip flip) case EXYNOS_DRM_FLIP_NONE: case EXYNOS_DRM_FLIP_VERTICAL: case EXYNOS_DRM_FLIP_HORIZONTAL:
- case EXYNOS_DRM_FLIP_VERTICAL | EXYNOS_DRM_FLIP_HORIZONTAL:
Ditto.
return true;
default: DRM_DEBUG_KMS("%s:invalid flip\n", __func__); -- 1.7.0.4
This patch fixed warnning in GSC build.
Signed-off-by: Eunchul Kim chulspro.kim@samsung.com --- drivers/gpu/drm/exynos/exynos_drm_gsc.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_gsc.c b/drivers/gpu/drm/exynos/exynos_drm_gsc.c index ba5fefd..4546833 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_gsc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_gsc.c @@ -1592,7 +1592,7 @@ static int gsc_ippdrv_start(struct device *dev, enum drm_exynos_ipp_cmd cmd) exynos_drm_ippnb_send_event(IPP_SET_WRITEBACK, (void *)&set_wb);
/* src local path */ - cfg = readl(GSC_IN_CON); + cfg = gsc_read(GSC_IN_CON); cfg &= ~(GSC_IN_PATH_MASK | GSC_IN_LOCAL_SEL_MASK); cfg |= (GSC_IN_PATH_LOCAL | GSC_IN_LOCAL_FIMD_WB); gsc_write(cfg, GSC_IN_CON);
This patch cleanup comment of abbreviation.
Signed-off-by: Eunchul Kim chulspro.kim@samsung.com --- drivers/gpu/drm/exynos/exynos_drm_fimc.c | 2 +- drivers/gpu/drm/exynos/exynos_drm_gsc.c | 2 +- drivers/gpu/drm/exynos/exynos_drm_ipp.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c b/drivers/gpu/drm/exynos/exynos_drm_fimc.c index 4c4078c..cfeb606 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c @@ -25,7 +25,7 @@ #include "exynos_drm_fimc.h"
/* - * FIMC is stand for Fully Interactive Mobile Camera and + * FIMC stands for Fully Interactive Mobile Camera and * supports image scaler/rotator and input/output DMA operations. * input DMA reads image data from the memory. * output DMA writes image data to memory. diff --git a/drivers/gpu/drm/exynos/exynos_drm_gsc.c b/drivers/gpu/drm/exynos/exynos_drm_gsc.c index 4546833..89fdb49 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_gsc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_gsc.c @@ -25,7 +25,7 @@ #include "exynos_drm_gsc.h"
/* - * GSC is stand for General SCaler and + * GSC stands for General SCaler and * supports image scaler/rotator and input/output DMA operations. * input DMA reads image data from the memory. * output DMA writes image data to memory. diff --git a/drivers/gpu/drm/exynos/exynos_drm_ipp.c b/drivers/gpu/drm/exynos/exynos_drm_ipp.c index cac94fe..63bcf92 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_ipp.c +++ b/drivers/gpu/drm/exynos/exynos_drm_ipp.c @@ -27,7 +27,7 @@ #include "exynos_drm_iommu.h"
/* - * IPP is stand for Image Post Processing and + * IPP stands for Image Post Processing and * supports image scaler/rotator and input/output DMA operations. * using FIMC, GSC, Rotator, so on. * IPP is integration device driver of same attribute h/w
From: JoongMock Shin jmock.shin@samsung.com
This patch removed color bar pattern register. we not use color bar any more. and don't support color bar at writeback operation.
Signed-off-by: JoongMock Shin jmock.shin@samsung.com Signed-off-by: Eunchul Kim chulspro.kim@samsung.com --- drivers/gpu/drm/exynos/exynos_drm_fimc.c | 9 +++------ 1 files changed, 3 insertions(+), 6 deletions(-)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c b/drivers/gpu/drm/exynos/exynos_drm_fimc.c index cfeb606..67e1b88 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c @@ -163,17 +163,14 @@ struct fimc_context { bool suspended; };
-static void fimc_sw_reset(struct fimc_context *ctx, bool pattern) +static void fimc_sw_reset(struct fimc_context *ctx) { u32 cfg;
- DRM_DEBUG_KMS("%s:pattern[%d]\n", __func__, pattern); + DRM_DEBUG_KMS("%s\n", __func__);
cfg = fimc_read(EXYNOS_CISRCFMT); cfg |= EXYNOS_CISRCFMT_ITU601_8BIT; - if (pattern) - cfg |= EXYNOS_CIGCTRL_TESTPATTERN_COLOR_BAR; - fimc_write(cfg, EXYNOS_CISRCFMT);
/* s/w reset */ @@ -1536,7 +1533,7 @@ static int fimc_ippdrv_reset(struct device *dev) DRM_DEBUG_KMS("%s\n", __func__);
/* reset h/w block */ - fimc_sw_reset(ctx, false); + fimc_sw_reset(ctx);
/* reset scaler capability */ memset(&ctx->sc, 0x0, sizeof(ctx->sc));
From: Jinyoung Jeon jy0.jeon@samsung.com
This patch fixed unnormal interrupt at m2m operation sometimes. m2m operation called s/w reset during every frame. but m2m occured interrupt after s/w reset sometimes. so, we cleared dma operation and capture operation.
Signed-off-by: Jinyoung Jeon jy0.jeon@samsung.com Signed-off-by: Eunchul Kim chulspro.kim@samsung.com --- drivers/gpu/drm/exynos/exynos_drm_fimc.c | 13 +++++++++++++ 1 files changed, 13 insertions(+), 0 deletions(-)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c b/drivers/gpu/drm/exynos/exynos_drm_fimc.c index 67e1b88..c9eaa81 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c @@ -169,10 +169,23 @@ static void fimc_sw_reset(struct fimc_context *ctx)
DRM_DEBUG_KMS("%s\n", __func__);
+ /* stop dma operation */ + cfg = fimc_read(EXYNOS_CISTATUS); + if (EXYNOS_CISTATUS_GET_ENVID_STATUS(cfg)) { + cfg = fimc_read(EXYNOS_MSCTRL); + cfg &= ~EXYNOS_MSCTRL_ENVID; + fimc_write(cfg, EXYNOS_MSCTRL); + } + cfg = fimc_read(EXYNOS_CISRCFMT); cfg |= EXYNOS_CISRCFMT_ITU601_8BIT; fimc_write(cfg, EXYNOS_CISRCFMT);
+ /* disable image capture */ + cfg = fimc_read(EXYNOS_CIIMGCPT); + cfg &= ~(EXYNOS_CIIMGCPT_IMGCPTEN_SC | EXYNOS_CIIMGCPT_IMGCPTEN); + fimc_write(cfg, EXYNOS_CIIMGCPT); + /* s/w reset */ cfg = fimc_read(EXYNOS_CIGCTRL); cfg |= (EXYNOS_CIGCTRL_SWRST);
This patch cleanup needless parenthesis. we got the comment from GSC. but we missed fimc side. so, we cleanup the code.
Signed-off-by: Eunchul Kim chulspro.kim@samsung.com --- drivers/gpu/drm/exynos/exynos_drm_fimc.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c b/drivers/gpu/drm/exynos/exynos_drm_fimc.c index c9eaa81..7238f4e 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c @@ -1212,7 +1212,7 @@ static int fimc_dst_set_buf_seq(struct fimc_context *ctx, u32 buf_id, }
/* sequence id */ - cfg &= (~mask); + cfg &= ~mask; cfg |= (enable << buf_id); fimc_write(cfg, EXYNOS_CIFCNTSEQ);
dri-devel@lists.freedesktop.org