Subversion Repositories shark

Rev

Rev 1624 | Rev 1645 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

/*
 * Project: HARTIK (HA-rd R-eal TI-me K-ernel)
 *
 * Coordinators: Giorgio Buttazzo <giorgio@sssup.it>
 *               Gerardo Lamastra <gerardo@sssup.it>
 *
 * Authors     : Mauro Marinoni   <mauro.marinoni@unipv.it>
 *               Giacomo Guidi    <giacomo@gandalf.sssup.it>
 * (see authors.txt for full list of hartik's authors)
 *
 * ReTiS Lab (Scuola Superiore S.Anna - Pisa - Italy)
 *
 * http://www.sssup.it
 * http://retis.sssup.it
 * http://hartik.sssup.it
 */


#include "chimera.h"
#include "modules/edf.h"
#include "modules/hardcbs.h"
#include "modules/rr.h"
#include "modules/dummy.h"
#include "modules/intdrive.h"

#include <drivers/keyb.h>

/*+ sysyem tick in us +*/
#define TICK 0

/*+ RR tick in us +*/
#define RRTICK 10000

#define INTDRIVE_Q 1000
#define INTDRIVE_T 10000
#define INTDRIVE_FLAGS 0

int main(int argc, char **argv);

TIME __kernel_register_levels__(void *arg)
{
        struct multiboot_info *mb = (struct multiboot_info *)arg;

        EDF_register_level(EDF_ENABLE_ALL);
        HCBS_register_level(HCBS_ENABLE_ALL, 0);
        RR_register_level(RRTICK, RR_MAIN_YES, mb);
        dummy_register_level();

        SEM_register_module();

        return TICK;
}

TASK __init__(void *arg)
{
        struct multiboot_info *mb = (struct multiboot_info *)arg;

        KEYB_PARMS kparms = BASE_KEYB;

        HARTPORT_init();

        KEYB_init(&kparms);

        __call_main__(mb);

        return (void *)0;
}