Commit 0e33bbb25436949cc100d40edfbe0f96dfa25882
Committed by
Wolfram Sang
1 parent
5692d2a22e
Exists in
smarc-l5.0.0_1.0.0-ga
and in
5 other branches
i2c: omap: Do not initialise the completion everytime
Use INIT_COMPLETION instead of init_completion in transfer. Reviewed-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Shubhrajyoti D <shubhrajyoti@ti.com> Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Showing 1 changed file with 2 additions and 1 deletions Side-by-side Diff
drivers/i2c/busses/i2c-omap.c
... | ... | @@ -490,7 +490,7 @@ |
490 | 490 | w |= OMAP_I2C_BUF_RXFIF_CLR | OMAP_I2C_BUF_TXFIF_CLR; |
491 | 491 | omap_i2c_write_reg(dev, OMAP_I2C_BUF_REG, w); |
492 | 492 | |
493 | - init_completion(&dev->cmd_complete); | |
493 | + INIT_COMPLETION(dev->cmd_complete); | |
494 | 494 | dev->cmd_err = 0; |
495 | 495 | |
496 | 496 | w = OMAP_I2C_CON_EN | OMAP_I2C_CON_MST | OMAP_I2C_CON_STT; |
... | ... | @@ -999,6 +999,7 @@ |
999 | 999 | } |
1000 | 1000 | |
1001 | 1001 | platform_set_drvdata(pdev, dev); |
1002 | + init_completion(&dev->cmd_complete); | |
1002 | 1003 | |
1003 | 1004 | dev->reg_shift = (dev->flags >> OMAP_I2C_FLAG_BUS_SHIFT__SHIFT) & 3; |
1004 | 1005 |