b2fd4bb1d2d5e9abe0eb31630426610b3bf525e6
1 #include <resources/hpet.h>
2 #include <proto/arossupport.h>
4 #include "hpet_intern.h"
6 /*****************************************************************************
9 #include <proto/hpet.h>
11 AROS_LH2(BOOL
, GetUnitAttrsA
,
14 AROS_LHA(ULONG
, unit
, D0
),
15 AROS_LHA(const struct TagItem
*, tags
, A0
),
18 struct HPETBase
*, base
, 4, Hpet
)
21 Query attributes of HPET unit.
24 unit - a number of previously allocated HPET unit.
27 TRUE in case of success or FALSE if the given unit number is out of range.
39 ******************************************************************************/
43 struct TagItem
*tag
, *tstate
= (struct TagItem
*)tags
;
45 /* Owner is the only thing which can be modified, so we don't need a semaphore here */
47 if (unit
>= base
->unitCnt
)
50 while ((tag
= LibNextTagItem(&tstate
)))
55 *(IPTR
*)tag
->ti_Data
= base
->units
[unit
].base
;
59 *(IPTR
*)tag
->ti_Data
= base
->units
[unit
].block
;
63 *(const char **)tag
->ti_Data
= base
->units
[unit
].Owner
;