Rev 754 | Rev 756 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 754 | Rev 755 | ||
---|---|---|---|
Line 74... | Line 74... | ||
74 | if (as) { |
74 | if (as) { |
75 | list_initialize(&as->as_with_asid_link); |
75 | list_initialize(&as->as_with_asid_link); |
76 | spinlock_initialize(&as->lock, "as_lock"); |
76 | spinlock_initialize(&as->lock, "as_lock"); |
77 | list_initialize(&as->as_area_head); |
77 | list_initialize(&as->as_area_head); |
78 | 78 | ||
79 | if (flags & AS_KERNEL) |
79 | if (flags & FLAG_AS_KERNEL) |
80 | as->asid = ASID_KERNEL; |
80 | as->asid = ASID_KERNEL; |
81 | else |
81 | else |
82 | as->asid = ASID_INVALID; |
82 | as->asid = ASID_INVALID; |
83 | 83 | ||
84 | as->ptl0 = ptl0; |
84 | as->ptl0 = ptl0; |
Line 184... | Line 184... | ||
184 | 184 | ||
185 | /* |
185 | /* |
186 | * Note: area->lock is held. |
186 | * Note: area->lock is held. |
187 | */ |
187 | */ |
188 | 188 | ||
189 | page_mapping_insert(page, as->asid, frame, get_area_flags(area), (__address) as->ptl0); |
189 | page_mapping_insert(as, page, frame, get_area_flags(area), (__address) as->ptl0); |
190 | 190 | ||
191 | spinlock_unlock(&area->lock); |
191 | spinlock_unlock(&area->lock); |
192 | spinlock_unlock(&as->lock); |
192 | spinlock_unlock(&as->lock); |
193 | interrupts_restore(ipl); |
193 | interrupts_restore(ipl); |
194 | } |
194 | } |
Line 264... | Line 264... | ||
264 | /* |
264 | /* |
265 | * Map 'page' to 'frame'. |
265 | * Map 'page' to 'frame'. |
266 | * Note that TLB shootdown is not attempted as only new information is being |
266 | * Note that TLB shootdown is not attempted as only new information is being |
267 | * inserted into page tables. |
267 | * inserted into page tables. |
268 | */ |
268 | */ |
269 | page_mapping_insert(page, AS->asid, frame, get_area_flags(area), (__address) AS->ptl0); |
269 | page_mapping_insert(AS, page, frame, get_area_flags(area), (__address) AS->ptl0); |
270 | 270 | ||
271 | spinlock_unlock(&area->lock); |
271 | spinlock_unlock(&area->lock); |
272 | spinlock_unlock(&AS->lock); |
272 | spinlock_unlock(&AS->lock); |
273 | 273 | ||
274 | return 1; |
274 | return 1; |