1 | ; $Id: bs3-cpu-basic-2.asm 59863 2016-02-26 20:59:52Z vboxsync $
|
---|
2 | ;; @file
|
---|
3 | ; BS3Kit - bs3-cpu-basic-2
|
---|
4 | ;
|
---|
5 |
|
---|
6 | ;
|
---|
7 | ; Copyright (C) 2007-2016 Oracle Corporation
|
---|
8 | ;
|
---|
9 | ; This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
10 | ; available from http://www.virtualbox.org. This file is free software;
|
---|
11 | ; you can redistribute it and/or modify it under the terms of the GNU
|
---|
12 | ; General Public License (GPL) as published by the Free Software
|
---|
13 | ; Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
14 | ; VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
15 | ; hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
16 | ;
|
---|
17 | ; The contents of this file may alternatively be used under the terms
|
---|
18 | ; of the Common Development and Distribution License Version 1.0
|
---|
19 | ; (CDDL) only, as it comes in the "COPYING.CDDL" file of the
|
---|
20 | ; VirtualBox OSE distribution, in which case the provisions of the
|
---|
21 | ; CDDL are applicable instead of those of the GPL.
|
---|
22 | ;
|
---|
23 | ; You may elect to license modified versions of this file under the
|
---|
24 | ; terms and conditions of either the GPL or the CDDL or both.
|
---|
25 | ;
|
---|
26 |
|
---|
27 |
|
---|
28 | ;*********************************************************************************************************************************
|
---|
29 | ;* Header Files *
|
---|
30 | ;*********************************************************************************************************************************
|
---|
31 | %include "bs3kit.mac"
|
---|
32 |
|
---|
33 | ;
|
---|
34 | ; Segment defs, grouping and related variables.
|
---|
35 | ; Defines the entry point 'start' as well, leaving us in BS3TEXT16.
|
---|
36 | ;
|
---|
37 | %include "bs3-first-common.mac"
|
---|
38 |
|
---|
39 |
|
---|
40 | ;
|
---|
41 | ; We start in real mode.
|
---|
42 | ;
|
---|
43 | %define TMPL_RM
|
---|
44 | %include "bs3kit-template-header.mac"
|
---|
45 |
|
---|
46 | BS3_EXTERN_DATA16 g_uBs3CpuDetected
|
---|
47 | BS3_BEGIN_TEXT16
|
---|
48 | BS3_EXTERN_CMN Bs3Shutdown
|
---|
49 | extern _Bs3InitAll_rm
|
---|
50 |
|
---|
51 |
|
---|
52 | BS3_BEGIN_TEXT16
|
---|
53 | BS3_PROC_BEGIN Bs3CpuBasic2_Main
|
---|
54 | push word 0 ; zero return address.
|
---|
55 | push word 0 ; zero caller BP
|
---|
56 | mov bp, sp
|
---|
57 | sub sp, 20h ; reserve 20h for 64-bit calls (we're doing them MSC style, remember).
|
---|
58 |
|
---|
59 | call _Bs3InitAll_rm
|
---|
60 |
|
---|
61 | ;
|
---|
62 | ; Start testing.
|
---|
63 | ;
|
---|
64 |
|
---|
65 |
|
---|
66 |
|
---|
67 | ;
|
---|
68 | ; Done.
|
---|
69 | ;
|
---|
70 | .shutdown:
|
---|
71 | call Bs3Shutdown
|
---|
72 | jmp .shutdown
|
---|
73 | BS3_PROC_END Bs3CpuBasic2_Main
|
---|
74 |
|
---|
75 |
|
---|
76 | ;
|
---|
77 | ; Instantiate the test template code.
|
---|
78 | ;
|
---|
79 | %include "bs3kit-template-footer.mac" ; reset the initial environemnt.
|
---|
80 |
|
---|
81 |
|
---|
82 | BS3_INSTANTIATE_TEMPLATE_WITH_WEIRD_ONES "bs3-cpu-basic-2-template.mac"
|
---|
83 |
|
---|