Changes in kernel/generic/src/mm/tlb.c [49eb681:402eda5] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/mm/tlb.c
r49eb681 r402eda5 73 73 * to all other processors. 74 74 * 75 * @param type 76 * @param asid 77 * @param page 78 * @param count 75 * @param type Type describing scope of shootdown. 76 * @param asid Address space, if required by type. 77 * @param page Virtual page address, if required by type. 78 * @param count Number of pages, if required by type. 79 79 * 80 80 * @return The interrupt priority level as it existed prior to this call. 81 *82 81 */ 83 82 ipl_t tlb_shootdown_start(tlb_invalidate_type_t type, asid_t asid, 84 83 uintptr_t page, size_t count) 85 84 { 86 ipl_t ipl = interrupts_disable(); 85 ipl_t ipl; 86 87 ipl = interrupts_disable(); 87 88 CPU->tlb_active = false; 88 89 irq_spinlock_lock(&tlblock, false); … … 90 91 size_t i; 91 92 for (i = 0; i < config.cpu_count; i++) { 93 cpu_t *cpu; 94 92 95 if (i == CPU->id) 93 96 continue; 94 97 95 cpu_t *cpu = &cpus[i]; 96 98 cpu = &cpus[i]; 97 99 irq_spinlock_lock(&cpu->lock, false); 98 100 if (cpu->tlb_messages_count == TLB_MESSAGE_QUEUE_LEN) { … … 122 124 123 125 busy_wait: 124 for (i = 0; i < config.cpu_count; i++) {126 for (i = 0; i < config.cpu_count; i++) 125 127 if (cpus[i].tlb_active) 126 128 goto busy_wait; 127 } 128 129 129 130 return ipl; 130 131 } … … 132 133 /** Finish TLB shootdown sequence. 133 134 * 134 * @param ipl Previous interrupt priority level. 135 * 135 * @param ipl Previous interrupt priority level. 136 136 */ 137 137 void tlb_shootdown_finalize(ipl_t ipl)
Note:
See TracChangeset
for help on using the changeset viewer.