XilinxProcessorIPLib/drivers/board_common/src/rfclk/src/xrfclk.c
u32 XRFClk_ResetChip(u32 ChipId)
{
	Xil_AssertNonvoid(ChipId < RFCLK_CHIP_NUM);

	u32 val = LMX_RESET_VAL;

	if (ChipId == RFCLK_LMK)
		val = LMK_RESET_VAL;

	if (XST_SUCCESS != XRFClk_WriteReg(ChipId, val)) {
		LOG("reset chip");
		return XST_FAILURE;
	}
	if (XST_SUCCESS != XRFClk_WriteReg(ChipId, 0)) {
		LOG("undo reset");
		return XST_FAILURE;
	}
	return XST_SUCCESS;
}
/****************************************************************************/
/**
*
* This function is used to reset one of LMX2594 or LMK04828.
*
* @param	ChipId indicates the RF clock chip Id.
*
* @return
*	- XST_SUCCESS if successful.
*	- XST_FAILURE if failed.
*
* @note		None
*
****************************************************************************/
This function is used to reset one of LMX2594 or LMK04828.
This function is used to reset one of LMX2594 or LMK04828 .
u32 XRFClk_ResetChip(u32 ChipId)
{
	Xil_AssertNonvoid(ChipId < RFCLK_CHIP_NUM);
	u32 val = LMX_RESET_VAL;
	if (ChipId == RFCLK_LMK)
		val = LMK_RESET_VAL;
	if (XST_SUCCESS != XRFClk_WriteReg(ChipId, val)) {
		LOG("reset chip");
		return XST_FAILURE;
	}
	if (XST_SUCCESS != XRFClk_WriteReg(ChipId, 0)) {
		LOG("undo reset");
		return XST_FAILURE;
	}
	return XST_SUCCESS;
}
u32 XRFClk_ResetChip ( u32 ChipId ) { Xil_AssertNonvoid ( ChipId < RFCLK_CHIP_NUM ) ; u32 val = LMX_RESET_VAL ; if ( ChipId == RFCLK_LMK ) val = LMK_RESET_VAL ; if ( XST_SUCCESS != XRFClk_WriteReg ( ChipId , val ) ) { LOG ( " " ) ; return XST_FAILURE ; } if ( XST_SUCCESS != XRFClk_WriteReg ( ChipId , 0 ) ) { LOG ( " " ) ; return XST_FAILURE ; } return XST_SUCCESS ; }
This function is used to reset one of LMX2594 or LMK04828.
This function is used to reset one of LMX2594 or LMK04828 .