diff options
author | Wolfram Sang <wsa@the-dreams.de> | 2013-11-14 17:32:02 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-11-14 19:32:21 -0500 |
commit | 16735d022f72b20ddbb2274b8e109f69575e9b2b (patch) | |
tree | f567c7dfff06ae18899feab7cd8a79a7a0f7be40 /drivers/mtd/onenand/omap2.c | |
parent | c32f74ab2872994bc8336ed367313da3139350ca (diff) |
tree-wide: use reinit_completion instead of INIT_COMPLETION
Use this new function to make code more comprehensible, since we are
reinitialzing the completion, not initializing.
[akpm@linux-foundation.org: linux-next resyncs]
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Acked-by: Linus Walleij <linus.walleij@linaro.org> (personally at LCE13)
Cc: Ingo Molnar <mingo@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/mtd/onenand/omap2.c')
-rw-r--r-- | drivers/mtd/onenand/omap2.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/mtd/onenand/omap2.c b/drivers/mtd/onenand/omap2.c index 2362909d20c0..6547c84afc3a 100644 --- a/drivers/mtd/onenand/omap2.c +++ b/drivers/mtd/onenand/omap2.c | |||
@@ -159,7 +159,7 @@ static int omap2_onenand_wait(struct mtd_info *mtd, int state) | |||
159 | syscfg = read_reg(c, ONENAND_REG_SYS_CFG1); | 159 | syscfg = read_reg(c, ONENAND_REG_SYS_CFG1); |
160 | } | 160 | } |
161 | 161 | ||
162 | INIT_COMPLETION(c->irq_done); | 162 | reinit_completion(&c->irq_done); |
163 | if (c->gpio_irq) { | 163 | if (c->gpio_irq) { |
164 | result = gpio_get_value(c->gpio_irq); | 164 | result = gpio_get_value(c->gpio_irq); |
165 | if (result == -1) { | 165 | if (result == -1) { |
@@ -349,7 +349,7 @@ static int omap3_onenand_read_bufferram(struct mtd_info *mtd, int area, | |||
349 | omap_set_dma_dest_params(c->dma_channel, 0, OMAP_DMA_AMODE_POST_INC, | 349 | omap_set_dma_dest_params(c->dma_channel, 0, OMAP_DMA_AMODE_POST_INC, |
350 | dma_dst, 0, 0); | 350 | dma_dst, 0, 0); |
351 | 351 | ||
352 | INIT_COMPLETION(c->dma_done); | 352 | reinit_completion(&c->dma_done); |
353 | omap_start_dma(c->dma_channel); | 353 | omap_start_dma(c->dma_channel); |
354 | 354 | ||
355 | timeout = jiffies + msecs_to_jiffies(20); | 355 | timeout = jiffies + msecs_to_jiffies(20); |
@@ -420,7 +420,7 @@ static int omap3_onenand_write_bufferram(struct mtd_info *mtd, int area, | |||
420 | omap_set_dma_dest_params(c->dma_channel, 0, OMAP_DMA_AMODE_POST_INC, | 420 | omap_set_dma_dest_params(c->dma_channel, 0, OMAP_DMA_AMODE_POST_INC, |
421 | dma_dst, 0, 0); | 421 | dma_dst, 0, 0); |
422 | 422 | ||
423 | INIT_COMPLETION(c->dma_done); | 423 | reinit_completion(&c->dma_done); |
424 | omap_start_dma(c->dma_channel); | 424 | omap_start_dma(c->dma_channel); |
425 | 425 | ||
426 | timeout = jiffies + msecs_to_jiffies(20); | 426 | timeout = jiffies + msecs_to_jiffies(20); |
@@ -499,7 +499,7 @@ static int omap2_onenand_read_bufferram(struct mtd_info *mtd, int area, | |||
499 | omap_set_dma_dest_params(c->dma_channel, 0, OMAP_DMA_AMODE_POST_INC, | 499 | omap_set_dma_dest_params(c->dma_channel, 0, OMAP_DMA_AMODE_POST_INC, |
500 | dma_dst, 0, 0); | 500 | dma_dst, 0, 0); |
501 | 501 | ||
502 | INIT_COMPLETION(c->dma_done); | 502 | reinit_completion(&c->dma_done); |
503 | omap_start_dma(c->dma_channel); | 503 | omap_start_dma(c->dma_channel); |
504 | wait_for_completion(&c->dma_done); | 504 | wait_for_completion(&c->dma_done); |
505 | 505 | ||
@@ -544,7 +544,7 @@ static int omap2_onenand_write_bufferram(struct mtd_info *mtd, int area, | |||
544 | omap_set_dma_dest_params(c->dma_channel, 0, OMAP_DMA_AMODE_POST_INC, | 544 | omap_set_dma_dest_params(c->dma_channel, 0, OMAP_DMA_AMODE_POST_INC, |
545 | dma_dst, 0, 0); | 545 | dma_dst, 0, 0); |
546 | 546 | ||
547 | INIT_COMPLETION(c->dma_done); | 547 | reinit_completion(&c->dma_done); |
548 | omap_start_dma(c->dma_channel); | 548 | omap_start_dma(c->dma_channel); |
549 | wait_for_completion(&c->dma_done); | 549 | wait_for_completion(&c->dma_done); |
550 | 550 | ||