Any objections?

-- 
Øyvind Harboe

Can Zylin Consulting help on your project?

US toll free 1-866-980-3434 / International +47 51 87 40 27

http://www.zylin.com/zy1000.html
ARM7 ARM9 ARM11 XScale Cortex
JTAG debugger and flash programmer
From 36d60ee6c8d3aa1865dac2378c481954ba402910 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C3=98yvind=20Harboe?= <oyvind.har...@zylin.com>
Date: Wed, 27 Apr 2011 23:02:28 +0200
Subject: [PATCH] cfi: leave check on whether target is running to target_write_memory()
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

there was a check in clearing the status register that
called exit() if the target was running. target_write_memory()
has such a check and will report the error correctly.

Signed-off-by: Øyvind Harboe <oyvind.har...@zylin.com>
---
 src/flash/nor/cfi.c |    8 --------
 1 files changed, 0 insertions(+), 8 deletions(-)

diff --git a/src/flash/nor/cfi.c b/src/flash/nor/cfi.c
index 1fa3f2d..954dbc2 100644
--- a/src/flash/nor/cfi.c
+++ b/src/flash/nor/cfi.c
@@ -305,14 +305,6 @@ static int cfi_reset(struct flash_bank *bank)
 
 static void cfi_intel_clear_status_register(struct flash_bank *bank)
 {
-	struct target *target = bank->target;
-
-	if (target->state != TARGET_HALTED)
-	{
-		LOG_ERROR("BUG: attempted to clear status register while target wasn't halted");
-		exit(-1);
-	}
-
 	cfi_send_command(bank, 0x50, flash_address(bank, 0, 0x0));
 }
 
-- 
1.7.0.4

_______________________________________________
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development

Reply via email to