MLK-16695-3: mipi_csi: Change printk to dev_dbg
authorGuoniu.Zhou <guoniu.zhou@nxp.com>
Fri, 10 Nov 2017 03:09:21 +0000 (11:09 +0800)
committerNitin Garg <nitin.garg@nxp.com>
Mon, 19 Mar 2018 20:46:56 +0000 (15:46 -0500)
Messages in ISI irq handler are for debugging, so
change printk to dev_dbg for this purpose.

The width and height of image information need output
in debug process.

Reviewed-by: Sandor Yu <sandor.yu@nxp.com>
Signed-off-by: Guoniu.Zhou <guoniu.zhou@nxp.com>
(cherry picked from commit e254c8408f69eca9b668af58d911f27a4fefc121)

drivers/media/platform/imx8/mxc-isi-core.c
drivers/media/platform/imx8/mxc-mipi-csi2.c

index dfa985f..45174f3 100644 (file)
@@ -15,6 +15,7 @@
 static irqreturn_t mxc_isi_irq_handler(int irq, void *priv)
 {
        struct mxc_isi_dev *mxc_isi = priv;
+       struct device *dev = &mxc_isi->pdev->dev;
        u32 status;
 
        spin_lock(&mxc_isi->slock);
@@ -28,19 +29,19 @@ static irqreturn_t mxc_isi_irq_handler(int irq, void *priv)
        if (status & (CHNL_STS_AXI_WR_ERR_Y_MASK |
                                        CHNL_STS_AXI_WR_ERR_U_MASK |
                                        CHNL_STS_AXI_WR_ERR_V_MASK))
-               printk("%s, IRQ AXI Error stat=0x%X\n", __func__, status);
+               dev_dbg(dev, "%s, IRQ AXI Error stat=0x%X\n", __func__, status);
        if (status & (CHNL_STS_OFLW_PANIC_Y_BUF_MASK |
                                        CHNL_STS_OFLW_PANIC_U_BUF_MASK |
                                        CHNL_STS_OFLW_PANIC_V_BUF_MASK))
-               printk("%s, IRQ Panic OFLW Error stat=0x%X\n", __func__, status);
+               dev_dbg(dev, "%s, IRQ Panic OFLW Error stat=0x%X\n", __func__, status);
        if (status & (CHNL_STS_OFLW_Y_BUF_MASK |
                                        CHNL_STS_OFLW_U_BUF_MASK |
                                        CHNL_STS_OFLW_V_BUF_MASK))
-               printk("%s, IRQ OFLW Error stat=0x%X\n", __func__, status);
+               dev_dbg(dev, "%s, IRQ OFLW Error stat=0x%X\n", __func__, status);
        if (status & (CHNL_STS_EXCS_OFLW_Y_BUF_MASK |
                                        CHNL_STS_EXCS_OFLW_U_BUF_MASK |
                                        CHNL_STS_EXCS_OFLW_V_BUF_MASK))
-               printk("%s, IRQ EXCS OFLW Error stat=0x%X\n", __func__, status);
+               dev_dbg(dev, "%s, IRQ EXCS OFLW Error stat=0x%X\n", __func__, status);
 
        spin_unlock(&mxc_isi->slock);
        return IRQ_HANDLED;
index 86489c4..d463f1f 100644 (file)
@@ -285,7 +285,7 @@ static int mxc_csi2_get_sensor_fmt(struct mxc_mipi_csi2_dev *csi2dev)
        memcpy(mf, &src_fmt.format, sizeof(struct v4l2_mbus_framefmt));
 
        /* Update input frame size and formate  */
-       dev_info(&csi2dev->pdev->dev, "width=%d, height=%d, fmt.code=0x%x\n", mf->width, mf->height, mf->code);
+       dev_dbg(&csi2dev->pdev->dev, "width=%d, height=%d, fmt.code=0x%x\n", mf->width, mf->height, mf->code);
        if (src_fmt.format.height * src_fmt.format.width > 1024 * 768)
                csi2dev->hs_settle = rxhs_settle[2];
        else if (src_fmt.format.height * src_fmt.format.width < 480 * 320)