XilinxProcessorIPLib/drivers/hdcp1x/src/xhdcp1x_tx.c
static void XHdcp1x_TxReadKsvList(XHdcp1x *InstancePtr,
		XHdcp1x_StateType *NextStatePtr)
{
	int NumAttempts = 3;
	int KsvListIsValid = FALSE;
	u16 RepeaterInfo = 0;

	/* Determine RepeaterInfo */
	RepeaterInfo = (u16)(InstancePtr->Tx.StateHelper & 0x1FFFu);

	/* Iterate through the attempts */
	do {
		/* Attempt to validate the ksv list */
		KsvListIsValid =
			XHdcp1x_TxValidateKsvList(InstancePtr, RepeaterInfo);

		/* Update for loop */
		NumAttempts--;
	}
	while ((NumAttempts > 0) && (!KsvListIsValid));

	/* Check for success */
	if (KsvListIsValid) {
		/* Log */
		XHdcp1x_TxDebugLog(InstancePtr, "ksv list validated");

		/* Check for Repeater */
		if (InstancePtr->IsRepeater) {
			/* Set the Repeater information to be
			* passes to HDCP RX setup */
			XHdcp1x_TxSetRepeaterInfo(InstancePtr);
		}

		/* Set the downstream ready variable to 1, as Tx is now
		* authenticated and call back the RX
		*/
		InstancePtr->Tx.DownstreamReady = 1;

		/* Update NextStatePtr */
		*NextStatePtr = XHDCP1X_STATE_AUTHENTICATED;
	}
	else {
		/* Log */
		XHdcp1x_TxDebugLog(InstancePtr, "ksv list invalid");

		/* Update NextStatePtr */
		*NextStatePtr = XHDCP1X_STATE_UNAUTHENTICATED;
	}
}
/*****************************************************************************/
/**
* This function reads the ksv list from an attached repeater.
*
* @param	InstancePtr is the hdcp state machine.
* @param	NextStatePtr is the next state.
*
* @return	None.
*
* @note		None.
*
******************************************************************************/
This function reads the ksv list from an attached repeater.
This function reads the ksv list from an attached repeater .
static void XHdcp1x_TxReadKsvList(XHdcp1x *InstancePtr,
		XHdcp1x_StateType *NextStatePtr)
{
	int NumAttempts = 3;
	int KsvListIsValid = FALSE;
	u16 RepeaterInfo = 0;
	RepeaterInfo = (u16)(InstancePtr->Tx.StateHelper & 0x1FFFu);
	do {
		KsvListIsValid =
			XHdcp1x_TxValidateKsvList(InstancePtr, RepeaterInfo);
		NumAttempts--;
	}
	while ((NumAttempts > 0) && (!KsvListIsValid));
	if (KsvListIsValid) {
		XHdcp1x_TxDebugLog(InstancePtr, "ksv list validated");
		if (InstancePtr->IsRepeater) {
			XHdcp1x_TxSetRepeaterInfo(InstancePtr);
		}
		InstancePtr->Tx.DownstreamReady = 1;
		*NextStatePtr = XHDCP1X_STATE_AUTHENTICATED;
	}
	else {
		XHdcp1x_TxDebugLog(InstancePtr, "ksv list invalid");
		*NextStatePtr = XHDCP1X_STATE_UNAUTHENTICATED;
	}
}
static void XHdcp1x_TxReadKsvList ( XHdcp1x * InstancePtr , XHdcp1x_StateType * NextStatePtr ) { int NumAttempts = 3 ; int KsvListIsValid = FALSE ; u16 RepeaterInfo = 0 ; RepeaterInfo = ( u16 ) ( InstancePtr -> Tx . StateHelper & 0x1FFFu ) ; do { KsvListIsValid = XHdcp1x_TxValidateKsvList ( InstancePtr , RepeaterInfo ) ; NumAttempts -- ; } while ( ( NumAttempts > 0 ) && ( ! KsvListIsValid ) ) ; if ( KsvListIsValid ) { XHdcp1x_TxDebugLog ( InstancePtr , " " ) ; if ( InstancePtr -> IsRepeater ) { XHdcp1x_TxSetRepeaterInfo ( InstancePtr ) ; } InstancePtr -> Tx . DownstreamReady = 1 ; * NextStatePtr = XHDCP1X_STATE_AUTHENTICATED ; } else { XHdcp1x_TxDebugLog ( InstancePtr , " " ) ; * NextStatePtr = XHDCP1X_STATE_UNAUTHENTICATED ; } }
This function reads the ksv list from an attached repeater.
This function reads the ksv list from an attached repeater .
/* Determine RepeaterInfo */ /* Iterate through the attempts */ /* Attempt to validate the ksv list */ /* Update for loop */ /* Check for success */ /* Log */ /* Check for Repeater */ /* Set the Repeater information to be
			* passes to HDCP RX setup */ /* Set the downstream ready variable to 1, as Tx is now
		* authenticated and call back the RX
		*/ /* Update NextStatePtr */ /* Log */ /* Update NextStatePtr */