Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 09c79335 authored by Nicolas Pitre's avatar Nicolas Pitre Committed by Thomas Gleixner
Browse files

[MTD] cfi_cmdset_0001: Fix state after sync



oldstate has to be reset to FL_READY after sync completion.

Signed-off-by: default avatarNicolas Pitre <nico@cam.org>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
parent 3a700250
Loading
Loading
Loading
Loading
+2 −1
Original line number Original line Diff line number Diff line
@@ -4,7 +4,7 @@
 *
 *
 * (C) 2000 Red Hat. GPL'd
 * (C) 2000 Red Hat. GPL'd
 *
 *
 * $Id: cfi_cmdset_0001.c,v 1.169 2005/03/15 19:07:18 gleixner Exp $
 * $Id: cfi_cmdset_0001.c,v 1.170 2005/03/16 22:41:05 nico Exp $
 *
 *
 * 
 * 
 * 10/10/2000	Nicolas Pitre <nico@cam.org>
 * 10/10/2000	Nicolas Pitre <nico@cam.org>
@@ -1789,6 +1789,7 @@ static void cfi_intelext_sync (struct mtd_info *mtd)
		
		
		if (chip->state == FL_SYNCING) {
		if (chip->state == FL_SYNCING) {
			chip->state = chip->oldstate;
			chip->state = chip->oldstate;
			chip->oldstate = FL_READY;
			wake_up(&chip->wq);
			wake_up(&chip->wq);
		}
		}
		spin_unlock(chip->mutex);
		spin_unlock(chip->mutex);