XilinxProcessorIPLib/drivers/dp14rxss/src/xdprxss_mcdp6000.c
int XDpRxSs_MCDP6000_ModifyRegister(XDpRxSs *DpRxSsPtr, u8 I2CSlaveAddress,
			    u16 RegisterAddress, u32 Value, u32 Mask)
{
	u32 Data;
	int Result;

	/* Verify argument.*/
	Xil_AssertNonvoid(DpRxSsPtr != NULL);

	/* Read data */
	Data = XDpRxSs_MCDP6000_GetRegister(DpRxSsPtr, I2CSlaveAddress,
				    RegisterAddress);

	/* Clear masked bits */
	Data &= ~Mask;

	/* Update */
	Data |= (Value & Mask);

	/* Write data */
	Result = XDpRxSs_MCDP6000_SetRegister(DpRxSsPtr, I2CSlaveAddress,
				      RegisterAddress, Data);

	return Result;
}
/*****************************************************************************/
/**
*
* This function modifies a single 32b word from the MCDP6000 device
*
* @param DpRxSsPtr is a pointer to the XDpRxSs core instance.
* @param I2CSlaveAddress is the 7-bit I2C slave address.
* @param RegisterAddress is the 16-bit register address.
* @param Value is the 32b word to write
* @param Mask is the 32b mask
*
* @return
*    - XST_SUCCESS Modification was successful.
*    - XST_FAILURE I2C write error.
*
* @note None.
*
******************************************************************************/
This function modifies a single 32b word from the MCDP6000 device
This function modifies a single 32b word from the MCDP6000 device
int XDpRxSs_MCDP6000_ModifyRegister(XDpRxSs *DpRxSsPtr, u8 I2CSlaveAddress,
			    u16 RegisterAddress, u32 Value, u32 Mask)
{
	u32 Data;
	int Result;
	Xil_AssertNonvoid(DpRxSsPtr != NULL);
	Data = XDpRxSs_MCDP6000_GetRegister(DpRxSsPtr, I2CSlaveAddress,
				    RegisterAddress);
	Data &= ~Mask;
	Data |= (Value & Mask);
	Result = XDpRxSs_MCDP6000_SetRegister(DpRxSsPtr, I2CSlaveAddress,
				      RegisterAddress, Data);
	return Result;
}
int XDpRxSs_MCDP6000_ModifyRegister ( XDpRxSs * DpRxSsPtr , u8 I2CSlaveAddress , u16 RegisterAddress , u32 Value , u32 Mask ) { u32 Data ; int Result ; Xil_AssertNonvoid ( DpRxSsPtr != NULL ) ; Data = XDpRxSs_MCDP6000_GetRegister ( DpRxSsPtr , I2CSlaveAddress , RegisterAddress ) ; Data &= ~ Mask ; Data |= ( Value & Mask ) ; Result = XDpRxSs_MCDP6000_SetRegister ( DpRxSsPtr , I2CSlaveAddress , RegisterAddress , Data ) ; return Result ; }
This function modifies a single 32b word from the MCDP6000 device
This function modifies a single 32b word from the MCDP6000 device
/* Verify argument.*/ /* Read data */ /* Clear masked bits */ /* Update */ /* Write data */