1 2/* 3 * Licensed Materials - Property of IBM 4 * 5 * trousers - An open source TCG Software Stack 6 * 7 * (C) Copyright International Business Machines Corp. 2004 8 * 9 */ 10 11#ifndef _MEMMGR_H_ 12#define _MEMMGR_H_ 13 14/* 15 * For each TSP context, there is one memTable, which holds a list of memEntry's, 16 * each of which holds a pointer to some malloc'd memory that's been returned to 17 * the user. The memTable also can point to other memTable's which would be 18 * created if multiple TSP contexts were opened. 19 * 20 */ 21 22struct memEntry { 23 void *memPointer; 24 struct memEntry *nextEntry; 25}; 26 27struct memTable { 28 TSS_HCONTEXT tspContext; 29 struct memEntry *entries; 30 struct memTable *nextTable; 31}; 32 33MUTEX_DECLARE_INIT(memtable_lock); 34 35struct memTable *SpiMemoryTable = NULL; 36 37#endif 38