| 43 | } |
| 44 | |
| 45 | void |
| 46 | bplist_append(bplist_t *bpl, const blkptr_t *bp) |
| 47 | { |
| 48 | bplist_entry_t *bpe = kmem_alloc(sizeof (*bpe), KM_SLEEP); |
| 49 | |
| 50 | mutex_enter(&bpl->bpl_lock); |
| 51 | bpe->bpe_blk = *bp; |
| 52 | list_insert_tail(&bpl->bpl_list, bpe); |
| 53 | mutex_exit(&bpl->bpl_lock); |
| 54 | } |
| 55 | |
| 56 | /* |
| 57 | * To aid debugging, we keep the most recently removed entry. This way if |
no test coverage detected