[flashrom] [PATCH] Handle erase failure in partial write, clean up