diff options
author | Maria Matejka <mq@ucw.cz> | 2022-09-07 15:06:22 +0200 |
---|---|---|
committer | Maria Matejka <mq@ucw.cz> | 2022-09-08 15:13:37 +0200 |
commit | 5103de4e8ed7f4744326129a4296cf3511b1e1f9 (patch) | |
tree | 789b4a1928ef6990962a8de1d0f5758318fc05f2 /nest/rt-table.c | |
parent | e2c612063649cb5134459ab0a2c7377f00d6e9c0 (diff) |
Table long-locking debug code
Diffstat (limited to 'nest/rt-table.c')
-rw-r--r-- | nest/rt-table.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/nest/rt-table.c b/nest/rt-table.c index eb53eff7..cdf0fd3e 100644 --- a/nest/rt-table.c +++ b/nest/rt-table.c @@ -3680,10 +3680,10 @@ rt_new_table(struct symbol *s, uint addr_type) * preventing it from being freed when it gets undefined in a new * configuration. */ -void -rt_lock_table(rtable *r) +void rt_lock_table_debug(rtable *tab, const char *file, uint line) { - r->use_count++; + rt_trace(tab, D_STATES, "Locked at %s:%d", file, line); + tab->use_count++; } /** @@ -3694,9 +3694,9 @@ rt_lock_table(rtable *r) * that is decrease its use count and delete it if it's scheduled * for deletion by configuration changes. */ -void -rt_unlock_table(rtable *r) +void rt_unlock_table_debug(rtable *r, const char *file, uint line) { + rt_trace(r, D_STATES, "Unlocked at %s:%d", file, line); if (!--r->use_count && r->deleted) { struct config *conf = r->deleted; |