From b4dc1e92405f961fc8bf12ea2aeee981ce235c4e Mon Sep 17 00:00:00 2001 From: SangHyun Sim Date: Thu, 28 Jun 2018 17:05:38 +0900 Subject: [PATCH] [COMMON] fimc-is2: add to check PAFSTAT irq time for debugging Change-Id: Ib6c371c552eceb73704d8916f192f58254b6e8c9 Signed-off-by: SangHyun Sim --- .../sensor/module_framework/fimc-is-device-sensor-peri.h | 1 + .../sensor/module_framework/pafstat/fimc-is-pafstat.c | 9 +++++---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/drivers/media/platform/exynos/fimc-is2/sensor/module_framework/fimc-is-device-sensor-peri.h b/drivers/media/platform/exynos/fimc-is2/sensor/module_framework/fimc-is-device-sensor-peri.h index 33f62527e8bb..0695275033fa 100644 --- a/drivers/media/platform/exynos/fimc-is2/sensor/module_framework/fimc-is-device-sensor-peri.h +++ b/drivers/media/platform/exynos/fimc-is2/sensor/module_framework/fimc-is-device-sensor-peri.h @@ -274,6 +274,7 @@ struct fimc_is_paf { struct pafstat_setting_t *regs_set; struct fimc_is_paf_ops *paf_ops; struct v4l2_subdev *subdev; /* connected module subdevice */ + char name[FIMC_IS_STR_LEN]; }; struct fimc_is_device_sensor_peri { diff --git a/drivers/media/platform/exynos/fimc-is2/sensor/module_framework/pafstat/fimc-is-pafstat.c b/drivers/media/platform/exynos/fimc-is2/sensor/module_framework/pafstat/fimc-is-pafstat.c index ca608f4f5041..d8bb7d0471c7 100644 --- a/drivers/media/platform/exynos/fimc-is2/sensor/module_framework/pafstat/fimc-is-pafstat.c +++ b/drivers/media/platform/exynos/fimc-is2/sensor/module_framework/pafstat/fimc-is-pafstat.c @@ -134,7 +134,7 @@ static irqreturn_t fimc_is_isr_pafstat(int irq, void *data) pafstat_hw_s_ready(base_reg, 1); atomic_inc(&pafstat->fs); - dbg_pafstatisr("[%d][F:%d] F.S (0x%x)", pafstat->id, atomic_read(&pafstat->fs), status); + dbg_isr("[%d][F:%d] F.S (0x%x)", pafstat, pafstat->id, atomic_read(&pafstat->fs), status); atomic_add(pafstat->fro_cnt, &pafstat->fs); } @@ -144,19 +144,19 @@ static irqreturn_t fimc_is_isr_pafstat(int irq, void *data) if (status & (1 << PAFSTAT_INT_BAYER_FRAME_END)) { atomic_inc(&pafstat->fe_img); - dbg_pafstatisr("[%d][F:%d] F.E, img (0x%x)", pafstat->id, atomic_read(&pafstat->fe_img), status); + dbg_isr("[%d][F:%d] F.E, img (0x%x)", pafstat, pafstat->id, atomic_read(&pafstat->fe_img), status); atomic_add(pafstat->fro_cnt, &pafstat->fe_img); } if (status & (1 << PAFSTAT_INT_STAT_FRAME_END)) { atomic_inc(&pafstat->fe_stat); - dbg_pafstatisr("[%d][F:%d] F.E, stat (0x%x)", pafstat->id, atomic_read(&pafstat->fe_stat), status); + dbg_isr("[%d][F:%d] F.E, stat (0x%x)", pafstat, pafstat->id, atomic_read(&pafstat->fe_stat), status); atomic_add(pafstat->fro_cnt, &pafstat->fe_stat); } if (status & (1 << PAFSTAT_INT_TOTAL_FRAME_END)) { atomic_inc(&pafstat->fe); - dbg_pafstatisr("[%d][F:%d] F.E (0x%x)", pafstat->id, atomic_read(&pafstat->fe), status); + dbg_isr("[%d][F:%d] F.E (0x%x)", pafstat, pafstat->id, atomic_read(&pafstat->fe), status); atomic_add(pafstat->fro_cnt, &pafstat->fe); pafstat_hw_s_timeout_cnt_clear(pafstat->regs); atomic_set(&pafstat->Vvalid, V_BLANK); @@ -579,6 +579,7 @@ static int __init pafstat_probe(struct platform_device *pdev) goto err_subdev_alloc; } + snprintf(pafstat->name, FIMC_IS_STR_LEN, "PAFSTAT%d", pafstat->id); reg_cnt = pafstat_hw_g_reg_cnt(); pafstat->regs_set = devm_kzalloc(&pdev->dev, reg_cnt * sizeof(struct pafstat_setting_t), GFP_KERNEL); if (!pafstat->regs_set) { -- 2.20.1