sched.h
ubixos/types.h
ubixos/tty.h
vfs/file.h
sys/tss.h
sys/thread.h
src/sys/include/mpi/mpi.h
src/sys/include/ubixos/elf.h
src/sys/include/ubixos/endtask.h
src/sys/include/ubixos/exec.h
src/sys/include/ubixos/fork.h
src/sys/include/ubixos/init.h
src/sys/include/ubixos/syscalls.h
src/sys/include/ubixos/ubthread.h
src/sys/isa/atkbd.c
src/sys/kernel/bioscall.c
src/sys/kernel/endtask.c
src/sys/kernel/fork.c
src/sys/kernel/gen_calls.c
src/sys/kernel/ld.c
src/sys/kernel/sched.c
src/sys/kernel/spinlock.c
src/sys/kernel/syscall.c
src/sys/kernel/syscall_new.c
src/sys/kernel/systemtask.c
src/sys/kernel/ubthread.c
src/sys/kmods/kmod.c
src/sys/lib/kmalloc.c
src/sys/sys/idt.c
src/sys/ubixfs/ubixfs.c
src/sys/vfs/file.c
src/sys/vmm/getfreevirtualpage.c
src/sys/vmm/pagefault.c
src/sys/vmm/paging.c
sys/thread.h
src/sys/include/ubixos/sched.h
ubixos/types.h
sys/_types.h
vfs/file.h
sys/tss.h
vfs/mount.h
ubixfs/dirCache.h
ubixos/tty.h
src/sys/include/ubixos/sched.h
src/sys/pci/hd.c
src/sys/include/ubixos/endtask.h
src/sys/kernel/vitals.c
src/sys/kernel/elf.c
src/sys/mpi/message.c
src/sys/kmods/kmod.c
src/sys/mpi/system.c
src/sys/kernel/kern_sysctl.c
src/sys/include/ubixos/vitals.h
src/sys/lib/kmalloc.c
src/sys/vmm/paging.c
src/sys/ubixfs/directory.c
src/sys/kernel/kern_sig.c
src/sys/kernel/ubthread.c
src/sys/kernel/systemtask.c
src/sys/lib/ogprintf.cc
src/sys/kernel/ld.c
src/sys/kernel/fork.c
src/sys/ubixfs/block.c
src/sys/kernel/sched.c
src/sys/include/mpi/mpi.h
src/sys/include/ubixos/fork.h
src/sys/ubixfs/dirCache.c
src/sys/ubixfs/ubixfs.c
src/sys/init/main.c
src/sys/include/ubixfs/ubixfs.h
src/sys/kernel/bioscall.c
src/sys/include/ubixos/ubthread.h
src/sys/kernel/syscall.c
src/sys/isa/ne2k.c
src/sys/include/ubixos/exec.h
src/sys/include/ubixos/syscalls.h
src/sys/include/pci/hd.h
src/sys/isa/atkbd.c
src/sys/vmm/pagefault.c
src/sys/ubixfs/thread.c
src/sys/include/ubixos/init.h
src/sys/vfs/mount.c
src/sys/kernel/time.c
src/sys/vmm/vmm_memory.c
src/sys/kernel/spinlock.c
src/sys/include/ubixos/elf.h
src/sys/kernel/kern_descrip.c
src/sys/kernel/endtask.c
src/sys/vfs/file.c
src/sys/kernel/gen_calls.c
src/sys/sys/idt.c
src/sys/kernel/syscall_new.c
src/sys/kernel/exec.c
src/sys/vmm/getfreevirtualpage.c
src/sys/vfs/vfs.c
osInfo
taskStruct
taskStruct typedef struct taskStruct kTask_t kTask_t
tState
PLACEHOLDER
-2
DEAD
-1
NEW
0
READY
1
RUNNING
2
IDLE
3
FORK
4
WAIT
5
void void sched () sched _current DEAD FORK taskStruct::id taskStruct::next READY sched_addDelTask sched_deleteTask schedulerSpinLock spinTryLock taskStruct::state sched_yield
int int sched_addDelTask (kTask_t *) sched_addDelTask kTask_t * delList taskStruct::next taskStruct::prev sched
int int sched_deleteTask (pidType) sched_deleteTask pidType taskStruct::id taskStruct::next taskStruct::prev taskList sched
kTask_t * kTask_t* sched_getDelTask () sched_getDelTask delList taskStruct::next systemTask
int int sched_init () sched_init taskStruct::id kmalloc kpanic kprintf nextID taskList
int int sched_setStatus (pidType, tState) sched_setStatus pidType tState schedFindTask taskStruct::state x1 endTask execFile execThread
void void sched_yield () sched_yield sched _int0 _int1 _int10 _int11 _int12 _int2 _int3 _int4 _int5 _int6 _int9 endTask fork_copyProcess schedEndTask spinLock sysFgetc sysSchedYield systemTask ubthread_cond_timedwait ubthread_cond_wait
void void schedEndTask (pidType pid) schedEndTask pidType pid _current endTask taskStruct::id sched_yield
kTask_t * kTask_t* schedFindTask (uInt32 id) schedFindTask uInt32 id taskStruct::id taskStruct::next taskList sched_setStatus sysCheckPid systemTask vmmMapFromTask
kTask_t * kTask_t* schedNewTask () schedNewTask file::f_flag taskStruct::id kmalloc kpanic memset NEW taskStruct::next nextID thread::o_files taskStruct::prev schedulerSpinLock spinLock spinUnlock taskStruct::state taskList taskStruct::td taskStruct::usedMath biosCall execFile execThread
kTask_t * kTask_t* _current _current __sysctl _int0 _int1 _int10 _int11 _int12 _int13 _int2 _int3 _int4 _int5 _int6 _int8 _int9 biosCall elf_loadfile endTask execFile fork_copyProcess fstat getgid getpid getuid intNull kmod_load ldEnable mathStateRestore mmap mpi_createMbox mpi_destroyMbox mpi_fetchMessage mpi_postMessage obreak sched schedEndTask sys_exec syscall sysChDir sysExec sysExit sysFgetc sysFwrite sysGetCwd sysGetFreePage sysGetGid sysGetpid sysGetUid sysMkDir sysPasswd sysSetGid sysSetUid ubthread_mutex_lock ubthread_mutex_unlock ubthread_self vmm_pageFault vmm_remapPage vmmGetFreeVirtualPage vmmMapFromTask
kTask_t * kTask_t* _usedMath _usedMath mathStateRestore

    /*****************************************************************************************
    Copyright(c)2002-2004TheUbixOSProject
    Allrightsreserved.

    Redistributionanduseinsourceandbinaryforms,withorwithoutmodification,are
    permittedprovidedthatthefollowingconditionsaremet:

    Redistributionsofsourcecodemustretaintheabovecopyrightnotice,thislistof
    conditions,thefollowingdisclaimerandthelistofauthors.Redistributionsinbinary
    formmustreproducetheabovecopyrightnotice,thislistofconditions,thefollowing
    disclaimerandthelistofauthorsinthedocumentationand/orothermaterialsprovided
    withthedistribution.NeitherthenameoftheUbixOSProjectnorthenamesofits
    contributorsmaybeusedtoendorseorpromoteproductsderivedfromthissoftware
    withoutspecificpriorwrittenpermission.

    THISSOFTWAREISPROVIDEDBYTHECOPYRIGHTHOLDERSANDCONTRIBUTORS"ASIS"ANDANY
    EXPRESSORIMPLIEDWARRANTIES,INCLUDING,BUTNOTLIMITEDTO,THEIMPLIEDWARRANTIESOF
    MERCHANTABILITYANDFITNESSFORAPARTICULARPURPOSEAREDISCLAIMED.INNOEVENTSHALL
    THECOPYRIGHTOWNERORCONTRIBUTORSBELIABLEFORANYDIRECT,INDIRECT,INCIDENTAL,
    SPECIAL,EXEMPLARY,ORCONSEQUENTIALDAMAGES(INCLUDING,BUTNOTLIMITEDTO,PROCUREMENT
    OFSUBSTITUTEGOODSORSERVICES;LOSSOFUSE,DATA,ORPROFITS;ORBUSINESSINTERRUPTION)
    HOWEVERCAUSEDANDONANYTHEORYOFLIABILITY,WHETHERINCONTRACT,STRICTLIABILITY,OR
    TORT(INCLUDINGNEGLIGENCEOROTHERWISE)ARISINGINANYWAYOUTOFTHEUSEOFTHIS
    SOFTWARE,EVENIFADVISEDOFTHEPOSSIBILITYOFSUCHDAMAGE.

    $Id: sched_8h.xml 88 2016-01-12 00:11:29Z reddawg $

    *****************************************************************************************/

    #ifndef_SCHED_H
    #define_SCHED_H

    #include<ubixos/types.h>
    //#include<ubixos/elf.h>
    #include<ubixos/tty.h>
    #include<vfs/file.h>
    #include<sys/tss.h>
    #include<sys/thread.h>

    typedefenum{PLACEHOLDER=-2,DEAD=-1,NEW=0,READY=1,RUNNING=2,IDLE=3,FORK=4,WAIT=5}tState;

    structosInfo{
    uInt8timer;
    uInt8v86Task;
    boolv86If;
    uInt32vmStart;
    uInt32stdinSize;
    uInt32controlKeys;
    char*stdin;
    charcwd[1024];/*currentworkingdir*/
    };

    typedefstructtaskStruct{
    pidTypeid;
    structtaskStruct*prev;
    structtaskStruct*next;
    structtssStructtss;
    structi387Structi387;
    structosInfooInfo;
    fileDescriptor*imageFd;
    tStatestate;
    uInt32gid;
    uInt32uid;
    uInt16usedMath;
    tty_term*term;
    structthreadtd;
    }kTask_t;

    intsched_init();
    intsched_setStatus(pidType,tState);
    intsched_deleteTask(pidType);
    intsched_addDelTask(kTask_t*);
    kTask_t*sched_getDelTask();
    voidsched_yield();
    voidsched();

    voidschedEndTask(pidTypepid);
    kTask_t*schedNewTask();
    kTask_t*schedFindTask(uInt32id);

    externkTask_t*_current;
    externkTask_t*_usedMath;

    #endif

    /***
    $Log: sched_8h.xml,v $
    Revision 1.6  2006/12/19 14:12:52  reddawg
    rtld-elf almost workign

    Revision1.32006/12/1515:43:46reddawg
    Changes

    Revision1.22006/10/2716:42:42reddawg
    Testing

    Revision1.1.1.12006/06/0112:46:14reddawg
    ubix2

    Revision1.22005/10/1200:13:37reddawg
    Removed

    Revision1.1.1.12005/09/2617:23:55reddawg
    nomessage

    Revision1.302004/09/1122:21:11reddawg
    oInfo.cwdisnowanarraynolongerapointer..

    Revision1.292004/09/0823:19:58reddawg
    hmm

    Revision1.282004/09/0822:16:02reddawg
    Fixens

    Revision1.272004/09/0821:19:32reddawg
    Allgoodnow

    Revision1.262004/09/0721:54:38reddawg
    okrevertedbacktooldschedulingfornow....

    Revision1.202004/08/0912:58:05reddawg
    letmeknowwhenyougotthesurce

    Revision1.192004/08/0622:43:04reddawg
    ok

    Revision1.182004/08/0622:32:16reddawg
    UbixWorksAgain

    Revision1.162004/08/0408:17:57reddawg
    tty:wehaveprimativettystryf1-f5soitiseasiertouseanddebug
    ubixos

    Revision1.152004/07/2921:32:16reddawg
    Myquicklunchsbreaksworthofupdates....

    Revision1.142004/07/2117:15:02reddawg
    removedgarbage

    Revision1.132004/07/2114:43:14flameshadow
    add:addedcwc(currentworkingcontainer)totheosInfostrut

    Revision1.122004/07/1902:32:21reddawg
    sched:wenowsettaskstatustodeadwhichthenmakestheschedulerdosomecleanitcouldbesomeminoroverheadbutifeelthisisourmostefficientapproachrightnowtopreventcorruptionofthequeues

    Revision1.112004/07/1902:08:27reddawg
    Cleanedouttherestofdebugingcodealsotemporarilydisabledtheipstacktoimproveboottime

    Revision1.102004/07/1805:24:15reddawg
    Fixens

    Revision1.92004/07/0913:23:20reddawg
    sched:schedInittosched_init
    Adjustedinitializationroutines

    Revision1.82004/06/2214:02:14solar
    AddedthePLACEHOLDERstateforatask

    Revision1.72004/06/1813:01:47solar
    AddedniceandtimeSlicememberstothekTask_ttype

    Revision1.62004/06/1702:12:57reddawg
    CleanedOutDeadCode

    Revision1.52004/06/1614:04:51reddawg
    Renamedatypedef

    Revision1.42004/06/1412:20:54reddawg
    notes:manybugsrepairedandldworks100%now.

    Revision1.32004/05/2115:49:13reddawg
    Theosdoesbetterhousekeepingnowwhenataskisexited

    Revision1.22004/05/2115:20:00reddawg
    Cleanedup

    END
    ***/