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
657913f0
Unverified
Commit
657913f0
authored
Dec 21, 2023
by
Nils Goroll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Factor out the commit part of fellow_busy_region_alloc()
parent
da17aa3b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
10 deletions
+20
-10
fellow_cache.c
src/fellow_cache.c
+20
-10
No files found.
src/fellow_cache.c
View file @
657913f0
...
...
@@ -2160,21 +2160,15 @@ fellow_region_alloc(const struct fellow_cache *fc, size_t size, int8_t cram)
FEP_SPC
,
size
,
cram
));
}
/* allocate a new region for body, aux attr or seglist
*
* aux attr use: We do not yet coalesce allocations because
* there only is a single aux attr, so the one segment gets
* its own region
*/
/* commit a region to the busy object */
static
struct
buddy_off_extent
*
fellow_busy_region_
alloc
(
struct
fellow_busy
*
fbo
,
size_t
size
,
int8_t
cram
)
fellow_busy_region_
commit
(
struct
fellow_busy
*
fbo
,
struct
buddy_off_extent
reg
)
{
struct
buddy_off_extent
*
fdr
,
reg
;
struct
buddy_off_extent
*
fdr
;
CHECK_OBJ_NOTNULL
(
fbo
,
FELLOW_BUSY_MAGIC
);
reg
=
fellow_region_alloc
(
fbo
->
fc
,
size
,
cram
);
if
(
reg
.
off
<
0
)
{
return
(
NULL
);
}
...
...
@@ -2189,6 +2183,22 @@ fellow_busy_region_alloc(struct fellow_busy *fbo, size_t size, int8_t cram)
return
(
fdr
);
}
/* allocate a new region for body, aux attr or seglist
*
* aux attr use: We do not yet coalesce allocations because
* there only is a single aux attr, so the one segment gets
* its own region
*/
static
struct
buddy_off_extent
*
fellow_busy_region_alloc
(
struct
fellow_busy
*
fbo
,
size_t
size
,
int8_t
cram
)
{
CHECK_OBJ_NOTNULL
(
fbo
,
FELLOW_BUSY_MAGIC
);
return
(
fellow_busy_region_commit
(
fbo
,
fellow_region_alloc
(
fbo
->
fc
,
size
,
cram
)));
}
/*
* return an unused region for seglist trim
*/
...
...
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