btrfs: update and correct description of btrfs_get_or_create_delayed_node()

The comment mistakenly says the function is returning PTR_ERR instead of
ERR_PTR. Fix it and update it so it's more descriptive.

Signed-off-by: Charles Han <hanchunchao@inspur.com>
Reviewed-by: David Sterba <dsterba@suse.com>
[ Enhance the function comment. ]
Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
Charles Han
2025-04-10 17:07:22 +08:00
committed by David Sterba
parent ea2a8bacb1
commit ecf5b757c7

View File

@@ -119,7 +119,12 @@ static struct btrfs_delayed_node *btrfs_get_delayed_node(
return NULL;
}
/* Will return either the node or PTR_ERR(-ENOMEM) */
/*
* Look up an existing delayed node associated with @btrfs_inode or create a new
* one and insert it to the delayed nodes of the root.
*
* Return the delayed node, or error pointer on failure.
*/
static struct btrfs_delayed_node *btrfs_get_or_create_delayed_node(
struct btrfs_inode *btrfs_inode)
{