Well it's been a while... Need bitmask set/clr on some registers with rmw
[AROS.git] / arch / i386-pc / bootloader / getbootinfo.c
blobebdbadbe1c312c5e1ff1590e3bd3a9a125b552af
1 /*
2 Copyright © 1995-2003, The AROS Development Team. All rights reserved.
3 $Id$
5 GetBootInfo() function.
6 */
7 #include "bootloader_intern.h"
8 #include <proto/bootloader.h>
9 #include <proto/utility.h>
10 #include <aros/multiboot.h>
11 #include <aros/debug.h>
13 /*****************************************************************************
15 NAME */
16 AROS_LH1(APTR, GetBootInfo,
18 /* SYNOPSIS */
19 AROS_LHA(ULONG, infoType, D0),
21 /* LOCATION */
22 struct BootLoaderBase *, BootLoaderBase, 1, Bootloader)
24 /* FUNCTION
25 Return information from the bootloader
27 INPUTS
28 infoType - The type of information requestes
30 RESULT
31 Pointer to resource or NULL if failed
33 NOTES
35 EXAMPLE
37 BUGS
39 SEE ALSO
41 INTERNALS
43 *****************************************************************************/
45 AROS_LIBFUNC_INIT
47 switch (infoType)
49 case BL_Video:
50 if (BootLoaderBase->Flags & MB_FLAGS_GFX)
51 return (APTR)&(BootLoaderBase->Vesa);
52 break;
53 case BL_Args:
54 if (BootLoaderBase->Flags & MB_FLAGS_CMDLINE)
55 return (APTR)&(BootLoaderBase->Args);
56 break;
57 case BL_Drives:
58 if (BootLoaderBase->Flags & MB_FLAGS_DRIVES)
59 return (APTR)&(BootLoaderBase->DriveInfo);
60 break;
61 default:
62 bug("[BootLdr] GetBootInfo: Unknown info requested\n");
65 return NULL;
67 AROS_LIBFUNC_EXIT
68 } /* GetBootInfo */