Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
slash
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
uplex-varnish
slash
Commits
345ae72d
Unverified
Commit
345ae72d
authored
Oct 24, 2023
by
Nils Goroll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add buddy_reqs_next_ready / buddy_reqs_done
parent
1902b35a
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
0 deletions
+18
-0
buddy.h
src/buddy.h
+18
-0
No files found.
src/buddy.h
View file @
345ae72d
...
@@ -821,6 +821,24 @@ _buddy_get_off_extent(const struct buddy_reqs *reqs, uint8_t n)
...
@@ -821,6 +821,24 @@ _buddy_get_off_extent(const struct buddy_reqs *reqs, uint8_t n)
return
(
off
);
return
(
off
);
}
}
static
inline
uint8_t
buddy_reqs_next_ready
(
struct
buddy_reqs
*
reqs
)
{
(
void
)
BUDDYF
(
alloc_async_ready
)(
reqs
);
assert
(
reqs
->
i_wait
.
finid
>=
reqs
->
i_wait
.
next
);
return
(
reqs
->
i_wait
.
finid
-
reqs
->
i_wait
.
next
);
}
static
inline
int
buddy_reqs_done
(
struct
buddy_reqs
*
reqs
)
{
uint8_t
rdy
;
rdy
=
BUDDYF
(
alloc_async_ready
)(
reqs
);
assert
(
rdy
<=
reqs
->
n
);
return
(
rdy
==
reqs
->
n
);
}
#ifndef FREEPAGE_WHEN
#ifndef FREEPAGE_WHEN
static
inline
struct
buddy_off_extent
static
inline
struct
buddy_off_extent
buddy_get_off_extent
(
const
struct
buddy_reqs
*
reqs
,
uint8_t
n
)
buddy_get_off_extent
(
const
struct
buddy_reqs
*
reqs
,
uint8_t
n
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment