diff --git a/include/rm_loc.h b/include/rm_loc.h
index 5806800691c46278ab838e97c519974c3e896f6e..a5d65739b8a862953a49e37d60736137f221f52a 100644 (file)
--- a/include/rm_loc.h
+++ b/include/rm_loc.h
#include <ti/drv/rm/rm_services.h>
#include <ti/drv/rm/rm_transport.h>
+/* RM internal includes */
+#include <ti/drv/rm/include/rm_servicesloc.h>
+#include <ti/drv/rm/include/rm_policyloc.h>
+#include <ti/drv/rm/include/rm_nameserverloc.h>
+
/* AVL BBST includes */
#include <ti/drv/rm/include/tree.h>
/** Pointer to RM instance's transaction queue */
typedef void *Rm_TransactionQueue;
-/** Pointer to the RM instance's allocators */
-typedef void *Rm_Allocators;
-
-/** Pointer to the RM instance's NameServer (Valid only on Server) */
-typedef void *Rm_NameServer;
-
-/** Pointer to the RM instance's policy information */
-typedef void *Rm_Policy;
-
-/** Pointer to the RM instance's valid policy instances */
-typedef void *Rm_PolicyValidInstances;
-
-
/**
* @brief RM protocol packet resource information
*/
int32_t alignment;
/** If applicable, the NameServer name assigned to the specified
* resource. Used for commands centering on RM NameServer actions */
- char nsName[RM_RESOURCE_NAME_MAX_CHARS];
+ char nameServerName[RM_RESOURCE_NAME_MAX_CHARS];
} Rm_ResourceInfo;
/**
} Rm_AllocatorOp;
typedef struct {
- void *serviceSrcInstNode;
+ Rm_PolicyValidInstNode *serviceSrcInstNode;
Rm_AllocatorOp operation;
uint32_t allocType;
Rm_ResourceInfo *resourceInfo;
struct Rm_Allocator_s *nextAllocator;
} Rm_Allocator;
+
+typedef struct {
+ char instName[RM_INSTANCE_NAME_MAX_CHARS];
+ void *startupDtb;
+ Rm_PolicyValidInstTree *validInstTree;
+ uint32_t requestCount;
+ Rm_ServicePreMainReq *preMainReqList;
+} Rm_PreMainInst;
+
typedef struct {
- char name[RM_INSTANCE_NAME_MAX_CHARS];
- Rm_InstType instType;
- bool registeredWithDelegateOrServer;
- Rm_Policy policy;
- Rm_PolicyValidInstances validInstances;
- Rm_Allocators allocators;
- Rm_NameServer nameServer;
+ char instName[RM_INSTANCE_NAME_MAX_CHARS];
+ Rm_InstType instType;
+ bool registeredWithDelegateOrServer;
+ void *policy;
+ Rm_PolicyValidInstTree *validInstances;
+ Rm_Allocator *allocators;
+ Rm_NameServerTree *nameServer;
/* RM instance transport parameters */
- Rm_TransportRouteMap routeMap;
+ Rm_TransportRouteMap routeMap;
/* RM Transaction sequence number counter */
- uint32_t transactionSeqNum;
+ uint32_t transactionSeqNum;
/* RM transaction queue */
- Rm_TransactionQueue transactionQueue;
+ Rm_TransactionQueue transactionQueue;
/* Transport API function pointers - not global in case application wants to
* hook up different transports to RM */
- Rm_TransportCallouts transport;
+ Rm_TransportCallouts transport;
} Rm_Inst;
Rm_Transaction *Rm_transactionQueueAdd(Rm_Inst *rmInst);
@@ -180,7 +181,7 @@ Rm_Transaction *Rm_transactionQueueFind(Rm_Inst *rmInst, uint32_t transactionId)
int32_t Rm_transactionQueueDelete(Rm_Inst *rmInst, uint32_t transactionId);
uint32_t Rm_transactionGetSequenceNum(Rm_Inst *rmInst);
-Rm_Allocator *Rm_allocatorFind(Rm_Inst *rmInst, char *resourceName);
+Rm_Allocator *Rm_allocatorFind(Rm_Allocator *allocatorList, char *resourceName);
void Rm_transactionResponder (Rm_Inst *rmInst, Rm_Transaction *transaction);
void Rm_transactionForwarder (Rm_Inst *rmInst, Rm_Transaction *transaction);
/* Declare the tree structure nodes */
typedef struct Rm_AllocatedTo_s {
- void *instNameNode;
+ Rm_PolicyValidInstNode *instNameNode;
struct Rm_AllocatedTo_s *nextAllocatedTo;
} Rm_AllocatedTo;