Lines Matching refs:thisCardInst

61 STATIC agBOOLEAN agtiapi_typhAlloc( ag_card_info_t *thisCardInst )  in agtiapi_typhAlloc()  argument
63 struct agtiapi_softc *pmsc = thisCardInst->pCard; in agtiapi_typhAlloc()
131 STATIC agBOOLEAN agtiapi_InitResource( ag_card_info_t *thisCardInst ) in agtiapi_InitResource() argument
133 struct agtiapi_softc *pmsc = thisCardInst->pCard; in agtiapi_InitResource()
134 device_t devx = thisCardInst->pPCIDev; in agtiapi_InitResource()
140 if( agtiapi_typhAlloc( thisCardInst ) == AGTIAPI_FAIL ) { in agtiapi_InitResource()
160 thisCardInst->pciMemBaseRIDSpc[lBar] = PCIR_BAR(bar); in agtiapi_InitResource()
161 thisCardInst->pciMemBaseRscSpc[lBar] = in agtiapi_InitResource()
164 &(thisCardInst->pciMemBaseRIDSpc[lBar]), in agtiapi_InitResource()
167 thisCardInst->pciMemBaseRscSpc[lBar] ); in agtiapi_InitResource()
168 if ( thisCardInst->pciMemBaseRscSpc[lBar] != NULL ) { in agtiapi_InitResource()
169 thisCardInst->pciMemVirtAddrSpc[lBar] = in agtiapi_InitResource()
171 thisCardInst->pciMemBaseRscSpc[lBar] ); in agtiapi_InitResource()
172 thisCardInst->pciMemBaseSpc[lBar] = in agtiapi_InitResource()
174 thisCardInst->pciMemBaseRIDSpc[lBar]); in agtiapi_InitResource()
175 thisCardInst->pciMemSizeSpc[lBar] = in agtiapi_InitResource()
177 thisCardInst->pciMemBaseRIDSpc[lBar] ); in agtiapi_InitResource()
180 (long unsigned int)thisCardInst->pciMemVirtAddrSpc[lBar], in agtiapi_InitResource()
181 thisCardInst->pciMemSizeSpc[lBar] ); in agtiapi_InitResource()
184 thisCardInst->pciMemVirtAddrSpc[lBar] = 0; in agtiapi_InitResource()
185 thisCardInst->pciMemBaseSpc[lBar] = 0; in agtiapi_InitResource()
186 thisCardInst->pciMemSizeSpc[lBar] = 0; in agtiapi_InitResource()
190 thisCardInst->pciMemVirtAddr = thisCardInst->pciMemVirtAddrSpc[0]; in agtiapi_InitResource()
191 thisCardInst->pciMemSize = thisCardInst->pciMemSizeSpc[0]; in agtiapi_InitResource()
192 thisCardInst->pciMemBase = thisCardInst->pciMemBaseSpc[0]; in agtiapi_InitResource()
198 pRscInfo = &thisCardInst->tiRscInfo; in agtiapi_InitResource()
238 if ( thisCardInst->dmaIndex >= in agtiapi_InitResource()
239 sizeof(thisCardInst->tiDmaMem) / in agtiapi_InitResource()
240 sizeof(thisCardInst->tiDmaMem[0]) ) { in agtiapi_InitResource()
242 thisCardInst->dmaIndex ); in agtiapi_InitResource()
245 thisCardInst->tiDmaMem[thisCardInst->dmaIndex].type = in agtiapi_InitResource()
252 if( agtiapi_MemAlloc( thisCardInst, in agtiapi_InitResource()
253 &thisCardInst->tiDmaMem[thisCardInst->dmaIndex].dmaVirtAddr, in agtiapi_InitResource()
254 &thisCardInst->tiDmaMem[thisCardInst->dmaIndex].dmaPhysAddr, in agtiapi_InitResource()
261 thisCardInst->tiDmaMem[thisCardInst->dmaIndex].type, in agtiapi_InitResource()
266 thisCardInst->tiDmaMem[thisCardInst->dmaIndex].memSize = in agtiapi_InitResource()
275 thisCardInst->dmaIndex++; in agtiapi_InitResource()
279 if (thisCardInst->cacheIndex >= in agtiapi_InitResource()
280 sizeof(thisCardInst->tiCachedMem) / in agtiapi_InitResource()
281 sizeof(thisCardInst->tiCachedMem[0])) { in agtiapi_InitResource()
283 thisCardInst->cacheIndex ); in agtiapi_InitResource()
286 if ( agtiapi_MemAlloc( thisCardInst, in agtiapi_InitResource()
287 &thisCardInst->tiCachedMem[thisCardInst->cacheIndex], in agtiapi_InitResource()
307 thisCardInst->cacheIndex++; in agtiapi_InitResource()
348 if( thisCardInst->cacheIndex >= in agtiapi_InitResource()
349 sizeof( thisCardInst->tiCachedMem) / in agtiapi_InitResource()
350 sizeof( thisCardInst->tiCachedMem[0])) { in agtiapi_InitResource()
352 thisCardInst->cacheIndex ); in agtiapi_InitResource()
356 if( agtiapi_MemAlloc( thisCardInst, in agtiapi_InitResource()
357 (void *)&thisCardInst->tiCachedMem[thisCardInst->cacheIndex], in agtiapi_InitResource()
382 thisCardInst->cacheIndex++; in agtiapi_InitResource()
397 if( thisCardInst->dmaIndex >= in agtiapi_InitResource()
398 sizeof(thisCardInst->tiDmaMem) / sizeof(thisCardInst->tiDmaMem[0]) ) { in agtiapi_InitResource()
399 AGTIAPI_PRINTK( "Invalid dmaIndex %d ERROR\n", thisCardInst->dmaIndex); in agtiapi_InitResource()
402 if( agtiapi_MemAlloc( thisCardInst, (void *)&thisCardInst-> in agtiapi_InitResource()
403 tiDmaMem[thisCardInst->dmaIndex].dmaVirtAddr, in agtiapi_InitResource()
404 &thisCardInst->tiDmaMem[thisCardInst->dmaIndex]. in agtiapi_InitResource()
418 thisCardInst->tiDmaMem[thisCardInst->dmaIndex].memSize = in agtiapi_InitResource()
428 thisCardInst->dmaIndex++; in agtiapi_InitResource()
433 if( thisCardInst->cacheIndex >= in agtiapi_InitResource()
434 sizeof(thisCardInst->tiCachedMem) / in agtiapi_InitResource()
435 sizeof(thisCardInst->tiCachedMem[0]) ) { in agtiapi_InitResource()
436 AGTIAPI_PRINTK( "Invalid cacheIndex %d ERROR\n", thisCardInst->cacheIndex); in agtiapi_InitResource()
439 if( agtiapi_MemAlloc( thisCardInst, (void *)&thisCardInst-> in agtiapi_InitResource()
440 tiCachedMem[thisCardInst->cacheIndex], in agtiapi_InitResource()
460 thisCardInst->cacheIndex, in agtiapi_InitResource()
461 thisCardInst->tiCachedMem[thisCardInst->cacheIndex], in agtiapi_InitResource()
465 thisCardInst->cacheIndex++; in agtiapi_InitResource()
491 STATIC int agtiapi_ScopeDMARes( ag_card_info_t *thisCardInst ) in agtiapi_ScopeDMARes() argument
493 struct agtiapi_softc *pmsc = thisCardInst->pCard; in agtiapi_ScopeDMARes()
500 pRscInfo = &thisCardInst->tiRscInfo; in agtiapi_ScopeDMARes()
539 if( thisCardInst->cacheIndex >= in agtiapi_ScopeDMARes()
540 sizeof(thisCardInst->tiCachedMem) / in agtiapi_ScopeDMARes()
541 sizeof(thisCardInst->tiCachedMem[0]) ) { in agtiapi_ScopeDMARes()
543 thisCardInst->cacheIndex ); in agtiapi_ScopeDMARes()
623 STATIC agBOOLEAN agtiapi_MemAlloc( ag_card_info_t *thisCardInst, in agtiapi_MemAlloc() argument
645 struct agtiapi_softc *pmsc = thisCardInst->pCard; // get card reference in agtiapi_MemAlloc()
756 ag_card_info_t *thisCardInst, in agtiapi_ProbeCard() argument
773 thisCardInst->cardIdIndex = idx; in agtiapi_ProbeCard()
774 thisCardInst->pPCIDev = dev; in agtiapi_ProbeCard()
775 thisCardInst->cardNameIndex = ag_card_type[idx].cardNameIndex; in agtiapi_ProbeCard()
776 thisCardInst->cardID = in agtiapi_ProbeCard()
779 thisCardInst->pPCIDev, thisCardInst ); in agtiapi_ProbeCard()