Defined in 1 files as a prototype:

Defined in 1 files as a function:

Referenced in 4 files:

Smatch caller information:

fs/btrfs/scrub.c scrub_enumerate_chunks() -> btrfs_discard_queue_work()

Type Parameter Key Value
PARAM_VALUE 0 discard_ctl 4096-ptr_max
PARAM_VALUE 1 block_group 4096-ptr_max
PARAM_VALUE 1 block_group->fs_info->sb->s_cop->inode_info_offs 1632,1720,1808,2632,2648
PARAM_VALUE 1 block_group->lock.rlock.dep_map->name 0-255
PARAM_VALUE 1 block_group->reserved 0
PARAM_VALUE 1 block_group->ro 0
PARAM_VALUE 1 block_group->used 0
DATA_SOURCE 1 block_group r btrfs_lookup_block_group
NOCHECK_CALL

fs/btrfs/free-space-cache.c __btrfs_add_free_space() -> btrfs_discard_queue_work()

Type Parameter Key Value
PARAM_VALUE 0 discard_ctl 4096-ptr_max
PARAM_VALUE 1 block_group 4096-ptr_max
PARAM_VALUE 1 block_group->data_rwsem.first_waiter->handoff_set 0-1
PARAM_VALUE 1 block_group->data_rwsem.first_waiter->type 0-1
PARAM_VALUE 1 block_group->free_space_ctl->block_group 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->block_group->fs_info 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->total_bitmaps 0-s32max
PARAM_VALUE 1 block_group->free_space_ctl->tree_lock.rlock.dep_map->name 0-255
PARAM_VALUE 1 block_group->fs_info->commit_root_sem.first_waiter->handoff_set 0-1
PARAM_VALUE 1 block_group->fs_info->commit_root_sem.first_waiter->type 0-1
PARAM_VALUE 1 block_group->fs_info->remap_root->node->lock.first_waiter->handoff_set 0-1
PARAM_VALUE 1 block_group->fs_info->remap_root->node->lock.first_waiter->type 0-1
PARAM_VALUE 1 block_group->space_info->groups_sem.first_waiter->handoff_set 0-1
PARAM_VALUE 1 block_group->space_info->groups_sem.first_waiter->type 0-1
BUF_SIZE 1 block_group->fs_info (-1),11312
CAPPED_DATA 1 block_group 1
DATA_SOURCE 1 block_group $0
PREEMPT_ADD
RX_PATH
TASK_NOT_RUNNING
NOCHECK_CALL
USER_DATA 1 block_group->discard_cursor 1-s32max[c]
NO_OVERFLOW_SIMPLE 1 block_group->fs_info->nodesize
NO_OVERFLOW_SIMPLE 1 block_group->fs_info->sectorsize
NO_OVERFLOW_SIMPLE 1 block_group->full_stripe_len
NO_OVERFLOW_SIMPLE 1 block_group->pinned
NO_OVERFLOW_SIMPLE 1 block_group->reserved
NO_OVERFLOW_SIMPLE 1 block_group->space_info->bytes_may_use
HALF_LOCKED2 &ctl->cache_writeout_mutex

fs/btrfs/free-space-cache.c btrfs_return_cluster_to_free_space() -> btrfs_discard_queue_work()

Type Parameter Key Value
PARAM_VALUE 0 discard_ctl 4096-ptr_max
PARAM_VALUE 1 block_group 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.next->next 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.next->prev 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.prev->next 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.prev->prev 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->free_space_bytes.rb_leftmost 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->free_space_bytes.rb_root.rb_node 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->tree_lock.rlock.dep_map->name 0-255
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work->timer->entry.pprev 4096-ptr_max
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.timer.is_hard 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.timer.is_lazy 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.timer.is_queued 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.timer.is_soft 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.entry.next->next 1-u64max
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.entry.prev->prev 1-u64max
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.flags 0-4294967295
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.is_queued 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.lockdep_map->name 0-255
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.wq->dfl_pwq 0-s64max
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.wq->saved_max_active s32min-s32max
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.wq->saved_min_active s32min-s32max
PARAM_VALUE 1 *block_group->fs_info->discard_ctl.work.timer->entry.pprev 4096-ptr_max
DATA_SOURCE 1 block_group $0 [m]
PREEMPT_ADD
RX_PATH
TASK_NOT_RUNNING
NOCHECK_CALL
LOCK2 &cluster->refill_lock
HALF_LOCKED2 &space_info->groups_sem
TYPE_LOCK (struct btrfs_free_cluster)->refill_lock

fs/btrfs/block-group.c btrfs_delete_unused_bgs() -> btrfs_discard_queue_work()

Type Parameter Key Value
PARAM_VALUE 0 discard_ctl 4096-ptr_max
PARAM_VALUE 1 block_group 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.next->next 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.next->prev 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.prev->next 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.prev->prev 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->tree_lock.rlock.dep_map->name 0-255
PARAM_VALUE 1 block_group->fs_info->discard_ctl->work.timer->entry.pprev 4096-ptr_max
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.timer.is_queued 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.entry.next->prev 4096-ptr_max
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.entry.prev->next 1-u64max
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.is_hard 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.is_lazy 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.is_queued 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.is_soft 0-1
PARAM_VALUE 1 block_group->fs_info->sb->s_cop->inode_info_offs 1632,1720,1808,2632,2648
PARAM_VALUE 1 block_group->space_info->groups_sem.first_waiter->handoff_set 0-1
PARAM_VALUE 1 block_group->space_info->groups_sem.first_waiter->type 0-1
PARAM_VALUE 1 *block_group->fs_info->discard_ctl.work.timer->entry->next->pprev 1-u64max
PARAM_VALUE 1 *block_group->fs_info->discard_ctl.work.timer->entry.pprev 4096-ptr_max
CAPPED_DATA 1 block_group 1
RX_PATH
TASK_NOT_RUNNING
NOCHECK_CALL
LOCK2 &fs_info->reclaim_bgs_lock
TYPE_LOCK (struct btrfs_fs_info)->reclaim_bgs_lock

fs/btrfs/block-group.c btrfs_delete_unused_bgs() -> btrfs_discard_queue_work()

Type Parameter Key Value
PARAM_VALUE 0 discard_ctl 4096-ptr_max
PARAM_VALUE 1 block_group 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.next->next 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.next->prev 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.prev->next 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.prev->prev 4096-ptr_max
PARAM_VALUE 1 block_group->fs_info->discard_ctl->work.timer->entry.pprev 4096-ptr_max
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.timer.is_queued 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.entry.next->prev 4096-ptr_max
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.entry.prev->next 1-u64max
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.is_hard 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.is_lazy 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.is_queued 0-1
PARAM_VALUE 1 block_group->fs_info->discard_ctl.work.work.is_soft 0-1
PARAM_VALUE 1 block_group->fs_info->sb->s_cop->inode_info_offs 1632,1720,1808,2632,2648
PARAM_VALUE 1 block_group->lock.rlock.dep_map->name 0-255
PARAM_VALUE 1 block_group->space_info 4096-ptr_max
PARAM_VALUE 1 block_group->space_info->fs_info->balance_lock.rlock.dep_map->name 0-255
PARAM_VALUE 1 block_group->space_info->groups_sem.first_waiter->handoff_set 0-1
PARAM_VALUE 1 block_group->space_info->groups_sem.first_waiter->type 0-1
PARAM_VALUE 1 block_group->space_info->lock.rlock.dep_map->name 0-255
PARAM_VALUE 1 block_group->start 0-18446744073709551614
PARAM_VALUE 1 *block_group->fs_info->discard_ctl.work.timer->entry->next->pprev 1-u64max
PARAM_VALUE 1 *block_group->fs_info->discard_ctl.work.timer->entry.pprev 4096-ptr_max
CAPPED_DATA 1 block_group 1
CAPPED_DATA 1 block_group->start 1
CAPPED_DATA 1 &block_group->discard_list 1
CAPPED_DATA 1 &block_group->list 1
PARAM_COMPARE 1 &block_group->discard_list != $1->discard_list.next
RX_PATH
TASK_NOT_RUNNING
NOCHECK_CALL
LOCK2 &fs_info->reclaim_bgs_lock
TYPE_LOCK (struct btrfs_fs_info)->reclaim_bgs_lock

fs/btrfs/block-group.c btrfs_mark_bg_fully_remapped() -> btrfs_discard_queue_work()

Type Parameter Key Value
PARAM_VALUE 0 discard_ctl 4096-ptr_max
PARAM_VALUE 1 block_group 4096-ptr_max
PARAM_VALUE 1 block_group->fs_info->sb->s_cop->inode_info_offs 1632,1720,1808,2632,2648,2712
PARAM_VALUE 1 block_group->identity_remap_count 0
PARAM_VALUE 1 block_group->io_ctl.inode->i_mapping->i_mmap_rwsem.first_waiter->handoff_set 0-1
PARAM_VALUE 1 block_group->io_ctl.inode->i_mapping->i_mmap_rwsem.first_waiter->type 0-1
PARAM_VALUE 1 block_group->lock.rlock.dep_map->name 0-255
PARAM_VALUE 1 block_group->space_info->groups_sem.first_waiter->handoff_set 0-1
PARAM_VALUE 1 block_group->space_info->groups_sem.first_waiter->type 0-1
PARAM_VALUE 1 block_group->space_info->lock.rlock.dep_map->name 0-255
DATA_SOURCE 1 block_group $0
RX_PATH
TASK_NOT_RUNNING
NOCHECK_CALL
HALF_LOCKED2 &fs_info->remap_mutex

fs/btrfs/block-group.c read_one_block_group() -> btrfs_discard_queue_work()

Type Parameter Key Value
PARAM_VALUE 0 discard_ctl 4096-ptr_max
PARAM_VALUE 1 block_group 4096-ptr_max
PARAM_VALUE 1 block_group->active_bg_list.next->next 4096-ptr_max
PARAM_VALUE 1 block_group->active_bg_list.prev->next 4096-ptr_max
PARAM_VALUE 1 block_group->active_bg_list.prev->prev 4096-ptr_max
PARAM_VALUE 1 block_group->bg_list.next 4096-ptr_max
PARAM_VALUE 1 block_group->bg_list.next->next 4096-ptr_max
PARAM_VALUE 1 block_group->bg_list.prev->next 4096-ptr_max
PARAM_VALUE 1 block_group->bg_list.prev->prev 4096-ptr_max
PARAM_VALUE 1 block_group->cache_node.__rb_parent_color 1
PARAM_VALUE 1 block_group->cache_node.rb_left 4096-ptr_max
PARAM_VALUE 1 block_group->cache_node.rb_right 4096-ptr_max
PARAM_VALUE 1 block_group->cluster_list.next->next 4096-ptr_max
PARAM_VALUE 1 block_group->cluster_list.prev->next 4096-ptr_max
PARAM_VALUE 1 block_group->cluster_list.prev->prev 4096-ptr_max
PARAM_VALUE 1 block_group->data_rwsem.dep_map->name 0-255
PARAM_VALUE 1 block_group->dirty_list.next->next 4096-ptr_max
PARAM_VALUE 1 block_group->dirty_list.prev->next 4096-ptr_max
PARAM_VALUE 1 block_group->dirty_list.prev->prev 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.next->next 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.prev->next 4096-ptr_max
PARAM_VALUE 1 block_group->discard_list.prev->prev 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->block_group 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->block_group->fs_info 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->cache_writeout_mutex.dep_map->name 0-255
PARAM_VALUE 1 block_group->free_space_ctl->cache_writeout_mutex.magic 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->extents_thresh 157
PARAM_VALUE 1 block_group->free_space_ctl->trimming_ranges.next 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->trimming_ranges.next->next 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->trimming_ranges.prev 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->trimming_ranges.prev->next 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_ctl->trimming_ranges.prev->prev 4096-ptr_max
PARAM_VALUE 1 block_group->free_space_lock.dep_map->name 0-255
PARAM_VALUE 1 block_group->fs_info 4096-ptr_max
PARAM_VALUE 1 block_group->fs_info->block_group_cache_lock.dep_map->name 0-255
PARAM_VALUE 1 block_group->fs_info->block_group_cache_lock.owner (-1)
PARAM_VALUE 1 block_group->fs_info->block_group_cache_lock.owner_cpu u32max
PARAM_VALUE 1 block_group->fs_info->block_group_cache_tree.rb_leftmost 4096-ptr_max
PARAM_VALUE 1 block_group->fs_info->block_group_cache_tree.rb_root.rb_node 4096-ptr_max
PARAM_VALUE 1 block_group->fs_info->mapping_tree_lock.dep_map->name 0-255
PARAM_VALUE 1 block_group->io_list.next->next 4096-ptr_max
PARAM_VALUE 1 block_group->io_list.prev->next 4096-ptr_max
PARAM_VALUE 1 block_group->io_list.prev->prev 4096-ptr_max
PARAM_VALUE 1 block_group->list.next->next 4096-ptr_max
PARAM_VALUE 1 block_group->list.prev->next 4096-ptr_max
PARAM_VALUE 1 block_group->list.prev->prev 4096-ptr_max
PARAM_VALUE 1 block_group->remap_bytes 0
PARAM_VALUE 1 block_group->ro_list.next->next 4096-ptr_max
PARAM_VALUE 1 block_group->ro_list.prev->next 4096-ptr_max
PARAM_VALUE 1 block_group->ro_list.prev->prev 4096-ptr_max
PARAM_VALUE 1 block_group->space_info 4096-ptr_max
PARAM_VALUE 1 block_group->space_info->fs_info->balance_lock.rlock.dep_map->name 0-255
PARAM_VALUE 1 block_group->space_info->fs_info->fs_devices->per_profile_lock.rlock.dep_map->name 0-255
PARAM_VALUE 1 block_group->space_info->groups_sem.dep_map->name 0-255
PARAM_VALUE 1 block_group->space_info->groups_sem.first_waiter->handoff_set 1
PARAM_VALUE 1 block_group->space_info->groups_sem.first_waiter->list.next 2624917664208203776
PARAM_VALUE 1 block_group->space_info->groups_sem.first_waiter->list.prev 2624917664208203776
PARAM_VALUE 1 block_group->space_info->groups_sem.first_waiter->type 0-1
PARAM_VALUE 1 block_group->space_info->groups_sem.osq.tail.counter 0-s32max
PARAM_VALUE 1 block_group->space_info->lock.rlock.dep_map->name 0-255
PARAM_VALUE 1 block_group->start 0-18446744073709551614
PARAM_VALUE 1 block_group->used 0
CAPPED_DATA 1 block_group->start 1
CAPPED_DATA 1 &block_group->bg_list 1
DATA_SOURCE 1 block_group r btrfs_create_block_group
PARAM_COMPARE 1 &block_group->bg_list == $1->bg_list.next
NOCHECK_CALL
NO_OVERFLOW_SIMPLE 1 block_group->free_space_ctl->block_group->full_stripe_len

fs/btrfs/discard.c btrfs_discard_punt_unused_bgs_list() -> btrfs_discard_queue_work()

Type Parameter Key Value
PARAM_VALUE 0 discard_ctl 4096-ptr_max
PARAM_VALUE 1 block_group 4096-ptr_max
CAPPED_DATA 1 &block_group->bg_list 1
PREEMPT_ADD <- disables preempt
RX_PATH
TASK_NOT_RUNNING
NOCHECK_CALL
LOCK2 &fs_info->unused_bgs_lock
TYPE_LOCK (struct btrfs_fs_info)->unused_bgs_lock