[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [mini-os master] mini-os: remove unused functions from sched.c



commit 864c2eb6d25a941b26ba3b8e2d5a4a64caa8ed0f
Author:     Juergen Gross <jgross@xxxxxxxx>
AuthorDate: Mon Aug 29 08:17:22 2016 +0200
Commit:     Wei Liu <wei.liu2@xxxxxxxxxx>
CommitDate: Mon Aug 29 11:12:04 2016 +0100

    mini-os: remove unused functions from sched.c
    
    sched.c contains some functions nobody is using. Remove them.
    
    Signed-off-by: Juergen Gross <jgross@xxxxxxxx>
    Reviewed-by: Samuel Thibault <samuel.thibault@xxxxxxxxxxxx>
---
 sched.c | 48 ------------------------------------------------
 1 file changed, 48 deletions(-)

diff --git a/sched.c b/sched.c
index 1e843d9..6f89ea4 100644
--- a/sched.c
+++ b/sched.c
@@ -63,16 +63,6 @@ static int threads_started;
 
 struct thread *main_thread;
 
-void inline print_runqueue(void)
-{
-    struct thread *th;
-    MINIOS_TAILQ_FOREACH(th, &thread_list, thread_list)
-    {
-        printk("   Thread \"%s\", runnable=%d\n", th->name, is_runnable(th));
-    }
-    printk("\n");
-}
-
 void schedule(void)
 {
     struct thread *prev, *next, *thread, *tmp;
@@ -245,44 +235,6 @@ void idle_thread_fn(void *unused)
     }
 }
 
-DECLARE_MUTEX(mutex);
-
-void th_f1(void *data)
-{
-    struct timeval tv1, tv2;
-
-    for(;;)
-    {
-        down(&mutex);
-        printk("Thread \"%s\" got semaphore, runnable %d\n", current->name, 
is_runnable(current));
-        schedule();
-        printk("Thread \"%s\" releases the semaphore\n", current->name);
-        up(&mutex);
-        
-        
-        gettimeofday(&tv1, NULL);
-        for(;;)
-        {
-            gettimeofday(&tv2, NULL);
-            if(tv2.tv_sec - tv1.tv_sec > 2) break;
-        }
-                
-        
-        schedule(); 
-    }
-}
-
-void th_f2(void *data)
-{
-    for(;;)
-    {
-        printk("Thread OTHER executing, data 0x%p\n", data);
-        schedule();
-    }
-}
-
-
-
 void init_sched(void)
 {
     printk("Initialising scheduler\n");
--
generated by git-patchbot for /home/xen/git/mini-os.git#master

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.