3 * - By John Hodge (thePowersGang)
13 typedef struct sEHCI_Controller tEHCI_Controller;
14 typedef struct sEHCI_Endpoint tEHCI_Endpoint;
16 #define PERIODIC_SIZE 1024
24 #define TD_POOL_SIZE (PAGE_SIZE/sizeof(tEHCI_qTD))
25 // - 256 addresses * 16 endpoints
26 #define QH_POOL_SIZE (256*16)
27 #define QH_POOL_PAGES (QH_POOL_SIZE*sizeof(tEHCI_QH)/PAGE_SIZE)
28 #define QH_POOL_NPERPAGE (PAGE_SIZE/sizeof(tEHCI_QH))
30 struct sEHCI_Controller
33 tThread *InterruptThread;
37 tEHCI_CapRegs *CapRegs;
43 int InterruptLoad[PERIODIC_SIZE];
46 tEHCI_QH *ReclaimList;
48 tMutex lAsyncSchedule;
50 tMutex PeriodicListLock;
51 Uint32 *PeriodicQueue;
52 tEHCI_QH *PeriodicQueueV[PERIODIC_SIZE];
55 tEHCI_QH *QHPools[QH_POOL_PAGES]; // [PAGE_SIZE/64]
57 tEHCI_qTD *TDPool; // [TD_POOL_SIZE]
59 tEHCI_Endpoint *FirstInterruptEndpt; // List of interrupt endpoints