Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit c4e50c2

Browse files
author
Octavian Purdila
committed
Merge pull request torvalds#136 from pscollins/hijack-eventfd-only-sometimes
lkl: Hijack eventfd only when COFNIG_EVENTFD
2 parents e11e9b5 + a38269b commit c4e50c2

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tools/lkl/lib/hijack/hijack.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -280,6 +280,8 @@ int epoll_ctl(int epollfd, int op, int fd, struct epoll_event *event)
280280
return lkl_call(__lkl__NR_epoll_ctl, 4, epollfd, op, fd, event);
281281
}
282282

283+
#ifdef CONFIG_EVENTFD
284+
/* Hijack eventfd only if we turned it on in our config files */
283285
int eventfd(unsigned int count, int flags)
284286
{
285287
return lkl_sys_eventfd2(count, flags);
@@ -308,3 +310,4 @@ int eventfd_write(int fd, uint64_t value)
308310
return lkl_sys_write(fd, (void *) &value,
309311
sizeof(value)) != sizeof(value) ? -1 : 0;
310312
}
313+
#endif

0 commit comments

Comments
 (0)