XilinxProcessorIPLib/drivers/mcdma/src/xmcdma_bd.c
int XMcDma_BdSetAppWord(XMcdma_Bd* BdPtr, int Offset, u32 Word)
{
	if (XMcdma_BdRead(BdPtr, XMCDMA_BD_HAS_CTRLSTS_OFFSET) == 0) {

		xil_printf("BdRingSetAppWord: no sts cntrl"
			   "stream in hardware build, cannot set app word\r\n");

		return XST_INVALID_PARAM;
	}

	if ((Offset < 0) || (Offset > XMCDMA_LAST_APPWORD)) {

		xil_printf("BdRingSetAppWord: invalid offset");

		return XST_INVALID_PARAM;
	}

	XMcdma_BdWrite(BdPtr, XMCDMA_BD_USR0_OFFSET + Offset * 4, Word);

	return XST_SUCCESS;
}
/*****************************************************************************/
/**
 * Set the APP word at the specified APP word offset for a BD.
 *
 * @param	BdPtr is the BD to operate on
 * @param	Offset is the offset inside the APP word, it is valid from
 *		0 to 4
 * @param	Word is the value to set
 *
 * @returns
 *		- XST_SUCCESS for success
 *		- XST_INVALID_PARAM under following error conditions.
 *		1) StsCntrlStrm is not built in hardware
 *		2) Offset is not in valid range
 *
 *****************************************************************************/
Set the APP word at the specified APP word offset for a BD.
@param       BdPtr is the BD to operate on
@param       Offset is the offset inside the APP word, it is valid from
0 to 4
@param       Word is the value to set

@returns
- XST_SUCCESS for success
- XST_INVALID_PARAM under following error conditions.
1) StsCntrlStrm is not built in hardware
2) Offset is not in valid range
Set the APP word at the specified APP word offset for a BD . @param BdPtr is the BD to operate on @param Offset is the offset inside the APP word it is valid from 0 to 4 @param Word is the value to set @returns - XST_SUCCESS for success - XST_INVALID_PARAM under following error conditions . 1 ) StsCntrlStrm is not built in hardware 2 ) Offset is not in valid range
int XMcDma_BdSetAppWord(XMcdma_Bd* BdPtr, int Offset, u32 Word)
{
	if (XMcdma_BdRead(BdPtr, XMCDMA_BD_HAS_CTRLSTS_OFFSET) == 0) {
		xil_printf("BdRingSetAppWord: no sts cntrl"
			   "stream in hardware build, cannot set app word\r\n");
		return XST_INVALID_PARAM;
	}
	if ((Offset < 0) || (Offset > XMCDMA_LAST_APPWORD)) {
		xil_printf("BdRingSetAppWord: invalid offset");
		return XST_INVALID_PARAM;
	}
	XMcdma_BdWrite(BdPtr, XMCDMA_BD_USR0_OFFSET + Offset * 4, Word);
	return XST_SUCCESS;
}
int XMcDma_BdSetAppWord ( XMcdma_Bd * BdPtr , int Offset , u32 Word ) { if ( XMcdma_BdRead ( BdPtr , XMCDMA_BD_HAS_CTRLSTS_OFFSET ) == 0 ) { xil_printf ( " " " \r \n " ) ; return XST_INVALID_PARAM ; } if ( ( Offset < 0 ) || ( Offset > XMCDMA_LAST_APPWORD ) ) { xil_printf ( " " ) ; return XST_INVALID_PARAM ; } XMcdma_BdWrite ( BdPtr , XMCDMA_BD_USR0_OFFSET + Offset * 4 , Word ) ; return XST_SUCCESS ; }
Set the APP word at the specified APP word offset for a BD.
Set the APP word at the specified APP word offset for a BD .