}
spin_unlock(&shared->lock);
}
+ } else {
+ spin_unlock(&shared->lock);
}
}
spin_unlock(chip->mutex);
INVALIDATE_CACHED_RANGE(map, adr, len);
- set_current_state(TASK_UNINTERRUPTIBLE);
- schedule_timeout((chip->erase_time*HZ)/(2*1000));
+ msleep(chip->erase_time / 2);
spin_lock(chip->mutex);
/* FIXME. Use a timer to check this, and return immediately. */