XilinxProcessorIPLib/drivers/v_hdmirxss/src/xv_hdmirxss_hdcp.c
int XV_HdmiRxSs_HdcpSetProtocol(XV_HdmiRxSs *InstancePtr, XV_HdmiRxSs_HdcpProtocol Protocol)
{
  /* Verify argument. */
  Xil_AssertNonvoid(InstancePtr != NULL);
  Xil_AssertNonvoid((Protocol == XV_HDMIRXSS_HDCP_NONE) ||
                    (Protocol == XV_HDMIRXSS_HDCP_14)   ||
                    (Protocol == XV_HDMIRXSS_HDCP_22));

  int Status;

  /* Set requested protocol */
  if ((InstancePtr->UserHdcpProt != XV_HDMIRXSS_HDCP_NOUSERPREF) &&
		  (Protocol != InstancePtr->UserHdcpProt))
	  return XST_SUCCESS;

  InstancePtr->HdcpProtocol = Protocol;

  /* Reset both protocols */
  Status = XV_HdmiRxSs_HdcpReset(InstancePtr);
  if (Status != XST_SUCCESS) {
    InstancePtr->HdcpProtocol = XV_HDMIRXSS_HDCP_NONE;
    return XST_FAILURE;
  }

  /* Enable the requested protocol */
  Status = XV_HdmiRxSs_HdcpEnable(InstancePtr);
  if (Status != XST_SUCCESS) {
    InstancePtr->HdcpProtocol = XV_HDMIRXSS_HDCP_NONE;
    return XST_FAILURE;
  }

  return XST_SUCCESS;
}
/*****************************************************************************/
/**
*
* This function sets the active HDCP protocol and enables it.
* The protocol can be set to either HDCP 1.4, 2.2, or None.
*
* @param InstancePtr is a pointer to the XV_HdmiRxSs instance.
* @param Protocol is the requested content protection scheme of type
*        XV_HdmiRxSs_HdcpProtocol.
*
* @return
*  - XST_SUCCESS if action was successful
*  - XST_FAILURE if action was not successful
*
* @note   None.
*
******************************************************************************/
This function sets the active HDCP protocol and enables it.
The protocol can be set to either HDCP 1.4, 2.2, or None.
This function sets the active HDCP protocol and enables it . The protocol can be set to either HDCP 1 . 4 2 . 2 or None .
int XV_HdmiRxSs_HdcpSetProtocol(XV_HdmiRxSs *InstancePtr, XV_HdmiRxSs_HdcpProtocol Protocol)
{
  Xil_AssertNonvoid(InstancePtr != NULL);
  Xil_AssertNonvoid((Protocol == XV_HDMIRXSS_HDCP_NONE) ||
                    (Protocol == XV_HDMIRXSS_HDCP_14)   ||
                    (Protocol == XV_HDMIRXSS_HDCP_22));
  int Status;
  if ((InstancePtr->UserHdcpProt != XV_HDMIRXSS_HDCP_NOUSERPREF) &&
		  (Protocol != InstancePtr->UserHdcpProt))
	  return XST_SUCCESS;
  InstancePtr->HdcpProtocol = Protocol;
  Status = XV_HdmiRxSs_HdcpReset(InstancePtr);
  if (Status != XST_SUCCESS) {
    InstancePtr->HdcpProtocol = XV_HDMIRXSS_HDCP_NONE;
    return XST_FAILURE;
  }
  Status = XV_HdmiRxSs_HdcpEnable(InstancePtr);
  if (Status != XST_SUCCESS) {
    InstancePtr->HdcpProtocol = XV_HDMIRXSS_HDCP_NONE;
    return XST_FAILURE;
  }
  return XST_SUCCESS;
}
int XV_HdmiRxSs_HdcpSetProtocol ( XV_HdmiRxSs * InstancePtr , XV_HdmiRxSs_HdcpProtocol Protocol ) { Xil_AssertNonvoid ( InstancePtr != NULL ) ; Xil_AssertNonvoid ( ( Protocol == XV_HDMIRXSS_HDCP_NONE ) || ( Protocol == XV_HDMIRXSS_HDCP_14 ) || ( Protocol == XV_HDMIRXSS_HDCP_22 ) ) ; int Status ; if ( ( InstancePtr -> UserHdcpProt != XV_HDMIRXSS_HDCP_NOUSERPREF ) && ( Protocol != InstancePtr -> UserHdcpProt ) ) return XST_SUCCESS ; InstancePtr -> HdcpProtocol = Protocol ; Status = XV_HdmiRxSs_HdcpReset ( InstancePtr ) ; if ( Status != XST_SUCCESS ) { InstancePtr -> HdcpProtocol = XV_HDMIRXSS_HDCP_NONE ; return XST_FAILURE ; } Status = XV_HdmiRxSs_HdcpEnable ( InstancePtr ) ; if ( Status != XST_SUCCESS ) { InstancePtr -> HdcpProtocol = XV_HDMIRXSS_HDCP_NONE ; return XST_FAILURE ; } return XST_SUCCESS ; }
This function sets the active HDCP protocol and enables it.
This function sets the active HDCP protocol and enables it .
/* Verify argument. */ /* Set requested protocol */ /* Reset both protocols */ /* Enable the requested protocol */