mtd: OneNAND: do not use DMA if oops in progress
Otherwise we may hang if we are called from panic() through mtdoops. Signed-off-by: Aaro Koskinen <aaro.koskinen@nokia.com> Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
This commit is contained in:
parent
7d70f334ad
commit
932f5d21cc
|
@ -308,7 +308,7 @@ static int omap3_onenand_read_bufferram(struct mtd_info *mtd, int area,
|
|||
goto out_copy;
|
||||
|
||||
/* panic_write() may be in an interrupt context */
|
||||
if (in_interrupt())
|
||||
if (in_interrupt() || oops_in_progress)
|
||||
goto out_copy;
|
||||
|
||||
if (buf >= high_memory) {
|
||||
|
@ -385,7 +385,7 @@ static int omap3_onenand_write_bufferram(struct mtd_info *mtd, int area,
|
|||
goto out_copy;
|
||||
|
||||
/* panic_write() may be in an interrupt context */
|
||||
if (in_interrupt())
|
||||
if (in_interrupt() || oops_in_progress)
|
||||
goto out_copy;
|
||||
|
||||
if (buf >= high_memory) {
|
||||
|
|
Loading…
Reference in New Issue