~pmdj/ubuntu/trusty/qemu/2.9+applesmc+fadtv3

« back to all changes in this revision

Viewing changes to roms/openbios/libopenbios/init.c

  • Committer: Phil Dennis-Jordan
  • Date: 2017-07-21 08:03:43 UTC
  • mfrom: (1.1.1)
  • Revision ID: phil@philjordan.eu-20170721080343-2yr2vdj7713czahv
New upstream release 2.9.0.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 *   Creation Date: <2010/04/02 12:00:00 mcayland>
 
3
 *   Time-stamp: <2010/04/02 12:00:00 mcayland>
 
4
 *
 
5
 *      <init.c>
 
6
 *
 
7
 *      OpenBIOS intialization
 
8
 *
 
9
 *   Copyright (C) 2010 Mark Cave-Ayland (mark.cave-ayland@siriusit.co.uk)
 
10
 *
 
11
 *   This program is free software; you can redistribute it and/or
 
12
 *   modify it under the terms of the GNU General Public License
 
13
 *   version 2
 
14
 *
 
15
 */
 
16
 
 
17
#include "config.h"
 
18
#include "libopenbios/openbios.h"
 
19
#include "libopenbios/bindings.h"
 
20
#include "libopenbios/initprogram.h"
 
21
 
 
22
void
 
23
openbios_init( void )
 
24
{
 
25
        // Bind the saved program state context into Forth
 
26
        PUSH(pointer2cell((void *)&__context));
 
27
        feval("['] __context cell+ !");
 
28
 
 
29
        // Bind the C implementation of (init-program) into Forth
 
30
        bind_func("(init-program)", init_program);
 
31
        
 
32
        // Bind the C implementation of (go) into Forth
 
33
        bind_func("(go)", go);
 
34
}