summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2010-01-09 20:57:29 -0800
committerKeith Packard <keithp@keithp.com>2010-01-09 20:57:29 -0800
commita6082a8b4501ac4cb18584ace1f0c40e088e5484 (patch)
tree0ae97ddaa4355b137182d41609fa8b6a01955959 /src
parent05bb953830604721c9a49dd56256b86f3666b5ff (diff)
Remove flash debugging printfs
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'src')
-rw-r--r--src/ao_flash.c49
1 files changed, 23 insertions, 26 deletions
diff --git a/src/ao_flash.c b/src/ao_flash.c
index 3ea3e40b..638e51e0 100644
--- a/src/ao_flash.c
+++ b/src/ao_flash.c
@@ -400,29 +400,6 @@ ao_ee_flush(void) __reentrant
* the last block of the flash
*/
-void
-ao_ee_dump_config(void) __reentrant
-{
- uint16_t i;
- printf("Configuration block %d\n", FLASH_CONFIG_BLOCK);
- ao_mutex_get(&ao_flash_mutex); {
- ao_flash_flush_internal();
- ao_flash_block = FLASH_BLOCK_NONE;
- ao_flash_fill(FLASH_CONFIG_BLOCK);
- i = 0;
- do {
- if ((i & 7) == 0) {
- if (i)
- putchar('\n');
- ao_cmd_put16((uint16_t) i);
- }
- putchar(' ');
- ao_cmd_put8(ao_flash_data[i]);
- ++i;
- } while (i < sizeof (ao_config));
- } ao_mutex_put(&ao_flash_mutex);
-}
-
uint8_t
ao_ee_write_config(uint8_t *buf, uint16_t len) __reentrant
{
@@ -430,13 +407,11 @@ ao_ee_write_config(uint8_t *buf, uint16_t len) __reentrant
if (len > FLASH_BLOCK_SIZE)
return 0;
ao_mutex_get(&ao_flash_mutex); {
- printf("FLASH_CONFIG_BLOCK: %d\n", FLASH_CONFIG_BLOCK);
ao_flash_fill(FLASH_CONFIG_BLOCK);
memcpy(ao_flash_data, buf, len);
ao_flash_block_dirty = 1;
ao_flash_flush_internal();
} ao_mutex_put(&ao_flash_mutex);
- ao_ee_dump_config();
return 1;
}
@@ -446,7 +421,6 @@ ao_ee_read_config(uint8_t *buf, uint16_t len) __reentrant
ao_flash_setup();
if (len > FLASH_BLOCK_SIZE)
return 0;
- ao_ee_dump_config();
ao_mutex_get(&ao_flash_mutex); {
ao_flash_fill(FLASH_CONFIG_BLOCK);
memcpy(buf, ao_flash_data, len);
@@ -509,6 +483,29 @@ flash_store(void) __reentrant
ao_ee_flush();
}
+void
+ao_ee_dump_config(void) __reentrant
+{
+ uint16_t i;
+ printf("Configuration block %d\n", FLASH_CONFIG_BLOCK);
+ ao_mutex_get(&ao_flash_mutex); {
+ ao_flash_flush_internal();
+ ao_flash_block = FLASH_BLOCK_NONE;
+ ao_flash_fill(FLASH_CONFIG_BLOCK);
+ i = 0;
+ do {
+ if ((i & 7) == 0) {
+ if (i)
+ putchar('\n');
+ ao_cmd_put16((uint16_t) i);
+ }
+ putchar(' ');
+ ao_cmd_put8(ao_flash_data[i]);
+ ++i;
+ } while (i < sizeof (ao_config));
+ } ao_mutex_put(&ao_flash_mutex);
+}
+
static void
flash_status(void) __reentrant
{