FreeBSD kernel pms device code
osapi.c File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void ostiInitiatorEvent (tiRoot_t *ptiRoot, tiPortalContext_t *ptiPortalContext, tiDeviceHandle_t *ptiDevHandle, tiIntrEventType_t eventType, U32 eventStatus, void *parm)
 
void ostiInitiatorIOCompleted (tiRoot_t *ptiRoot, tiIORequest_t *ptiIORequest, tiIOStatus_t IOStatus, U32 statusDetail, tiSenseData_t *pSenseData, U32 context)
 
osGLOBAL tiDeviceHandle_tostiGetDevHandleFromSasAddr (tiRoot_t *root, unsigned char *sas_addr)
 
void ostiInitiatorSMPCompleted (tiRoot_t *ptiRoot, tiIORequest_t *ptiSMPRequest, tiSMPStatus_t smpStatus, bit32 tiSMPInfoLen, void *tiFrameHandle, bit32 context)
 
void ostiSingleThreadedEnter (tiRoot_t *ptiRoot, U32 queueId)
 
void ostiSingleThreadedLeave (tiRoot_t *ptiRoot, U32 queueId)
 
osGLOBAL tiDeviceHandle_tostiMapToDevHandle (tiRoot_t *root, bit8 pathId, bit8 targetId, bit8 LUN)
 
osGLOBAL FORCEINLINE bit8 ostiBitScanForward (tiRoot_t *root, bit32 *Index, bit32 Mask)
 
osGLOBAL FORCEINLINE sbit32 ostiInterlockedExchange (tiRoot_t *root, sbit32 volatile *Target, sbit32 Value)
 
osGLOBAL FORCEINLINE sbit32 ostiInterlockedIncrement (tiRoot_t *root, sbit32 volatile *Addend)
 
osGLOBAL FORCEINLINE sbit32 ostiInterlockedDecrement (tiRoot_t *root, sbit32 volatile *Addend)
 
osGLOBAL FORCEINLINE sbit32 ostiInterlockedAnd (tiRoot_t *root, sbit32 volatile *Destination, sbit32 Value)
 
osGLOBAL FORCEINLINE sbit32 ostiInterlockedOr (tiRoot_t *root, sbit32 volatile *Destination, sbit32 Value)
 
osGLOBAL bit32 ostiSetDeviceQueueDepth (tiRoot_t *tiRoot, tiIORequest_t *tiIORequest, bit32 QueueDepth)
 
osGLOBAL void ostiGetSenseKeyCount (tiRoot_t *root, bit32 fIsClear, void *SenseKeyCount, bit32 length)
 
osGLOBAL void ostiGetSCSIStatusCount (tiRoot_t *root, bit32 fIsClear, void *ScsiStatusCount, bit32 length)
 
osGLOBAL void ostiPCI_TRIGGER (tiRoot_t *tiRoot)
 
osGLOBAL bit32 ostiNumOfLUNIOCTLreq (tiRoot_t *root, void *param1, void *param2, void **tiRequestBody, tiIORequest_t **tiIORequest)
 

Function Documentation

◆ ostiBitScanForward()

osGLOBAL FORCEINLINE bit8 ostiBitScanForward ( tiRoot_t root,
bit32 Index,
bit32  Mask 
)

Definition at line 638 of file osapi.c.

◆ ostiGetDevHandleFromSasAddr()

osGLOBAL tiDeviceHandle_t * ostiGetDevHandleFromSasAddr ( tiRoot_t root,
unsigned char *  sas_addr 
)

Definition at line 364 of file osapi.c.

References NULL, pCard, _ag_portal_data::portalInfo, agtiapi_softc::portCount, agtiapi_softc::pPortalData, tiINIGetExpDeviceHandleBySasAddress(), _ag_portal_info::tiPortalContext, agtiapi_softc::tiRoot, and TIROOT_TO_CARD.

Referenced by tdsaSendSMPIoctl().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ostiGetSCSIStatusCount()

osGLOBAL void ostiGetSCSIStatusCount ( tiRoot_t root,
bit32  fIsClear,
void *  ScsiStatusCount,
bit32  length 
)

Definition at line 792 of file osapi.c.

References AGTIAPI_PRINTK.

◆ ostiGetSenseKeyCount()

osGLOBAL void ostiGetSenseKeyCount ( tiRoot_t root,
bit32  fIsClear,
void *  SenseKeyCount,
bit32  length 
)

Definition at line 781 of file osapi.c.

References AGTIAPI_PRINTK.

◆ ostiInitiatorEvent()

void ostiInitiatorEvent ( tiRoot_t ptiRoot,
tiPortalContext_t ptiPortalContext,
tiDeviceHandle_t ptiDevHandle,
tiIntrEventType_t  eventType,
U32  eventStatus,
void *  parm 
)

◆ ostiInitiatorIOCompleted()

void ostiInitiatorIOCompleted ( tiRoot_t ptiRoot,
tiIORequest_t ptiIORequest,
tiIOStatus_t  IOStatus,
U32  statusDetail,
tiSenseData_t pSenseData,
U32  context 
)

Definition at line 270 of file osapi.c.

References agNULL, agtiapi_Done(), AGTIAPI_FLAG_UP, agtiapi_hexdump(), AGTIAPI_IO, AGTIAPI_PRINTK, agtiapi_QueueCCB(), _CCB::ccb, agtiapi_softc::ccbDoneHead, agtiapi_softc::ccbDoneTail, _CCB::ccbStatus, _CCB::flags, agtiapi_softc::flags, MIN, tiIORequest::osData, OSTI_OUT_ENTER, OSTI_OUT_LEAVE, pCard, _CCB::pSenseData, REQ_DONE, SCSI_CHECK_CONDITION, _CCB::scsiStatus, tiSenseData::senseData, _CCB::senseLen, tiSenseData::senseLen, _CCB::startTime, tiDetailAborted, tiIODifError, tiIOFailed, tiIOSuccess, and TIROOT_TO_CARD.

Referenced by itdssDifHandler(), itdssDsInRecoveryHandler(), itdssDsNonOperationalHandler(), itdssEncryptionHandler(), itdssIOAbortedHandler(), itdssIOAbortResetHandler(), itdssIOCompleted(), itdssIODefaultHandler(), itdssIOFailedHandler(), itdssIONoDeviceHandler(), itdssIONotValidHandler(), itdssIOResourceUnavailableHandler(), itdssIORQEBusyFullHandler(), itdssIOSuccessHandler(), itdssIOUnderFlowHandler(), itdssLinkFailureHandler(), itdssOpenCnxErrorBadDestinationHandler(), itdssOpenCnxErrorBreakHandler(), itdssOpenCnxErrorConnectionRateNotSupportedHandler(), itdssOpenCnxErrorITNexusLossHandler(), itdssOpenCnxErrorItNexusLossNoDestHandler(), itdssOpenCnxErrorItNexusLossOpenCollideHandler(), itdssOpenCnxErrorItNexusLossOpenPathwayBlockedHandler(), itdssOpenCnxErrorItNexusLossOpenTmoHandler(), itdssOpenCnxErrorOpenPreemptedHandler(), itdssOpenCnxErrorProtocolNotSupprotedHandler(), itdssOpenCnxErrorSTPResourceBusyHandler(), itdssOpenCnxErrorUnknownErrorHandler(), itdssOpenCnxErrorWrongDestinationHandler(), itdssOpenCnxErrorZoneViolationHandler(), itdssPortInResetHandler(), itdssProgErrorHandler(), itdssSSPExtIUZeroLenHandler(), itdssTmTagNotFoundHandler(), itdssXferErrorACKNAKTimeoutHandler(), itdssXferErrorBreakHandler(), itdssXferErrorCMDIssueACKNAKTimeoutHandler(), itdssXferErrorCMDIssueBreakBeforeACKNAKHandler(), itdssXferErrorCMDIssuePhyDownBeforeACKNAKHandler(), itdssXferErrorCreditTimeoutHandler(), itdssXferErrorDisruptedPhyDownHandler(), itdssXferErrorDMAHandler(), itdssXferErrorEOBDataOverrunHandler(), itdssXferErrorInvalidSSPRspFrameHandler(), itdssXferErrorNAKReceivedHandler(), itdssXferErrorOffsetMismatchHandler(), itdssXferErrorPeerAbortedHandler(), itdssXferErrorPhyNotReadyHandler(), itdssXferErrorRxFrameHandler(), itdssXferErrorUnexpectedPhaseHandler(), itdssXferErrorXferZeroDataLenHandler(), itdssXferOpenRetryBackoffThresholdReachedHandler(), and itdssXferOpenRetryTimeoutHandler().

Here is the call graph for this function:

◆ ostiInitiatorSMPCompleted()

void ostiInitiatorSMPCompleted ( tiRoot_t ptiRoot,
tiIORequest_t ptiSMPRequest,
tiSMPStatus_t  smpStatus,
bit32  tiSMPInfoLen,
void *  tiFrameHandle,
bit32  context 
)

Definition at line 420 of file osapi.c.

References agtiapi_hexdump(), AGTIAPI_PRINTK, agtiapi_QueueCCB(), _CCB::ccb, _CCB::ccbStatus, _CCB::flags, tiIORequest::osData, OSTI_OUT_ENTER, OSTI_OUT_LEAVE, pCard, REQ_DONE, agtiapi_softc::smpDoneHead, agtiapi_softc::smpDoneTail, TIROOT_TO_CARD, and tiSMPSuccess.

Referenced by ossaSMPCAMCompleted().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ostiInterlockedAnd()

osGLOBAL FORCEINLINE sbit32 ostiInterlockedAnd ( tiRoot_t root,
sbit32 volatile *  Destination,
sbit32  Value 
)

Definition at line 738 of file osapi.c.

◆ ostiInterlockedDecrement()

osGLOBAL FORCEINLINE sbit32 ostiInterlockedDecrement ( tiRoot_t root,
sbit32 volatile *  Addend 
)

Definition at line 729 of file osapi.c.

◆ ostiInterlockedExchange()

osGLOBAL FORCEINLINE sbit32 ostiInterlockedExchange ( tiRoot_t root,
sbit32 volatile *  Target,
sbit32  Value 
)

Definition at line 710 of file osapi.c.

◆ ostiInterlockedIncrement()

osGLOBAL FORCEINLINE sbit32 ostiInterlockedIncrement ( tiRoot_t root,
sbit32 volatile *  Addend 
)

Definition at line 720 of file osapi.c.

◆ ostiInterlockedOr()

osGLOBAL FORCEINLINE sbit32 ostiInterlockedOr ( tiRoot_t root,
sbit32 volatile *  Destination,
sbit32  Value 
)

Definition at line 748 of file osapi.c.

◆ ostiMapToDevHandle()

osGLOBAL tiDeviceHandle_t * ostiMapToDevHandle ( tiRoot_t root,
bit8  pathId,
bit8  targetId,
bit8  LUN 
)

Definition at line 542 of file osapi.c.

References NULL, pCard, _ag_device::pDevHandle, agtiapi_softc::pDevList, agtiapi_softc::tgtCount, and TIROOT_TO_CARD.

Referenced by tdsaDeviceInfoGetIoctl().

Here is the caller graph for this function:

◆ ostiNumOfLUNIOCTLreq()

osGLOBAL bit32 ostiNumOfLUNIOCTLreq ( tiRoot_t root,
void *  param1,
void *  param2,
void **  tiRequestBody,
tiIORequest_t **  tiIORequest 
)

Definition at line 810 of file osapi.c.

References agtiapi_GetCCB(), AGTIAPI_PRINTK, IOCTL_CALL_FAIL, IOCTL_CALL_SUCCESS, NULL, pCard, status, _CCB::tdIOReqBody, _CCB::tiIORequest, and TIROOT_TO_CARD.

Referenced by tdsaGetNumOfLUNIOCTL().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ostiPCI_TRIGGER()

osGLOBAL void ostiPCI_TRIGGER ( tiRoot_t tiRoot)

Definition at line 803 of file osapi.c.

References ostiChipReadBit32Ext().

Referenced by ossaPCI_TRIGGER().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ostiSetDeviceQueueDepth()

osGLOBAL bit32 ostiSetDeviceQueueDepth ( tiRoot_t tiRoot,
tiIORequest_t tiIORequest,
bit32  QueueDepth 
)

Definition at line 761 of file osapi.c.

References AGTIAPI_PRINTK, _CCB::devHandle, tiDeviceHandle::osData, and tiIORequest::osData.

Referenced by itdssIOCompleted().

Here is the caller graph for this function:

◆ ostiSingleThreadedEnter()

void ostiSingleThreadedEnter ( tiRoot_t ptiRoot,
U32  queueId 
)

Definition at line 514 of file osapi.c.

References pCard, and TIROOT_TO_CARD.

Referenced by ossaSingleThreadedEnter(), and tdsaSingleThreadedEnter().

Here is the caller graph for this function:

◆ ostiSingleThreadedLeave()

void ostiSingleThreadedLeave ( tiRoot_t ptiRoot,
U32  queueId 
)

Definition at line 534 of file osapi.c.

References pCard, and TIROOT_TO_CARD.

Referenced by ossaSingleThreadedLeave(), and tdsaSingleThreadedLeave().

Here is the caller graph for this function: