2 Copyright (C) 2018-2019, The AROS Development Team.
6 #include <aros/debug.h>
8 #include <proto/sysexp.h>
11 #include <aros/libcall.h>
12 #include <aros/asmcall.h>
13 #include <aros/symbolsets.h>
15 #include "ahci_intern.h"
17 extern void AHCIStartup(struct SysexpBase
*);
18 extern void AHCIShutdown(struct SysexpBase
*);
20 #if (1) // TODO : Move into libbase
21 OOP_AttrBase HiddStorageUnitAB
;
22 OOP_AttrBase HiddAHCIUnitAB
;
24 OOP_MethodID HiddStorageControllerBase
;
27 const struct OOP_ABDescr ahci_abd
[] =
29 {IID_Hidd_StorageUnit
, &HiddStorageUnitAB
},
30 {IID_Hidd_AHCIUnit
, &HiddAHCIUnitAB
},
34 static int ahcienum_init(struct SysexpAHCIBase
*AhciBase
)
36 D(bug("[ahci.sysexp] %s()\n", __func__
));
38 OOP_ObtainAttrBases(ahci_abd
);
40 HiddStorageControllerBase
= OOP_GetMethodID(IID_Hidd_StorageController
, 0);
45 ADD2INITLIB(ahcienum_init
, 10);
47 AROS_LH1(void, ModuleInit
,
48 AROS_LHA(void *, SysexpBase
, A0
),
49 struct SysexpAHCIBase
*, AhciBase
, 5, Ahci
54 D(bug("[ahci.sysexp] %s(%p)\n", __func__
, SysexpBase
));
56 AhciBase
->seab_SysexpBase
= SysexpBase
;
57 AhciBase
->seab_Module
.sem_Node
.ln_Name
= "AHCI.Module";
58 AhciBase
->seab_Module
.sem_Node
.ln_Pri
= 90;
59 AhciBase
->seab_Module
.sem_Startup
= AHCIStartup
;
60 AhciBase
->seab_Module
.sem_Shutdown
= AHCIShutdown
;
61 RegisterModule(&AhciBase
->seab_Module
, AhciBase
);