Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
8668010b
Commit
8668010b
authored
Jan 12, 2015
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Try to make epoll waiter work again
parent
5ea15724
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
13 deletions
+10
-13
cache_session.c
bin/varnishd/cache/cache_session.c
+5
-1
cache_waiter_epoll.c
bin/varnishd/waiter/cache_waiter_epoll.c
+5
-12
No files found.
bin/varnishd/cache/cache_session.c
View file @
8668010b
...
...
@@ -288,7 +288,11 @@ SES_Wait(struct sess *sp)
CHECK_OBJ_NOTNULL
(
sp
,
SESS_MAGIC
);
pp
=
sp
->
sesspool
;
CHECK_OBJ_NOTNULL
(
pp
,
SESSPOOL_MAGIC
);
INIT_OBJ
(
&
sp
->
waited
,
WAITED_MAGIC
);
/*
* XXX: waiter_epoll prevents us from zeroing the struct because
* XXX: it keeps state across calls.
*/
sp
->
waited
.
magic
=
WAITED_MAGIC
;
sp
->
waited
.
fd
=
sp
->
fd
;
sp
->
waited
.
ptr
=
sp
;
sp
->
waited
.
deadline
=
sp
->
t_idle
;
...
...
bin/varnishd/waiter/cache_waiter_epoll.c
View file @
8668010b
...
...
@@ -75,18 +75,11 @@ vwe_modadd(struct vwe *vwe, int fd, void *data, short arm)
* XXX: will hang. See #644.
*/
assert
(
fd
>=
0
);
if
(
data
==
vwe
->
pipes
||
data
==
vwe
->
timer_pipes
)
{
struct
epoll_event
ev
=
{
EPOLLIN
|
EPOLLPRI
,
{
data
}
};
AZ
(
epoll_ctl
(
vwe
->
epfd
,
arm
,
fd
,
&
ev
));
}
else
{
struct
waited
*
sp
=
(
struct
waited
*
)
data
;
CHECK_OBJ_NOTNULL
(
sp
,
WAITED_MAGIC
);
sp
->
ev
.
data
.
ptr
=
data
;
sp
->
ev
.
events
=
EPOLLIN
|
EPOLLPRI
|
EPOLLONESHOT
|
EPOLLRDHUP
;
AZ
(
epoll_ctl
(
vwe
->
epfd
,
arm
,
fd
,
&
sp
->
ev
));
}
assert
(
data
==
vwe
->
pipes
||
data
==
vwe
->
timer_pipes
);
struct
epoll_event
ev
=
{
EPOLLIN
|
EPOLLPRI
,
{
data
}
};
AZ
(
epoll_ctl
(
vwe
->
epfd
,
arm
,
fd
,
&
ev
));
}
static
void
...
...
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