]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
drm/i2c: tda998x: always enable EDID read IRQ
authorJean-Francois Moine <moinejf@free.fr>
Sat, 25 Jan 2014 17:14:38 +0000 (18:14 +0100)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Thu, 13 Feb 2014 19:41:55 +0000 (19:41 +0000)
There is no need to enable/disable EDID read IRQ at each EDID block
read. This patch enables the IRQ at init time.

Tested-by: Russell King <rmk+kernel@arm.linux.org.uk>
Acked-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
drivers/gpu/drm/i2c/tda998x_drv.c

index 1ea4d43781f255168e2c28c80e2ef3c10a12e589..fddac4c84c28f0a1ef3539852980e0bed5f426ce 100644 (file)
@@ -985,9 +985,6 @@ read_edid_block(struct drm_encoder *encoder, uint8_t *buf, int blk)
        uint8_t offset, segptr;
        int ret, i;
 
-       /* enable EDID read irq: */
-       reg_set(priv, REG_INT_FLAGS_2, INT_FLAGS_2_EDID_BLK_RD);
-
        offset = (blk & 1) ? 128 : 0;
        segptr = blk / 2;
 
@@ -1022,8 +1019,6 @@ read_edid_block(struct drm_encoder *encoder, uint8_t *buf, int blk)
                return ret;
        }
 
-       reg_clear(priv, REG_INT_FLAGS_2, INT_FLAGS_2_EDID_BLK_RD);
-
        return 0;
 }
 
@@ -1247,6 +1242,9 @@ tda998x_encoder_init(struct i2c_client *client,
        cec_write(priv, REG_CEC_FRO_IM_CLK_CTRL,
                        CEC_FRO_IM_CLK_CTRL_GHOST_DIS | CEC_FRO_IM_CLK_CTRL_IMCLK_SEL);
 
+       /* enable EDID read irq: */
+       reg_set(priv, REG_INT_FLAGS_2, INT_FLAGS_2_EDID_BLK_RD);
+
        if (!np)
                return 0;               /* non-DT */