Changeset 1871118 in mainline for kernel/generic/src/sysinfo/stats.c
- Timestamp:
- 2023-02-10T22:59:11Z (2 years ago)
- Branches:
- master, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 11d2c983
- Parents:
- daadfa6
- git-author:
- Jiří Zárevúcky <zarevucky.jiri@…> (2023-02-10 22:53:12)
- git-committer:
- Jiří Zárevúcky <zarevucky.jiri@…> (2023-02-10 22:59:11)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/sysinfo/stats.c
rdaadfa6 r1871118 332 332 bool dry_run, void *data) 333 333 { 334 /* Messing with threads structures , avoid deadlock*/334 /* Messing with threads structures */ 335 335 irq_spinlock_lock(&threads_lock, true); 336 336 … … 597 597 return ret; 598 598 599 /* Messing with threads structures , avoid deadlock*/599 /* Messing with threads structures */ 600 600 irq_spinlock_lock(&threads_lock, true); 601 601 … … 627 627 ret.data.size = sizeof(stats_thread_t); 628 628 629 /* Hand-over-hand locking */ 630 irq_spinlock_exchange(&threads_lock, &thread->lock); 631 629 /* 630 * Replaced hand-over-hand locking with regular nested sections 631 * to avoid weak reference leak issues. 632 */ 633 irq_spinlock_lock(&thread->lock, false); 632 634 produce_stats_thread(thread, stats_thread); 633 634 irq_spinlock_unlock(&thread->lock, true); 635 irq_spinlock_unlock(&thread->lock, false); 636 637 irq_spinlock_unlock(&threads_lock, true); 635 638 } 636 639 … … 847 850 void kload(void *arg) 848 851 { 849 thread_detach(THREAD);850 851 852 while (true) { 852 853 size_t ready = atomic_load(&nrdy);
Note:
See TracChangeset
for help on using the changeset viewer.