XilinxProcessorIPLib/drivers/v_hdmitxss1/examples/xhdmi_example/idt_8t49n24x.c
static int IDT_8T49N24x_ModifyRegister(void *IicPtr, u8 I2CSlaveAddress,
							u16 RegisterAddress, u8 Value, u8 Mask)
{
	u8 Data;
	int Result;

	/* Read data */
	Data = IDT_8T49N24x_GetRegister(IicPtr, I2CSlaveAddress,
							RegisterAddress);

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

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

	/* Write data */
	Result = IDT_8T49N24x_SetRegister(IicPtr, I2CSlaveAddress,
							RegisterAddress, Data);

	return Result;
}
/*****************************************************************************/
/**
*
* This function modifies a single byte to the IDT 8T49N24x  
*
* @param I2CBaseAddress is the baseaddress of the I2C core.
* @param I2CSlaveAddress is the 7-bit I2C slave address.
*
* @return
*    - XST_SUCCESS Initialization was successful.
*    - XST_FAILURE I2C write error.
*
* @note None.
*
******************************************************************************/
This function modifies a single byte to the IDT 8T49N24x
This function modifies a single byte to the IDT 8T49N24x
static int IDT_8T49N24x_ModifyRegister(void *IicPtr, u8 I2CSlaveAddress,
							u16 RegisterAddress, u8 Value, u8 Mask)
{
	u8 Data;
	int Result;
	Data = IDT_8T49N24x_GetRegister(IicPtr, I2CSlaveAddress,
							RegisterAddress);
	Data &= ~Mask; 
	Data |= (Value & Mask);
	Result = IDT_8T49N24x_SetRegister(IicPtr, I2CSlaveAddress,
							RegisterAddress, Data);
	return Result;
}
static int IDT_8T49N24x_ModifyRegister ( void * IicPtr , u8 I2CSlaveAddress , u16 RegisterAddress , u8 Value , u8 Mask ) { u8 Data ; int Result ; Data = IDT_8T49N24x_GetRegister ( IicPtr , I2CSlaveAddress , RegisterAddress ) ; Data &= ~ Mask ; Data |= ( Value & Mask ) ; Result = IDT_8T49N24x_SetRegister ( IicPtr , I2CSlaveAddress , RegisterAddress , Data ) ; return Result ; }
This function modifies a single byte to the IDT 8T49N24x
This function modifies a single byte to the IDT 8T49N24x
/* Read data */ /* Clear masked bits */ /* Update */ /* Write data */