diff --git a/code/nrf-connect/samples/zigbee/src/debug_counters.c b/code/nrf-connect/samples/zigbee/src/debug_counters.c index a75f1f3..af57042 100644 --- a/code/nrf-connect/samples/zigbee/src/debug_counters.c +++ b/code/nrf-connect/samples/zigbee/src/debug_counters.c @@ -108,24 +108,3 @@ int prst_debug_counters_get_all(prst_debug_counters_callback_t callback) { } return fs_closedir(&dirp); } - -typedef struct { - struct k_work work; - const char* counter_name; -} counter_increment_work_t; - -static void increment_counter_callback(struct k_work* work) { - counter_increment_work_t* counter_work = CONTAINER_OF(work, counter_increment_work_t, work); - LOG_DBG("Incrementing counter callback for %s", counter_work->counter_name); - prst_debug_counters_increment(counter_work->counter_name); - free(counter_work); - LOG_DBG("Freed memory for %s", counter_work->counter_name); -} - -int prst_debug_counters_increment_async(const char* counter_name) { - counter_increment_work_t* work = malloc(sizeof(counter_increment_work_t)); - work->counter_name = counter_name; - k_work_init(&work->work, increment_counter_callback); - LOG_DBG("Scheduling increment of %s", counter_name); - return k_work_submit(&work->work); -} \ No newline at end of file diff --git a/code/nrf-connect/samples/zigbee/src/debug_counters.h b/code/nrf-connect/samples/zigbee/src/debug_counters.h index 3000102..84a511c 100644 --- a/code/nrf-connect/samples/zigbee/src/debug_counters.h +++ b/code/nrf-connect/samples/zigbee/src/debug_counters.h @@ -11,8 +11,6 @@ int prst_debug_counters_init(); int prst_debug_counters_increment(const char* counter_name); -int prst_debug_counters_increment_async(const char* counter_name); - int prst_debug_counters_get(const char* counter_name, prst_debug_counter_t* value); int prst_debug_counters_get_all(prst_debug_counters_callback_t callback);