2 Copyright © 1995-2001, The AROS Development Team. All rights reserved.
9 #include <aros/config.h>
10 #include <exec/types.h>
11 #include <utility/tagitem.h>
12 #include <aros/libcall.h>
13 #include <proto/utility.h>
14 #include "aros_intern.h"
17 #include <aros/debug.h>
20 /* Kickstart ROM location offsets */
21 #define LOC_COOKIE 0x00
22 #define LOC_ADDRESS 0x04
23 #define LOC_MAJORV 0x0c
24 #define LOC_MINORV 0x0e
25 #define LOC_ROMSIZE 0x14 /* offset from end of ROM! */
26 #define ROM_END 0x1000000
28 #define AROS_VERSION_MAJOR 1
29 #define AROS_VERSION_MINOR 12
30 #define AROS_RELEASE_DATE 7560 /* in days since 1978-01-01 */
32 #if (AROS_FLAVOUR & AROS_FLAVOUR_NATIVE)
33 /* Native AROS support functions */
38 /*****************************************************************************
41 #include <aros/inquire.h>
43 AROS_LH1(ULONG
, ArosInquireA
,
47 AROS_LHA(struct TagItem
*, taglist
, A0
),
51 struct ArosBase
*, ArosBase
, 5, Aros
)
54 This function is used to query system characteristics not easily
55 queried with another function.
58 tags -- taglist with appropriate queries. The tag's ti_Data field
59 should point to the location where the result of the query
60 is stored. Do not forget to clear the location before, as
61 queries not understood will be left untouched.
64 AI_KickstartSize ULONG
65 AI_KickstartVersion UWORD
66 AI_KickstartRevision UWORD
67 Only support these tags if we are on the native machine. On other machines this
68 call will not touch the storage space. Set the storage space to 0 if you want to
69 see if this call touches it.
72 aros.library version masquerades as AROS version. This means
73 that all aros modules must have the same major version number.
75 AI_ArosReleaseMajor IPTR
76 Update this whenever a new AROS is released.
78 AI_ArosReleaseMinor IPTR
79 Update this whenever a new AROS is released.
81 AI_ArosReleaseDate IPTR
82 Update this whenever a new AROS is released.
85 Given in the format: <d>.<m>.<y>
88 Configure time variant name.
91 All queries understood by this call will have appropriate values
92 assigned to the location a tag's ti_Data pointed to.
94 This function will (for now) always return 0.
107 ******************************************************************************/
114 # define SetData(tag,type,value) \
115 D(bug(" Data was: %d\n", *((type *)(tag->ti_Data)))); \
116 (*((type *)(tag->ti_Data)) = value); \
117 D(bug(" Data is : %d\n", *((type *)(tag->ti_Data))))
119 D(bug("ArosInquireA(taglist=%p)\n", taglist
));
121 while( (tag
= NextTagItem((const struct TagItem
**)&taglist
)))
123 D(bug(" tag = 0x%lx data = 0x%lx\n", tag
->ti_Tag
, tag
->ti_Data
));
128 #if (AROS_FLAVOUR & AROS_FLAVOUR_NATIVE)
130 Only support these tags if we are on the native machine. On other
131 machines this call will not touch the storage space. Set the
132 storage space to 0 if you want to see if this call touches it.
135 case AI_KickstartBase
:
136 SetData (tag
, APTR
, kickbase());
139 case AI_KickstartSize
:
140 SetData (tag
, ULONG
, kicksize());
143 case AI_KickstartVersion
:
144 SetData (tag
, UWORD
, *(UWORD
*)(kickbase() + LOC_MAJORV
));
147 case AI_KickstartRevision
:
148 SetData (tag
, UWORD
, *(UWORD
*)(kickbase() + LOC_MINORV
));
151 case AI_KickstartSize
:
152 SetData (tag
, ULONG
, 0);
159 aros.library version masquerades as AROS version. This means
160 that all aros modules must have the same major version number.
162 SetData (tag
, IPTR
, VERSION_NUMBER
);
165 case AI_ArosReleaseMajor
:
166 /* Update this whenever a new AROS is released */
167 SetData (tag
, IPTR
, AROS_VERSION_MAJOR
);
170 case AI_ArosReleaseMinor
:
171 /* Update this whenever a new AROS is released */
172 SetData (tag
, IPTR
, AROS_VERSION_MINOR
);
175 case AI_ArosReleaseDate
:
176 /* Update this whenever a new AROS is released */
177 SetData (tag
, IPTR
, AROS_RELEASE_DATE
);
180 case AI_ArosBuildDate
:
181 SetData (tag
, IPTR
, (IPTR
)__DATE__
);
186 SetData (tag
, IPTR
, (IPTR
) VARIANT
);
189 case AI_ArosArchitecture
:
190 SetData (tag
, IPTR
, (IPTR
) AROS_ARCHITECTURE
);
194 SetData (tag
, IPTR
, 0);
204 #if (AROS_FLAVOUR & AROS_FLAVOUR_NATIVE)
205 /* Native AROS support functions */
208 return *(ULONG
*)(ROM_END
- LOC_ROMSIZE
);
213 return (ROM_END
- kicksize());