btrfs: update function comments

Update, reformat or reword function comments. This also removes the kdoc
marker so we don't get reports when the function name is missing.

Changes made:

- remove kdoc markers
- reformat the brief description to be a proper sentence
- reword to imperative voice
- align parameter list
- fix typos

Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
David Sterba 2022-10-27 14:21:42 +02:00
Родитель 1751850fbd
Коммит 43dd529abe
20 изменённых файлов: 289 добавлений и 269 удалений

Просмотреть файл

@ -299,7 +299,7 @@ struct btrfs_block_group *btrfs_next_block_group(
return cache; return cache;
} }
/** /*
* Check if we can do a NOCOW write for a given extent. * Check if we can do a NOCOW write for a given extent.
* *
* @fs_info: The filesystem information object. * @fs_info: The filesystem information object.
@ -340,11 +340,9 @@ struct btrfs_block_group *btrfs_inc_nocow_writers(struct btrfs_fs_info *fs_info,
return bg; return bg;
} }
/** /*
* Decrement the number of NOCOW writers in a block group. * Decrement the number of NOCOW writers in a block group.
* *
* @bg: The block group.
*
* This is meant to be called after a previous call to btrfs_inc_nocow_writers(), * This is meant to be called after a previous call to btrfs_inc_nocow_writers(),
* and on the block group returned by that call. Typically this is called after * and on the block group returned by that call. Typically this is called after
* creating an ordered extent for a NOCOW write, to prevent races with scrub and * creating an ordered extent for a NOCOW write, to prevent races with scrub and
@ -1813,8 +1811,8 @@ static void set_avail_alloc_bits(struct btrfs_fs_info *fs_info, u64 flags)
write_sequnlock(&fs_info->profiles_lock); write_sequnlock(&fs_info->profiles_lock);
} }
/** /*
* Map a physical disk address to a list of logical addresses * Map a physical disk address to a list of logical addresses.
* *
* @fs_info: the filesystem * @fs_info: the filesystem
* @chunk_start: logical address of block group * @chunk_start: logical address of block group
@ -3421,8 +3419,9 @@ int btrfs_update_block_group(struct btrfs_trans_handle *trans,
return ret; return ret;
} }
/** /*
* btrfs_add_reserved_bytes - update the block_group and space info counters * Update the block_group and space info counters.
*
* @cache: The cache we are manipulating * @cache: The cache we are manipulating
* @ram_bytes: The number of bytes of file content, and will be same to * @ram_bytes: The number of bytes of file content, and will be same to
* @num_bytes except for the compress path. * @num_bytes except for the compress path.
@ -3465,8 +3464,9 @@ int btrfs_add_reserved_bytes(struct btrfs_block_group *cache,
return ret; return ret;
} }
/** /*
* btrfs_free_reserved_bytes - update the block_group and space info counters * Update the block_group and space info counters.
*
* @cache: The cache we are manipulating * @cache: The cache we are manipulating
* @num_bytes: The number of bytes in question * @num_bytes: The number of bytes in question
* @delalloc: The blocks are allocated for the delalloc write * @delalloc: The blocks are allocated for the delalloc write

Просмотреть файл

@ -2363,7 +2363,7 @@ int btrfs_search_backwards(struct btrfs_root *root, struct btrfs_key *key,
return ret; return ret;
} }
/** /*
* Search for a valid slot for the given path. * Search for a valid slot for the given path.
* *
* @root: The root node of the tree. * @root: The root node of the tree.
@ -3985,14 +3985,15 @@ void btrfs_extend_item(struct btrfs_path *path, u32 data_size)
} }
} }
/** /*
* setup_items_for_insert - Helper called before inserting one or more items * Make space in the node before inserting one or more items.
* to a leaf. Main purpose is to save stack depth by doing the bulk of the work
* in a function that doesn't call btrfs_search_slot
* *
* @root: root we are inserting items to * @root: root we are inserting items to
* @path: points to the leaf/slot where we are going to insert new items * @path: points to the leaf/slot where we are going to insert new items
* @batch: information about the batch of items to insert * @batch: information about the batch of items to insert
*
* Main purpose is to save stack depth by doing the bulk of the work in a
* function that doesn't call btrfs_search_slot
*/ */
static void setup_items_for_insert(struct btrfs_root *root, struct btrfs_path *path, static void setup_items_for_insert(struct btrfs_root *root, struct btrfs_path *path,
const struct btrfs_item_batch *batch) const struct btrfs_item_batch *batch)

Просмотреть файл

@ -202,8 +202,8 @@ void btrfs_free_reserved_data_space(struct btrfs_inode *inode,
btrfs_qgroup_free_data(inode, reserved, start, len); btrfs_qgroup_free_data(inode, reserved, start, len);
} }
/** /*
* Release any excessive reservation * Release any excessive reservations for an inode.
* *
* @inode: the inode we need to release from * @inode: the inode we need to release from
* @qgroup_free: free or convert qgroup meta. Unlike normal operation, qgroup * @qgroup_free: free or convert qgroup meta. Unlike normal operation, qgroup
@ -377,8 +377,8 @@ int btrfs_delalloc_reserve_metadata(struct btrfs_inode *inode, u64 num_bytes,
return 0; return 0;
} }
/** /*
* Release a metadata reservation for an inode * Release a metadata reservation for an inode.
* *
* @inode: the inode to release the reservation for. * @inode: the inode to release the reservation for.
* @num_bytes: the number of bytes we are releasing. * @num_bytes: the number of bytes we are releasing.
@ -405,8 +405,9 @@ void btrfs_delalloc_release_metadata(struct btrfs_inode *inode, u64 num_bytes,
btrfs_inode_rsv_release(inode, qgroup_free); btrfs_inode_rsv_release(inode, qgroup_free);
} }
/** /*
* btrfs_delalloc_release_extents - release our outstanding_extents * Release our outstanding_extents for an inode.
*
* @inode: the inode to balance the reservation for. * @inode: the inode to balance the reservation for.
* @num_bytes: the number of bytes we originally reserved with * @num_bytes: the number of bytes we originally reserved with
* *
@ -433,9 +434,9 @@ void btrfs_delalloc_release_extents(struct btrfs_inode *inode, u64 num_bytes)
btrfs_inode_rsv_release(inode, true); btrfs_inode_rsv_release(inode, true);
} }
/** /*
* btrfs_delalloc_reserve_space - reserve data and metadata space for * Reserve data and metadata space for delalloc
* delalloc *
* @inode: inode we're writing to * @inode: inode we're writing to
* @start: start range we are writing to * @start: start range we are writing to
* @len: how long the range we are writing to * @len: how long the range we are writing to
@ -444,19 +445,19 @@ void btrfs_delalloc_release_extents(struct btrfs_inode *inode, u64 num_bytes)
* *
* This will do the following things * This will do the following things
* *
* - reserve space in data space info for num bytes * - reserve space in data space info for num bytes and reserve precious
* and reserve precious corresponding qgroup space * corresponding qgroup space
* (Done in check_data_free_space) * (Done in check_data_free_space)
* *
* - reserve space for metadata space, based on the number of outstanding * - reserve space for metadata space, based on the number of outstanding
* extents and how much csums will be needed * extents and how much csums will be needed also reserve metadata space in a
* also reserve metadata space in a per root over-reserve method. * per root over-reserve method.
* - add to the inodes->delalloc_bytes * - add to the inodes->delalloc_bytes
* - add it to the fs_info's delalloc inodes list. * - add it to the fs_info's delalloc inodes list.
* (Above 3 all done in delalloc_reserve_metadata) * (Above 3 all done in delalloc_reserve_metadata)
* *
* Return 0 for success * Return 0 for success
* Return <0 for error(-ENOSPC or -EQUOT) * Return <0 for error(-ENOSPC or -EDQUOT)
*/ */
int btrfs_delalloc_reserve_space(struct btrfs_inode *inode, int btrfs_delalloc_reserve_space(struct btrfs_inode *inode,
struct extent_changeset **reserved, u64 start, u64 len) struct extent_changeset **reserved, u64 start, u64 len)
@ -475,7 +476,7 @@ int btrfs_delalloc_reserve_space(struct btrfs_inode *inode,
return ret; return ret;
} }
/** /*
* Release data and metadata space for delalloc * Release data and metadata space for delalloc
* *
* @inode: inode we're releasing space for * @inode: inode we're releasing space for
@ -484,10 +485,10 @@ int btrfs_delalloc_reserve_space(struct btrfs_inode *inode,
* @len: length of the space already reserved * @len: length of the space already reserved
* @qgroup_free: should qgroup reserved-space also be freed * @qgroup_free: should qgroup reserved-space also be freed
* *
* This function will release the metadata space that was not used and will * Release the metadata space that was not used and will decrement
* decrement ->delalloc_bytes and remove it from the fs_info delalloc_inodes * ->delalloc_bytes and remove it from the fs_info->delalloc_inodes list if
* list if there are no delalloc bytes left. * there are no delalloc bytes left. Also it will handle the qgroup reserved
* Also it will handle the qgroup reserved space. * space.
*/ */
void btrfs_delalloc_release_space(struct btrfs_inode *inode, void btrfs_delalloc_release_space(struct btrfs_inode *inode,
struct extent_changeset *reserved, struct extent_changeset *reserved,

Просмотреть файл

@ -71,14 +71,14 @@ int btrfs_should_throttle_delayed_refs(struct btrfs_trans_handle *trans)
return btrfs_check_space_for_delayed_refs(trans->fs_info); return btrfs_check_space_for_delayed_refs(trans->fs_info);
} }
/** /*
* Release a ref head's reservation * Release a ref head's reservation.
* *
* @fs_info: the filesystem * @fs_info: the filesystem
* @nr: number of items to drop * @nr: number of items to drop
* *
* This drops the delayed ref head's count from the delayed refs rsv and frees * Drops the delayed ref head's count from the delayed refs rsv and free any
* any excess reservation we had. * excess reservation we had.
*/ */
void btrfs_delayed_refs_rsv_release(struct btrfs_fs_info *fs_info, int nr) void btrfs_delayed_refs_rsv_release(struct btrfs_fs_info *fs_info, int nr)
{ {
@ -104,8 +104,7 @@ void btrfs_delayed_refs_rsv_release(struct btrfs_fs_info *fs_info, int nr)
} }
/* /*
* btrfs_update_delayed_refs_rsv - adjust the size of the delayed refs rsv * Adjust the size of the delayed refs rsv.
* @trans - the trans that may have generated delayed refs
* *
* This is to be called anytime we may have adjusted trans->delayed_ref_updates, * This is to be called anytime we may have adjusted trans->delayed_ref_updates,
* it'll calculate the additional size and add it to the delayed_refs_rsv. * it'll calculate the additional size and add it to the delayed_refs_rsv.
@ -139,8 +138,8 @@ void btrfs_update_delayed_refs_rsv(struct btrfs_trans_handle *trans)
trans->delayed_ref_updates = 0; trans->delayed_ref_updates = 0;
} }
/** /*
* Transfer bytes to our delayed refs rsv * Transfer bytes to our delayed refs rsv.
* *
* @fs_info: the filesystem * @fs_info: the filesystem
* @src: source block rsv to transfer from * @src: source block rsv to transfer from
@ -188,8 +187,8 @@ void btrfs_migrate_to_delayed_refs_rsv(struct btrfs_fs_info *fs_info,
delayed_refs_rsv->space_info, to_free); delayed_refs_rsv->space_info, to_free);
} }
/** /*
* Refill based on our delayed refs usage * Refill based on our delayed refs usage.
* *
* @fs_info: the filesystem * @fs_info: the filesystem
* @flush: control how we can flush for this reservation. * @flush: control how we can flush for this reservation.

Просмотреть файл

@ -62,7 +62,7 @@
#define BTRFS_DISCARD_MAX_DELAY_MSEC (1000UL) #define BTRFS_DISCARD_MAX_DELAY_MSEC (1000UL)
#define BTRFS_DISCARD_MAX_IOPS (10U) #define BTRFS_DISCARD_MAX_IOPS (10U)
/* Montonically decreasing minimum length filters after index 0 */ /* Monotonically decreasing minimum length filters after index 0 */
static int discard_minlen[BTRFS_NR_DISCARD_LISTS] = { static int discard_minlen[BTRFS_NR_DISCARD_LISTS] = {
0, 0,
BTRFS_ASYNC_DISCARD_MAX_FILTER, BTRFS_ASYNC_DISCARD_MAX_FILTER,
@ -147,8 +147,9 @@ static bool remove_from_discard_list(struct btrfs_discard_ctl *discard_ctl,
return running; return running;
} }
/** /*
* find_next_block_group - find block_group that's up next for discarding * Find block_group that's up next for discarding.
*
* @discard_ctl: discard control * @discard_ctl: discard control
* @now: current time * @now: current time
* *
@ -185,17 +186,17 @@ static struct btrfs_block_group *find_next_block_group(
return ret_block_group; return ret_block_group;
} }
/** /*
* Wrap find_next_block_group() * Look up next block group and set it for use.
* *
* @discard_ctl: discard control * @discard_ctl: discard control
* @discard_state: the discard_state of the block_group after state management * @discard_state: the discard_state of the block_group after state management
* @discard_index: the discard_index of the block_group after state management * @discard_index: the discard_index of the block_group after state management
* @now: time when discard was invoked, in ns * @now: time when discard was invoked, in ns
* *
* This wraps find_next_block_group() and sets the block_group to be in use. * Wrap find_next_block_group() and set the block_group to be in use.
* discard_state's control flow is managed here. Variables related to * @discard_state's control flow is managed here. Variables related to
* discard_state are reset here as needed (eg discard_cursor). @discard_state * @discard_state are reset here as needed (eg. @discard_cursor). @discard_state
* and @discard_index are remembered as it may change while we're discarding, * and @discard_index are remembered as it may change while we're discarding,
* but we want the discard to execute in the context determined here. * but we want the discard to execute in the context determined here.
*/ */
@ -234,8 +235,9 @@ again:
return block_group; return block_group;
} }
/** /*
* btrfs_discard_check_filter - updates a block groups filters * Update a block group's filters.
*
* @block_group: block group of interest * @block_group: block group of interest
* @bytes: recently freed region size after coalescing * @bytes: recently freed region size after coalescing
* *
@ -272,8 +274,9 @@ void btrfs_discard_check_filter(struct btrfs_block_group *block_group,
} }
} }
/** /*
* btrfs_update_discard_index - moves a block group along the discard lists * Move a block group along the discard lists.
*
* @discard_ctl: discard control * @discard_ctl: discard control
* @block_group: block_group of interest * @block_group: block_group of interest
* *
@ -292,13 +295,14 @@ static void btrfs_update_discard_index(struct btrfs_discard_ctl *discard_ctl,
add_to_discard_list(discard_ctl, block_group); add_to_discard_list(discard_ctl, block_group);
} }
/** /*
* btrfs_discard_cancel_work - remove a block_group from the discard lists * Remove a block_group from the discard lists.
*
* @discard_ctl: discard control * @discard_ctl: discard control
* @block_group: block_group of interest * @block_group: block_group of interest
* *
* This removes @block_group from the discard lists. If necessary, it waits on * Remove @block_group from the discard lists. If necessary, wait on the
* the current work and then reschedules the delayed work. * current work and then reschedule the delayed work.
*/ */
void btrfs_discard_cancel_work(struct btrfs_discard_ctl *discard_ctl, void btrfs_discard_cancel_work(struct btrfs_discard_ctl *discard_ctl,
struct btrfs_block_group *block_group) struct btrfs_block_group *block_group)
@ -309,12 +313,13 @@ void btrfs_discard_cancel_work(struct btrfs_discard_ctl *discard_ctl,
} }
} }
/** /*
* btrfs_discard_queue_work - handles queuing the block_groups * Handles queuing the block_groups.
*
* @discard_ctl: discard control * @discard_ctl: discard control
* @block_group: block_group of interest * @block_group: block_group of interest
* *
* This maintains the LRU order of the discard lists. * Maintain the LRU order of the discard lists.
*/ */
void btrfs_discard_queue_work(struct btrfs_discard_ctl *discard_ctl, void btrfs_discard_queue_work(struct btrfs_discard_ctl *discard_ctl,
struct btrfs_block_group *block_group) struct btrfs_block_group *block_group)
@ -384,7 +389,8 @@ static void __btrfs_discard_schedule_work(struct btrfs_discard_ctl *discard_ctl,
} }
/* /*
* btrfs_discard_schedule_work - responsible for scheduling the discard work * Responsible for scheduling the discard work.
*
* @discard_ctl: discard control * @discard_ctl: discard control
* @override: override the current timer * @override: override the current timer
* *
@ -402,15 +408,16 @@ void btrfs_discard_schedule_work(struct btrfs_discard_ctl *discard_ctl,
spin_unlock(&discard_ctl->lock); spin_unlock(&discard_ctl->lock);
} }
/** /*
* btrfs_finish_discard_pass - determine next step of a block_group * Determine next step of a block_group.
*
* @discard_ctl: discard control * @discard_ctl: discard control
* @block_group: block_group of interest * @block_group: block_group of interest
* *
* This determines the next step for a block group after it's finished going * Determine the next step for a block group after it's finished going through
* through a pass on a discard list. If it is unused and fully trimmed, we can * a pass on a discard list. If it is unused and fully trimmed, we can mark it
* mark it unused and send it to the unused_bgs path. Otherwise, pass it onto * unused and send it to the unused_bgs path. Otherwise, pass it onto the
* the appropriate filter list or let it fall off. * appropriate filter list or let it fall off.
*/ */
static void btrfs_finish_discard_pass(struct btrfs_discard_ctl *discard_ctl, static void btrfs_finish_discard_pass(struct btrfs_discard_ctl *discard_ctl,
struct btrfs_block_group *block_group) struct btrfs_block_group *block_group)
@ -427,12 +434,13 @@ static void btrfs_finish_discard_pass(struct btrfs_discard_ctl *discard_ctl,
} }
} }
/** /*
* btrfs_discard_workfn - discard work function * Discard work queue callback
*
* @work: work * @work: work
* *
* This finds the next block_group to start discarding and then discards a * Find the next block_group to start discarding and then discard a single
* single region. It does this in a two-pass fashion: first extents and second * region. It does this in a two-pass fashion: first extents and second
* bitmaps. Completely discarded block groups are sent to the unused_bgs path. * bitmaps. Completely discarded block groups are sent to the unused_bgs path.
*/ */
static void btrfs_discard_workfn(struct work_struct *work) static void btrfs_discard_workfn(struct work_struct *work)
@ -508,11 +516,12 @@ static void btrfs_discard_workfn(struct work_struct *work)
spin_unlock(&discard_ctl->lock); spin_unlock(&discard_ctl->lock);
} }
/** /*
* btrfs_run_discard_work - determines if async discard should be running * Determine if async discard should be running.
*
* @discard_ctl: discard control * @discard_ctl: discard control
* *
* Checks if the file system is writeable and BTRFS_FS_DISCARD_RUNNING is set. * Check if the file system is writeable and BTRFS_FS_DISCARD_RUNNING is set.
*/ */
bool btrfs_run_discard_work(struct btrfs_discard_ctl *discard_ctl) bool btrfs_run_discard_work(struct btrfs_discard_ctl *discard_ctl)
{ {
@ -524,8 +533,9 @@ bool btrfs_run_discard_work(struct btrfs_discard_ctl *discard_ctl)
test_bit(BTRFS_FS_DISCARD_RUNNING, &fs_info->flags)); test_bit(BTRFS_FS_DISCARD_RUNNING, &fs_info->flags));
} }
/** /*
* btrfs_discard_calc_delay - recalculate the base delay * Recalculate the base delay.
*
* @discard_ctl: discard control * @discard_ctl: discard control
* *
* Recalculate the base delay which is based off the total number of * Recalculate the base delay which is based off the total number of
@ -546,7 +556,7 @@ void btrfs_discard_calc_delay(struct btrfs_discard_ctl *discard_ctl)
spin_lock(&discard_ctl->lock); spin_lock(&discard_ctl->lock);
/* /*
* The following is to fix a potential -1 discrepenancy that we're not * The following is to fix a potential -1 discrepancy that we're not
* sure how to reproduce. But given that this is the only place that * sure how to reproduce. But given that this is the only place that
* utilizes these numbers and this is only called by from * utilizes these numbers and this is only called by from
* btrfs_finish_extent_commit() which is synchronized, we can correct * btrfs_finish_extent_commit() which is synchronized, we can correct
@ -579,13 +589,14 @@ void btrfs_discard_calc_delay(struct btrfs_discard_ctl *discard_ctl)
spin_unlock(&discard_ctl->lock); spin_unlock(&discard_ctl->lock);
} }
/** /*
* btrfs_discard_update_discardable - propagate discard counters * Propagate discard counters.
*
* @block_group: block_group of interest * @block_group: block_group of interest
* *
* This propagates deltas of counters up to the discard_ctl. It maintains a * Propagate deltas of counters up to the discard_ctl. It maintains a current
* current counter and a previous counter passing the delta up to the global * counter and a previous counter passing the delta up to the global stat.
* stat. Then the current counter value becomes the previous counter value. * Then the current counter value becomes the previous counter value.
*/ */
void btrfs_discard_update_discardable(struct btrfs_block_group *block_group) void btrfs_discard_update_discardable(struct btrfs_block_group *block_group)
{ {
@ -620,8 +631,9 @@ void btrfs_discard_update_discardable(struct btrfs_block_group *block_group)
} }
} }
/** /*
* btrfs_discard_punt_unused_bgs_list - punt unused_bgs list to discard lists * Punt unused_bgs list to discard lists.
*
* @fs_info: fs_info of interest * @fs_info: fs_info of interest
* *
* The unused_bgs list needs to be punted to the discard lists because the * The unused_bgs list needs to be punted to the discard lists because the
@ -645,8 +657,9 @@ void btrfs_discard_punt_unused_bgs_list(struct btrfs_fs_info *fs_info)
spin_unlock(&fs_info->unused_bgs_lock); spin_unlock(&fs_info->unused_bgs_lock);
} }
/** /*
* btrfs_discard_purge_list - purge discard lists * Purge discard lists.
*
* @discard_ctl: discard control * @discard_ctl: discard control
* *
* If we are disabling async discard, we may have intercepted block groups that * If we are disabling async discard, we may have intercepted block groups that

Просмотреть файл

@ -1298,7 +1298,7 @@ static void end_bio_extent_readpage(struct btrfs_bio *bbio)
bio_put(bio); bio_put(bio);
} }
/** /*
* Populate every free slot in a provided array with pages. * Populate every free slot in a provided array with pages.
* *
* @nr_pages: number of pages to allocate * @nr_pages: number of pages to allocate
@ -1334,8 +1334,8 @@ int btrfs_alloc_page_array(unsigned int nr_pages, struct page **page_array)
return 0; return 0;
} }
/** /*
* Attempt to add a page to bio * Attempt to add a page to bio.
* *
* @bio_ctrl: record both the bio, and its bio_flags * @bio_ctrl: record both the bio, and its bio_flags
* @page: page to add to the bio * @page: page to add to the bio
@ -3066,7 +3066,7 @@ retry:
return ret; return ret;
} }
/** /*
* Walk the list of dirty pages of the given address space and write all of them. * Walk the list of dirty pages of the given address space and write all of them.
* *
* @mapping: address space structure to write * @mapping: address space structure to write
@ -5460,8 +5460,9 @@ static inline void eb_bitmap_offset(const struct extent_buffer *eb,
*page_offset = offset_in_page(offset); *page_offset = offset_in_page(offset);
} }
/** /*
* extent_buffer_test_bit - determine whether a bit in a bitmap item is set * Determine whether a bit in a bitmap item is set.
*
* @eb: the extent buffer * @eb: the extent buffer
* @start: offset of the bitmap item in the extent buffer * @start: offset of the bitmap item in the extent buffer
* @nr: bit number to test * @nr: bit number to test
@ -5481,8 +5482,9 @@ int extent_buffer_test_bit(const struct extent_buffer *eb, unsigned long start,
return 1U & (kaddr[offset] >> (nr & (BITS_PER_BYTE - 1))); return 1U & (kaddr[offset] >> (nr & (BITS_PER_BYTE - 1)));
} }
/** /*
* extent_buffer_bitmap_set - set an area of a bitmap * Set an area of a bitmap to 1.
*
* @eb: the extent buffer * @eb: the extent buffer
* @start: offset of the bitmap item in the extent buffer * @start: offset of the bitmap item in the extent buffer
* @pos: bit number of the first bit * @pos: bit number of the first bit
@ -5523,8 +5525,9 @@ void extent_buffer_bitmap_set(const struct extent_buffer *eb, unsigned long star
} }
/** /*
* extent_buffer_bitmap_clear - clear an area of a bitmap * Clear an area of a bitmap.
*
* @eb: the extent buffer * @eb: the extent buffer
* @start: offset of the bitmap item in the extent buffer * @start: offset of the bitmap item in the extent buffer
* @pos: bit number of the first bit * @pos: bit number of the first bit

Просмотреть файл

@ -28,12 +28,9 @@ void __cold extent_map_exit(void)
kmem_cache_destroy(extent_map_cache); kmem_cache_destroy(extent_map_cache);
} }
/** /*
* extent_map_tree_init - initialize extent map tree * Initialize the extent tree @tree. Should be called for each new inode or
* @tree: tree to initialize * other user of the extent_map interface.
*
* Initialize the extent tree @tree. Should be called for each new inode
* or other user of the extent_map interface.
*/ */
void extent_map_tree_init(struct extent_map_tree *tree) void extent_map_tree_init(struct extent_map_tree *tree)
{ {
@ -42,12 +39,9 @@ void extent_map_tree_init(struct extent_map_tree *tree)
rwlock_init(&tree->lock); rwlock_init(&tree->lock);
} }
/** /*
* alloc_extent_map - allocate new extent map structure * Allocate a new extent_map structure. The new structure is returned with a
* * reference count of one and needs to be freed using free_extent_map()
* Allocate a new extent_map structure. The new structure is
* returned with a reference count of one and needs to be
* freed using free_extent_map()
*/ */
struct extent_map *alloc_extent_map(void) struct extent_map *alloc_extent_map(void)
{ {
@ -62,12 +56,9 @@ struct extent_map *alloc_extent_map(void)
return em; return em;
} }
/** /*
* free_extent_map - drop reference count of an extent_map * Drop the reference out on @em by one and free the structure if the reference
* @em: extent map being released * count hits zero.
*
* Drops the reference out on @em by one and free the structure
* if the reference count hits zero.
*/ */
void free_extent_map(struct extent_map *em) void free_extent_map(struct extent_map *em)
{ {
@ -82,7 +73,7 @@ void free_extent_map(struct extent_map *em)
} }
} }
/* simple helper to do math around the end of an extent, handling wrap */ /* Do the math around the end of an extent, handling wrapping. */
static u64 range_end(u64 start, u64 len) static u64 range_end(u64 start, u64 len)
{ {
if (start + len < start) if (start + len < start)
@ -138,8 +129,8 @@ static int tree_insert(struct rb_root_cached *root, struct extent_map *em)
} }
/* /*
* search through the tree for an extent_map with a given offset. If * Search through the tree for an extent_map with a given offset. If it can't
* it can't be found, try to find some neighboring extents * be found, try to find some neighboring extents
*/ */
static struct rb_node *__tree_search(struct rb_root *root, u64 offset, static struct rb_node *__tree_search(struct rb_root *root, u64 offset,
struct rb_node **prev_or_next_ret) struct rb_node **prev_or_next_ret)
@ -191,7 +182,7 @@ static struct rb_node *__tree_search(struct rb_root *root, u64 offset,
return NULL; return NULL;
} }
/* check to see if two extent_map structs are adjacent and safe to merge */ /* Check to see if two extent_map structs are adjacent and safe to merge. */
static int mergable_maps(struct extent_map *prev, struct extent_map *next) static int mergable_maps(struct extent_map *prev, struct extent_map *next)
{ {
if (test_bit(EXTENT_FLAG_PINNED, &prev->flags)) if (test_bit(EXTENT_FLAG_PINNED, &prev->flags))
@ -289,8 +280,9 @@ static void try_merge_map(struct extent_map_tree *tree, struct extent_map *em)
} }
} }
/** /*
* unpin_extent_cache - unpin an extent from the cache * Unpin an extent from the cache.
*
* @tree: tree to unpin the extent in * @tree: tree to unpin the extent in
* @start: logical offset in the file * @start: logical offset in the file
* @len: length of the extent * @len: length of the extent
@ -393,7 +385,7 @@ static void extent_map_device_clear_bits(struct extent_map *em, unsigned bits)
} }
} }
/** /*
* Add new extent map to the extent tree * Add new extent map to the extent tree
* *
* @tree: tree to insert new map in * @tree: tree to insert new map in
@ -452,8 +444,9 @@ __lookup_extent_mapping(struct extent_map_tree *tree,
return em; return em;
} }
/** /*
* lookup_extent_mapping - lookup extent_map * Lookup extent_map that intersects @start + @len range.
*
* @tree: tree to lookup in * @tree: tree to lookup in
* @start: byte offset to start the search * @start: byte offset to start the search
* @len: length of the lookup range * @len: length of the lookup range
@ -469,8 +462,9 @@ struct extent_map *lookup_extent_mapping(struct extent_map_tree *tree,
return __lookup_extent_mapping(tree, start, len, 1); return __lookup_extent_mapping(tree, start, len, 1);
} }
/** /*
* search_extent_mapping - find a nearby extent map * Find a nearby extent map intersecting @start + @len (not an exact search).
*
* @tree: tree to lookup in * @tree: tree to lookup in
* @start: byte offset to start the search * @start: byte offset to start the search
* @len: length of the lookup range * @len: length of the lookup range
@ -486,13 +480,14 @@ struct extent_map *search_extent_mapping(struct extent_map_tree *tree,
return __lookup_extent_mapping(tree, start, len, 0); return __lookup_extent_mapping(tree, start, len, 0);
} }
/** /*
* remove_extent_mapping - removes an extent_map from the extent tree * Remove an extent_map from the extent tree.
*
* @tree: extent tree to remove from * @tree: extent tree to remove from
* @em: extent map being removed * @em: extent map being removed
* *
* Removes @em from @tree. No reference counts are dropped, and no checks * Remove @em from @tree. No reference counts are dropped, and no checks
* are done to see if the range is in use * are done to see if the range is in use.
*/ */
void remove_extent_mapping(struct extent_map_tree *tree, struct extent_map *em) void remove_extent_mapping(struct extent_map_tree *tree, struct extent_map *em)
{ {
@ -615,8 +610,8 @@ static noinline int merge_extent_mapping(struct extent_map_tree *em_tree,
return add_extent_mapping(em_tree, em, 0); return add_extent_mapping(em_tree, em, 0);
} }
/** /*
* Add extent mapping into em_tree * Add extent mapping into em_tree.
* *
* @fs_info: the filesystem * @fs_info: the filesystem
* @em_tree: extent tree into which we want to insert the extent mapping * @em_tree: extent tree into which we want to insert the extent mapping

Просмотреть файл

@ -27,8 +27,8 @@
#define MAX_CSUM_ITEMS(r, size) (min_t(u32, __MAX_CSUM_ITEMS(r, size), \ #define MAX_CSUM_ITEMS(r, size) (min_t(u32, __MAX_CSUM_ITEMS(r, size), \
PAGE_SIZE)) PAGE_SIZE))
/** /*
* Set inode's size according to filesystem options * Set inode's size according to filesystem options.
* *
* @inode: inode we want to update the disk_i_size for * @inode: inode we want to update the disk_i_size for
* @new_i_size: i_size we want to set to, 0 if we use i_size * @new_i_size: i_size we want to set to, 0 if we use i_size
@ -67,8 +67,8 @@ void btrfs_inode_safe_disk_i_size_write(struct btrfs_inode *inode, u64 new_i_siz
spin_unlock(&inode->lock); spin_unlock(&inode->lock);
} }
/** /*
* Mark range within a file as having a new extent inserted * Mark range within a file as having a new extent inserted.
* *
* @inode: inode being modified * @inode: inode being modified
* @start: start file offset of the file extent we've inserted * @start: start file offset of the file extent we've inserted
@ -95,8 +95,8 @@ int btrfs_inode_set_file_extent_range(struct btrfs_inode *inode, u64 start,
EXTENT_DIRTY); EXTENT_DIRTY);
} }
/** /*
* Marks an inode range as not having a backing extent * Mark an inode range as not having a backing extent.
* *
* @inode: inode being modified * @inode: inode being modified
* @start: start file offset of the file extent we've inserted * @start: start file offset of the file extent we've inserted
@ -257,7 +257,7 @@ int btrfs_lookup_file_extent(struct btrfs_trans_handle *trans,
/* /*
* Find checksums for logical bytenr range [disk_bytenr, disk_bytenr + len) and * Find checksums for logical bytenr range [disk_bytenr, disk_bytenr + len) and
* estore the result to @dst. * store the result to @dst.
* *
* Return >0 for the number of sectors we found. * Return >0 for the number of sectors we found.
* Return 0 for the range [disk_bytenr, disk_bytenr + sectorsize) has no csum * Return 0 for the range [disk_bytenr, disk_bytenr + sectorsize) has no csum
@ -363,7 +363,7 @@ static int search_file_offset_in_bio(struct bio *bio, struct inode *inode,
return ret; return ret;
} }
/** /*
* Lookup the checksum for the read bio in csum tree. * Lookup the checksum for the read bio in csum tree.
* *
* @inode: inode that the bio is for. * @inode: inode that the bio is for.
@ -633,8 +633,8 @@ fail:
return ret; return ret;
} }
/** /*
* Calculate checksums of the data contained inside a bio * Calculate checksums of the data contained inside a bio.
* *
* @inode: Owner of the data inside the bio * @inode: Owner of the data inside the bio
* @bio: Contains the data to be checksummed * @bio: Contains the data to be checksummed
@ -749,15 +749,16 @@ blk_status_t btrfs_csum_one_bio(struct btrfs_inode *inode, struct bio *bio,
} }
/* /*
* helper function for csum removal, this expects the * Remove one checksum overlapping a range.
* key to describe the csum pointed to by the path, and it expects
* the csum to overlap the range [bytenr, len]
* *
* The csum should not be entirely contained in the range and the * This expects the key to describe the csum pointed to by the path, and it
* range should not be entirely contained in the csum. * expects the csum to overlap the range [bytenr, len]
* *
* This calls btrfs_truncate_item with the correct args based on the * The csum should not be entirely contained in the range and the range should
* overlap, and fixes up the key as required. * not be entirely contained in the csum.
*
* This calls btrfs_truncate_item with the correct args based on the overlap,
* and fixes up the key as required.
*/ */
static noinline void truncate_one_csum(struct btrfs_fs_info *fs_info, static noinline void truncate_one_csum(struct btrfs_fs_info *fs_info,
struct btrfs_path *path, struct btrfs_path *path,
@ -806,8 +807,7 @@ static noinline void truncate_one_csum(struct btrfs_fs_info *fs_info,
} }
/* /*
* deletes the csum items from the csum tree for a given * Delete the csum items from the csum tree for a given range of bytes.
* range of bytes.
*/ */
int btrfs_del_csums(struct btrfs_trans_handle *trans, int btrfs_del_csums(struct btrfs_trans_handle *trans,
struct btrfs_root *root, u64 bytenr, u64 len) struct btrfs_root *root, u64 bytenr, u64 len)

Просмотреть файл

@ -1369,8 +1369,8 @@ int btrfs_wait_cache_io(struct btrfs_trans_handle *trans,
path, block_group->start); path, block_group->start);
} }
/** /*
* Write out cached info to an inode * Write out cached info to an inode.
* *
* @root: root the inode belongs to * @root: root the inode belongs to
* @inode: freespace inode we are writing out * @inode: freespace inode we are writing out
@ -3034,10 +3034,7 @@ void btrfs_remove_free_space_cache(struct btrfs_block_group *block_group)
} }
/** /*
* btrfs_is_free_space_trimmed - see if everything is trimmed
* @block_group: block_group of interest
*
* Walk @block_group's free space rb_tree to determine if everything is trimmed. * Walk @block_group's free space rb_tree to determine if everything is trimmed.
*/ */
bool btrfs_is_free_space_trimmed(struct btrfs_block_group *block_group) bool btrfs_is_free_space_trimmed(struct btrfs_block_group *block_group)

Просмотреть файл

@ -6895,18 +6895,18 @@ static noinline int uncompress_inline(struct btrfs_path *path,
return ret; return ret;
} }
/** /*
* btrfs_get_extent - Lookup the first extent overlapping a range in a file. * Lookup the first extent overlapping a range in a file.
*
* @inode: file to search in * @inode: file to search in
* @page: page to read extent data into if the extent is inline * @page: page to read extent data into if the extent is inline
* @pg_offset: offset into @page to copy to * @pg_offset: offset into @page to copy to
* @start: file offset * @start: file offset
* @len: length of range starting at @start * @len: length of range starting at @start
* *
* This returns the first &struct extent_map which overlaps with the given * Return the first &struct extent_map which overlaps the given range, reading
* range, reading it from the B-tree and caching it if necessary. Note that * it from the B-tree and caching it if necessary. Note that there may be more
* there may be more extents which overlap the given range after the returned * extents which overlap the given range after the returned extent_map.
* extent_map.
* *
* If @page is not NULL and the extent is inline, this also reads the extent * If @page is not NULL and the extent is inline, this also reads the extent
* data directly into the page and marks the extent up to date in the io_tree. * data directly into the page and marks the extent up to date in the io_tree.
@ -11310,7 +11310,7 @@ void btrfs_update_inode_bytes(struct btrfs_inode *inode,
spin_unlock(&inode->lock); spin_unlock(&inode->lock);
} }
/** /*
* Verify that there are no ordered extents for a given file range. * Verify that there are no ordered extents for a given file range.
* *
* @inode: The target inode. * @inode: The target inode.

Просмотреть файл

@ -4346,7 +4346,7 @@ void btrfs_update_ioctl_balance_args(struct btrfs_fs_info *fs_info,
spin_unlock(&fs_info->balance_lock); spin_unlock(&fs_info->balance_lock);
} }
/** /*
* Try to acquire fs_info::balance_mutex as well as set BTRFS_EXLCOP_BALANCE as * Try to acquire fs_info::balance_mutex as well as set BTRFS_EXLCOP_BALANCE as
* required. * required.
* *

Просмотреть файл

@ -144,7 +144,7 @@ static inline struct rb_node *tree_search(struct btrfs_ordered_inode_tree *tree,
return ret; return ret;
} }
/** /*
* Add an ordered extent to the per-inode tree. * Add an ordered extent to the per-inode tree.
* *
* @inode: Inode that this extent is for. * @inode: Inode that this extent is for.
@ -1020,17 +1020,18 @@ out:
} }
/* /*
* btrfs_flush_ordered_range - Lock the passed range and ensures all pending * Lock the passed range and ensures all pending ordered extents in it are run
* ordered extents in it are run to completion. * to completion.
* *
* @inode: Inode whose ordered tree is to be searched * @inode: Inode whose ordered tree is to be searched
* @start: Beginning of range to flush * @start: Beginning of range to flush
* @end: Last byte of range to lock * @end: Last byte of range to lock
* @cached_state: If passed, will return the extent state responsible for the * @cached_state: If passed, will return the extent state responsible for the
* locked range. It's the caller's responsibility to free the cached state. * locked range. It's the caller's responsibility to free the
* cached state.
* *
* This function always returns with the given range locked, ensuring after it's * Always return with the given range locked, ensuring after it's called no
* called no order extent can be pending. * order extent can be pending.
*/ */
void btrfs_lock_and_flush_ordered_range(struct btrfs_inode *inode, u64 start, void btrfs_lock_and_flush_ordered_range(struct btrfs_inode *inode, u64 start,
u64 end, u64 end,

Просмотреть файл

@ -908,8 +908,8 @@ static void raid_write_end_io(struct bio *bio)
rbio_orig_end_io(rbio, err); rbio_orig_end_io(rbio, err);
} }
/** /*
* Get a sector pointer specified by its @stripe_nr and @sector_nr * Get a sector pointer specified by its @stripe_nr and @sector_nr.
* *
* @rbio: The raid bio * @rbio: The raid bio
* @stripe_nr: Stripe number, valid range [0, real_stripe) * @stripe_nr: Stripe number, valid range [0, real_stripe)

Просмотреть файл

@ -321,8 +321,8 @@ copy_to_page:
goto out; goto out;
} }
/** /*
* btrfs_clone() - clone a range from inode file to another * Clone a range from inode file to another.
* *
* @src: Inode to clone from * @src: Inode to clone from
* @inode: Inode to clone to * @inode: Inode to clone to

Просмотреть файл

@ -1493,8 +1493,8 @@ static void wait_reserve_ticket(struct btrfs_fs_info *fs_info,
spin_unlock(&space_info->lock); spin_unlock(&space_info->lock);
} }
/** /*
* Do the appropriate flushing and waiting for a ticket * Do the appropriate flushing and waiting for a ticket.
* *
* @fs_info: the filesystem * @fs_info: the filesystem
* @space_info: space info for the reservation * @space_info: space info for the reservation
@ -1596,8 +1596,8 @@ static inline bool can_ticket(enum btrfs_reserve_flush_enum flush)
flush != BTRFS_RESERVE_FLUSH_EMERGENCY); flush != BTRFS_RESERVE_FLUSH_EMERGENCY);
} }
/** /*
* Try to reserve bytes from the block_rsv's space * Try to reserve bytes from the block_rsv's space.
* *
* @fs_info: the filesystem * @fs_info: the filesystem
* @space_info: space info we want to allocate from * @space_info: space info we want to allocate from
@ -1736,8 +1736,8 @@ static int __reserve_bytes(struct btrfs_fs_info *fs_info,
orig_bytes, flush); orig_bytes, flush);
} }
/** /*
* Trye to reserve metadata bytes from the block_rsv's space * Try to reserve metadata bytes from the block_rsv's space.
* *
* @fs_info: the filesystem * @fs_info: the filesystem
* @block_rsv: block_rsv we're allocating for * @block_rsv: block_rsv we're allocating for
@ -1771,8 +1771,8 @@ int btrfs_reserve_metadata_bytes(struct btrfs_fs_info *fs_info,
return ret; return ret;
} }
/** /*
* Try to reserve data bytes for an allocation * Try to reserve data bytes for an allocation.
* *
* @fs_info: the filesystem * @fs_info: the filesystem
* @bytes: number of bytes we need * @bytes: number of bytes we need

Просмотреть файл

@ -7381,7 +7381,7 @@ void btrfs_record_snapshot_destroy(struct btrfs_trans_handle *trans,
mutex_unlock(&dir->log_mutex); mutex_unlock(&dir->log_mutex);
} }
/** /*
* Update the log after adding a new name for an inode. * Update the log after adding a new name for an inode.
* *
* @trans: Transaction handle. * @trans: Transaction handle.

Просмотреть файл

@ -38,8 +38,9 @@
* loop would be similar to the above. * loop would be similar to the above.
*/ */
/** /*
* ulist_init - freshly initialize a ulist * Freshly initialize a ulist.
*
* @ulist: the ulist to initialize * @ulist: the ulist to initialize
* *
* Note: don't use this function to init an already used ulist, use * Note: don't use this function to init an already used ulist, use
@ -52,8 +53,9 @@ void ulist_init(struct ulist *ulist)
ulist->nnodes = 0; ulist->nnodes = 0;
} }
/** /*
* ulist_release - free up additionally allocated memory for the ulist * Free up additionally allocated memory for the ulist.
*
* @ulist: the ulist from which to free the additional memory * @ulist: the ulist from which to free the additional memory
* *
* This is useful in cases where the base 'struct ulist' has been statically * This is useful in cases where the base 'struct ulist' has been statically
@ -71,8 +73,9 @@ void ulist_release(struct ulist *ulist)
INIT_LIST_HEAD(&ulist->nodes); INIT_LIST_HEAD(&ulist->nodes);
} }
/** /*
* ulist_reinit - prepare a ulist for reuse * Prepare a ulist for reuse.
*
* @ulist: ulist to be reused * @ulist: ulist to be reused
* *
* Free up all additional memory allocated for the list elements and reinit * Free up all additional memory allocated for the list elements and reinit
@ -84,8 +87,9 @@ void ulist_reinit(struct ulist *ulist)
ulist_init(ulist); ulist_init(ulist);
} }
/** /*
* ulist_alloc - dynamically allocate a ulist * Dynamically allocate a ulist.
*
* @gfp_mask: allocation flags to for base allocation * @gfp_mask: allocation flags to for base allocation
* *
* The allocated ulist will be returned in an initialized state. * The allocated ulist will be returned in an initialized state.
@ -102,8 +106,9 @@ struct ulist *ulist_alloc(gfp_t gfp_mask)
return ulist; return ulist;
} }
/** /*
* ulist_free - free dynamically allocated ulist * Free dynamically allocated ulist.
*
* @ulist: ulist to free * @ulist: ulist to free
* *
* It is not necessary to call ulist_release before. * It is not necessary to call ulist_release before.
@ -164,8 +169,9 @@ static int ulist_rbtree_insert(struct ulist *ulist, struct ulist_node *ins)
return 0; return 0;
} }
/** /*
* ulist_add - add an element to the ulist * Add an element to the ulist.
*
* @ulist: ulist to add the element to * @ulist: ulist to add the element to
* @val: value to add to ulist * @val: value to add to ulist
* @aux: auxiliary value to store along with val * @aux: auxiliary value to store along with val
@ -243,8 +249,9 @@ int ulist_del(struct ulist *ulist, u64 val, u64 aux)
return 0; return 0;
} }
/** /*
* ulist_next - iterate ulist * Iterate ulist.
*
* @ulist: ulist to iterate * @ulist: ulist to iterate
* @uiter: iterator variable, initialized with ULIST_ITER_INIT(&iterator) * @uiter: iterator variable, initialized with ULIST_ITER_INIT(&iterator)
* *

Просмотреть файл

@ -531,9 +531,9 @@ error:
return ret; return ret;
} }
/** /*
* Search and remove all stale devices (which are not mounted). * Search and remove all stale devices (which are not mounted). When both
* When both inputs are NULL, it will search and release all stale devices. * inputs are NULL, it will search and release all stale devices.
* *
* @devt: Optional. When provided will it release all unmounted devices * @devt: Optional. When provided will it release all unmounted devices
* matching this devt only. * matching this devt only.
@ -1478,8 +1478,9 @@ static bool dev_extent_hole_check_zoned(struct btrfs_device *device,
return changed; return changed;
} }
/** /*
* dev_extent_hole_check - check if specified hole is suitable for allocation * Check if specified hole is suitable for allocation.
*
* @device: the device which we have the hole * @device: the device which we have the hole
* @hole_start: starting position of the hole * @hole_start: starting position of the hole
* @hole_size: the size of the hole * @hole_size: the size of the hole
@ -1533,7 +1534,8 @@ static bool dev_extent_hole_check(struct btrfs_device *device, u64 *hole_start,
} }
/* /*
* find_free_dev_extent_start - find free space in the specified device * Find free space in the specified device.
*
* @device: the device which we search the free space in * @device: the device which we search the free space in
* @num_bytes: the size of the free space that we need * @num_bytes: the size of the free space that we need
* @search_start: the position from which to begin the search * @search_start: the position from which to begin the search
@ -1541,9 +1543,8 @@ static bool dev_extent_hole_check(struct btrfs_device *device, u64 *hole_start,
* @len: the size of the free space. that we find, or the size * @len: the size of the free space. that we find, or the size
* of the max free space if we don't find suitable free space * of the max free space if we don't find suitable free space
* *
* this uses a pretty simple search, the expectation is that it is * This does a pretty simple search, the expectation is that it is called very
* called very infrequently and that a given device has a small number * infrequently and that a given device has a small number of extents.
* of extents
* *
* @start is used to store the start of the free space if we find. But if we * @start is used to store the start of the free space if we find. But if we
* don't find suitable free space, it will be used to store the start position * don't find suitable free space, it will be used to store the start position
@ -2322,8 +2323,8 @@ void btrfs_destroy_dev_replace_tgtdev(struct btrfs_device *tgtdev)
btrfs_free_device(tgtdev); btrfs_free_device(tgtdev);
} }
/** /*
* Populate args from device at path * Populate args from device at path.
* *
* @fs_info: the filesystem * @fs_info: the filesystem
* @args: the args to populate * @args: the args to populate
@ -4031,8 +4032,9 @@ error:
return ret; return ret;
} }
/** /*
* alloc_profile_is_valid - see if a given profile is valid and reduced * See if a given profile is valid and reduced.
*
* @flags: profile to validate * @flags: profile to validate
* @extended: if true @flags is treated as an extended profile * @extended: if true @flags is treated as an extended profile
*/ */
@ -7009,8 +7011,9 @@ static struct btrfs_device *add_missing_dev(struct btrfs_fs_devices *fs_devices,
return device; return device;
} }
/** /*
* btrfs_alloc_device - allocate struct btrfs_device * Allocate new device struct, set up devid and UUID.
*
* @fs_info: used only for generating a new devid, can be NULL if * @fs_info: used only for generating a new devid, can be NULL if
* devid is provided (i.e. @devid != NULL). * devid is provided (i.e. @devid != NULL).
* @devid: a pointer to devid for this device. If NULL a new devid * @devid: a pointer to devid for this device. If NULL a new devid

Просмотреть файл

@ -1020,8 +1020,8 @@ int btrfs_reset_sb_log_zones(struct block_device *bdev, int mirror)
zone_sectors * BTRFS_NR_SB_LOG_ZONES, GFP_NOFS); zone_sectors * BTRFS_NR_SB_LOG_ZONES, GFP_NOFS);
} }
/** /*
* btrfs_find_allocatable_zones - find allocatable zones within a given region * Find allocatable zones within a given region.
* *
* @device: the device to allocate a region on * @device: the device to allocate a region on
* @hole_start: the position of the hole to allocate the region * @hole_start: the position of the hole to allocate the region
@ -1864,7 +1864,7 @@ struct btrfs_device *btrfs_zoned_get_device(struct btrfs_fs_info *fs_info,
return device; return device;
} }
/** /*
* Activate block group and underlying device zones * Activate block group and underlying device zones
* *
* @block_group: the block group to activate * @block_group: the block group to activate

Просмотреть файл

@ -94,7 +94,7 @@ static inline struct workspace *list_to_workspace(struct list_head *list)
void zstd_free_workspace(struct list_head *ws); void zstd_free_workspace(struct list_head *ws);
struct list_head *zstd_alloc_workspace(unsigned int level); struct list_head *zstd_alloc_workspace(unsigned int level);
/** /*
* Timer callback to free unused workspaces. * Timer callback to free unused workspaces.
* *
* @t: timer * @t: timer