See uma.h */
| 3406 | |
| 3407 | /* See uma.h */ |
| 3408 | void * |
| 3409 | uma_zalloc_smr(uma_zone_t zone, int flags) |
| 3410 | { |
| 3411 | uma_cache_bucket_t bucket; |
| 3412 | uma_cache_t cache; |
| 3413 | |
| 3414 | #ifdef UMA_ZALLOC_DEBUG |
| 3415 | void *item; |
| 3416 | |
| 3417 | KASSERT((zone->uz_flags & UMA_ZONE_SMR) != 0, |
| 3418 | ("uma_zalloc_arg: called with non-SMR zone.")); |
| 3419 | if (uma_zalloc_debug(zone, &item, NULL, flags) == EJUSTRETURN) |
| 3420 | return (item); |
| 3421 | #endif |
| 3422 | |
| 3423 | critical_enter(); |
| 3424 | cache = &zone->uz_cpu[curcpu]; |
| 3425 | bucket = &cache->uc_allocbucket; |
| 3426 | if (__predict_false(bucket->ucb_cnt == 0)) |
| 3427 | return (cache_alloc_retry(zone, cache, NULL, flags)); |
| 3428 | return (cache_alloc_item(zone, cache, bucket, NULL, flags)); |
| 3429 | } |
| 3430 | |
| 3431 | /* See uma.h */ |
| 3432 | void * |
no test coverage detected