From 3c4abebc788e9d92d776d7bc8b778f398cdb4010 Mon Sep 17 00:00:00 2001 From: Nathan O Date: Mon, 9 Dec 2019 14:59:56 -0500 Subject: Initial attempt to "connect the wires" - This is my first attempt to re-add all of the modifications on top of this version of the Linux kernel that were present in the previous version of LITMUS. - More notes on changes will follow after testing--no guarantees the code as it is now will compile or run correctly. --- fs/exec.c | 3 +++ fs/inode.c | 2 ++ fs/select.c | 6 ++++-- 3 files changed, 9 insertions(+), 2 deletions(-) (limited to 'fs') diff --git a/fs/exec.c b/fs/exec.c index 555e93c7dec8..49c8613d2510 100644 --- a/fs/exec.c +++ b/fs/exec.c @@ -64,6 +64,8 @@ #include #include +#include + #include #include #include @@ -1765,6 +1767,7 @@ static int __do_execve_file(int fd, struct filename *filename, goto out_unmark; sched_exec(); + litmus_exec(); bprm->file = file; if (!filename) { diff --git a/fs/inode.c b/fs/inode.c index fef457a42882..abf61717d9db 100644 --- a/fs/inode.c +++ b/fs/inode.c @@ -394,6 +394,8 @@ void inode_init_once(struct inode *inode) INIT_LIST_HEAD(&inode->i_lru); __address_space_init_once(&inode->i_data); i_size_ordered_init(inode); + INIT_LIST_HEAD(&inode->i_obj_list); + mutex_init(&inode->i_obj_mutex); } EXPORT_SYMBOL(inode_init_once); diff --git a/fs/select.c b/fs/select.c index 53a0c149f528..7a3745f8d17f 100644 --- a/fs/select.c +++ b/fs/select.c @@ -32,6 +32,8 @@ #include #include +#include + #include @@ -80,9 +82,9 @@ u64 select_estimate_accuracy(struct timespec64 *tv) /* * Realtime tasks get a slack of 0 for obvious reasons. */ - - if (rt_task(current)) + if (rt_task(current) || is_realtime(current)) { return 0; + } ktime_get_ts64(&now); now = timespec64_sub(*tv, now); -- cgit v1.2.2