Changeset 4d194be in mainline
- Timestamp:
- 2012-05-08T09:31:18Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 905721b
- Parents:
- ddb56be
- Location:
- kernel/generic
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/include/mm/slab.h
rddb56be r4d194be 116 116 /* Magazines */ 117 117 list_t magazines; /**< List o full magazines */ 118 SPINLOCK_DECLARE(maglock);118 IRQ_SPINLOCK_DECLARE(maglock); 119 119 120 120 /** CPU cache */ -
kernel/generic/src/mm/slab.c
rddb56be r4d194be 355 355 link_t *cur; 356 356 357 ASSERT(interrupts_disabled()); 358 359 spinlock_lock(&cache->maglock); 357 irq_spinlock_lock(&cache->maglock, true); 360 358 if (!list_empty(&cache->magazines)) { 361 359 if (first) … … 368 366 atomic_dec(&cache->magazine_counter); 369 367 } 370 spinlock_unlock(&cache->maglock);368 irq_spinlock_unlock(&cache->maglock, true); 371 369 372 370 return mag; … … 379 377 slab_magazine_t *mag) 380 378 { 381 ASSERT(interrupts_disabled()); 382 383 spinlock_lock(&cache->maglock); 379 irq_spinlock_lock(&cache->maglock, true); 384 380 385 381 list_prepend(&mag->link, &cache->magazines); 386 382 atomic_inc(&cache->magazine_counter); 387 383 388 spinlock_unlock(&cache->maglock);384 irq_spinlock_unlock(&cache->maglock, true); 389 385 } 390 386 … … 629 625 630 626 irq_spinlock_initialize(&cache->slablock, "slab.cache.slablock"); 631 spinlock_initialize(&cache->maglock, "slab.cache.maglock");627 irq_spinlock_initialize(&cache->maglock, "slab.cache.maglock"); 632 628 633 629 if (!(cache->flags & SLAB_CACHE_NOMAGAZINE))
Note:
See TracChangeset
for help on using the changeset viewer.