File tree Expand file tree Collapse file tree 2 files changed +10
-5
lines changed Expand file tree Collapse file tree 2 files changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -81,9 +81,10 @@ typedef struct xfs_alloc_arg {
81
81
/*
82
82
* Defines for datatype
83
83
*/
84
- #define XFS_ALLOC_INITIAL_USER_DATA (1 << 0)/* special case start of file */
85
- #define XFS_ALLOC_USERDATA_ZERO (1 << 1)/* zero extent on allocation */
86
- #define XFS_ALLOC_NOBUSY (1 << 2)/* Busy extents not allowed */
84
+ #define XFS_ALLOC_USERDATA (1 << 0)/* allocation is for user data*/
85
+ #define XFS_ALLOC_INITIAL_USER_DATA (1 << 1)/* special case start of file */
86
+ #define XFS_ALLOC_USERDATA_ZERO (1 << 2)/* zero extent on allocation */
87
+ #define XFS_ALLOC_NOBUSY (1 << 3)/* Busy extents not allowed */
87
88
88
89
static inline bool
89
90
xfs_alloc_is_userdata (int datatype )
Original file line number Diff line number Diff line change @@ -4042,8 +4042,12 @@ xfs_bmapi_allocate(
4042
4042
*/
4043
4043
if (!(bma -> flags & XFS_BMAPI_METADATA )) {
4044
4044
bma -> datatype = XFS_ALLOC_NOBUSY ;
4045
- if (whichfork == XFS_DATA_FORK && bma -> offset == 0 )
4046
- bma -> datatype |= XFS_ALLOC_INITIAL_USER_DATA ;
4045
+ if (whichfork == XFS_DATA_FORK ) {
4046
+ if (bma -> offset == 0 )
4047
+ bma -> datatype |= XFS_ALLOC_INITIAL_USER_DATA ;
4048
+ else
4049
+ bma -> datatype |= XFS_ALLOC_USERDATA ;
4050
+ }
4047
4051
if (bma -> flags & XFS_BMAPI_ZERO )
4048
4052
bma -> datatype |= XFS_ALLOC_USERDATA_ZERO ;
4049
4053
}
You can’t perform that action at this time.
0 commit comments