Commit 173e937
fs: export may_delete() as may_delete_dentry()
For many years btrfs as been using a copy of may_delete() in
fs/btrfs/ioctl.c:btrfs_may_delete(). Everytime may_delete() is updated we
need to update the btrfs copy, and this is a maintenance burden. Currently
there are minor differences between both because the btrfs side lacks
updates done in may_delete().
Export may_delete() so that btrfs can use it and with the less generic
name may_delete_dentry(). While at it change the calls in vfs_rmdir() to
pass a boolean literal instead of 1 and 0 as the last argument since the
argument has a bool type.
Signed-off-by: Filipe Manana <fdmanana@suse.com>
Link: https://patch.msgid.link/e09128fd53f01b19d0a58f0e7d24739f79f47f6d.1768307858.git.fdmanana@suse.com
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: Christian Brauner <brauner@kernel.org>1 parent 8f0b4cc commit 173e937
2 files changed
Lines changed: 12 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3604 | 3604 | | |
3605 | 3605 | | |
3606 | 3606 | | |
3607 | | - | |
| 3607 | + | |
3608 | 3608 | | |
3609 | 3609 | | |
3610 | 3610 | | |
| |||
3646 | 3646 | | |
3647 | 3647 | | |
3648 | 3648 | | |
| 3649 | + | |
3649 | 3650 | | |
3650 | 3651 | | |
3651 | 3652 | | |
| |||
5209 | 5210 | | |
5210 | 5211 | | |
5211 | 5212 | | |
5212 | | - | |
| 5213 | + | |
5213 | 5214 | | |
5214 | 5215 | | |
5215 | 5216 | | |
| |||
5344 | 5345 | | |
5345 | 5346 | | |
5346 | 5347 | | |
5347 | | - | |
| 5348 | + | |
5348 | 5349 | | |
5349 | 5350 | | |
5350 | 5351 | | |
| |||
5816 | 5817 | | |
5817 | 5818 | | |
5818 | 5819 | | |
5819 | | - | |
| 5820 | + | |
5820 | 5821 | | |
5821 | 5822 | | |
5822 | 5823 | | |
| |||
5826 | 5827 | | |
5827 | 5828 | | |
5828 | 5829 | | |
5829 | | - | |
5830 | | - | |
| 5830 | + | |
| 5831 | + | |
5831 | 5832 | | |
5832 | | - | |
5833 | | - | |
| 5833 | + | |
| 5834 | + | |
5834 | 5835 | | |
5835 | 5836 | | |
5836 | 5837 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2657 | 2657 | | |
2658 | 2658 | | |
2659 | 2659 | | |
| 2660 | + | |
| 2661 | + | |
| 2662 | + | |
2660 | 2663 | | |
2661 | 2664 | | |
2662 | 2665 | | |
| |||
0 commit comments