Skip to contentSkip to conversation

erase / interrupts

DISCUSSION Jochen Schaeuble 2 participants 2 messages May 21, 2001 Memory technology devices (MTD)

lore
Share & tools
lore
#0 lore raw

I have two questions. First of all, what happens to the interrupts during an erase? Are they disabled?
The other one is, what happens if the power fails during a erase/write. Does the init-code handle the reset of the chip?

Thx
Jochen

#1 lore raw
Quoted 2 lines · [email protected] said:

I have two questions. First of all, what happens to the interrupts during an erase? Are they disabled?

That's entirely dependent on the driver. In general, interrupts _shouldn't_ be disabled. They aren't disabled in the cfi_cmdset_000[12] drivers.

The erase method may sleep. And it may return immediately, calling the erase completion callback later, from a timer. That isn't implemented yet. Of course, it's entirely permitted to do both.

Quoted 2 lines

The other one is, what happens if the power fails during a erase/write. Does the init-code handle the reset of the chip?

Yes, it should do. It's up the the application to work out the the sector in question was partially erased and erase it properly. See the marker nodes in JFFS2.

--
dwmw2