[PATCH v7 4/7] omap3: nand: prefetch in irq mode support
From: Ghorai, Sukumar <hidden>
Date: 2011-01-04 08:50:17
Also in:
linux-omap
From: Ghorai, Sukumar <hidden>
Date: 2011-01-04 08:50:17
Also in:
linux-omap
[..snip...]
quoted
+ if (info->buf_len & (info->buf_len < bytes))Meant to use logical AND here?
[Ghorai] thanks, you are right. [..snip..]
quoted
+ init_completion(&info->comp);You can use INIT_COMPLETION to reset the completion variable. Same change can be done in write below.
[..snip..]
s/methode/method
[Ghorai] yes. I will do this [..snip..]
quoted
+ /* waiting for write to complete */ + wait_for_completion(&info->comp); + /* wait for data to flushed-out before reset the prefetch */ + do { + ret = gpmc_read_status(GPMC_PREFETCH_COUNT); + } while (ret);Please have a timeout for this while loop in case hardware does not become ready. Also, consider using cpu_relax() inside the tight loop.
[Ghorai] Thanks. I will send again.