rem: return ENOMEM;
add: return FS_ENOMEM;
context: init_block_cache(int max_blocks, int flags){    memset(&bc, 0, sizeof(bc));    memset(iovec_pool, 0, sizeof(iovec_pool));    memset(iovec_used, 0, sizeof(iovec_used));    memset(&max_device_blocks, 0, sizeof(max_device_blocks));    if (init_hash_table(&bc.ht) != 0)        return ENOMEM;    bc.lock.s = iovec_lock.s = -1;    bc.max_blocks = max_blocks;    bc.flags      = flags;    if (new_lock(&bc.lock, "bollockcache") != 0)        goto err;    if (new_lock(&iovec_lock, "iovec_lock") != 0)        goto err;        /* allocate two of these up front so vm won't accidently re-enter itself */    iovec_pool[0] = (struct iovec *)malloc(sizeof(struct iovec)*NUM_FLUSH_BLOCKS);    iovec_pool[1] = (struct iovec *)malloc(sizeof(struct iovec)*NUM_FLUSH_BLOCKS);#ifndef USER#ifdef DEBUG    add_debugger_command("bcache", do_dump, "dump the block cache list");    add_debugger_command("fblock", do_find_block, "find a block in the cache");    add_debugger_command("fdata",  do_find_data, "find a data block ptr in the cache");#endif    register_kernel_daemon(cache_flusher, NULL, 3);#endif    return 0; err:    if (bc.lock.s >= 0)        free_lock(&bc.lock);    if (iovec_lock.s >= 0)        free_lock(&iovec_lock);    shutdown_hash_table(&bc.ht);    memset((void *)&bc, 0, sizeof(bc));    return ENOMEM;}