XilinxProcessorIPLib/drivers/aienginev2/src/dma/xaie_dma.c
AieRC XAie_DmaWriteBd(XAie_DevInst *DevInst, XAie_DmaDesc *DmaDesc,
		XAie_LocType Loc, u8 BdNum)
{
	const XAie_DmaMod *DmaMod;

	if((DmaDesc == XAIE_NULL) ||
			(DmaDesc->IsReady != XAIE_COMPONENT_IS_READY)) {
		XAIE_ERROR("Invalid Arguments\n");
		return XAIE_INVALID_ARGS;
	}

	if(DmaDesc->TileType != DevInst->DevOps->GetTTypefromLoc(DevInst, Loc)) {
		XAIE_ERROR("Tile type mismatch\n");
		return XAIE_INVALID_TILE;
	}

	DmaMod = DmaDesc->DmaMod;
	if(BdNum > DmaMod->NumBds) {
		XAIE_ERROR("Invalid BD number\n");
		return XAIE_INVALID_BD_NUM;
	}

	return DmaMod->WriteBd(DevInst, DmaDesc, Loc, BdNum);
}
/*****************************************************************************/
/**
*
* This API writes a Dma Descriptor which is initialized and setup by other APIs
* into the corresponding registers and register fields in the hardware.
*
* @param	DevInst: Device Instance
* @param	DmaDesc: Initialized Dma Descriptor.
* @param	Loc: Location of AIE Tile
* @param	BdNum: Hardware BD number to be written to.
*
* @return	XAIE_OK on success, Error code on failure.
*
* @note		None.
*
******************************************************************************/
This API writes a Dma Descriptor which is initialized and setup by other APIs
into the corresponding registers and register fields in the hardware.
This API writes a Dma Descriptor which is initialized and setup by other APIs into the corresponding registers and register fields in the hardware .
AieRC XAie_DmaWriteBd(XAie_DevInst *DevInst, XAie_DmaDesc *DmaDesc,
		XAie_LocType Loc, u8 BdNum)
{
	const XAie_DmaMod *DmaMod;
	if((DmaDesc == XAIE_NULL) ||
			(DmaDesc->IsReady != XAIE_COMPONENT_IS_READY)) {
		XAIE_ERROR("Invalid Arguments\n");
		return XAIE_INVALID_ARGS;
	}
	if(DmaDesc->TileType != DevInst->DevOps->GetTTypefromLoc(DevInst, Loc)) {
		XAIE_ERROR("Tile type mismatch\n");
		return XAIE_INVALID_TILE;
	}
	DmaMod = DmaDesc->DmaMod;
	if(BdNum > DmaMod->NumBds) {
		XAIE_ERROR("Invalid BD number\n");
		return XAIE_INVALID_BD_NUM;
	}
	return DmaMod->WriteBd(DevInst, DmaDesc, Loc, BdNum);
}
AieRC XAie_DmaWriteBd ( XAie_DevInst * DevInst , XAie_DmaDesc * DmaDesc , XAie_LocType Loc , u8 BdNum ) { const XAie_DmaMod * DmaMod ; if ( ( DmaDesc == XAIE_NULL ) || ( DmaDesc -> IsReady != XAIE_COMPONENT_IS_READY ) ) { XAIE_ERROR ( " \n " ) ; return XAIE_INVALID_ARGS ; } if ( DmaDesc -> TileType != DevInst -> DevOps -> GetTTypefromLoc ( DevInst , Loc ) ) { XAIE_ERROR ( " \n " ) ; return XAIE_INVALID_TILE ; } DmaMod = DmaDesc -> DmaMod ; if ( BdNum > DmaMod -> NumBds ) { XAIE_ERROR ( " \n " ) ; return XAIE_INVALID_BD_NUM ; } return DmaMod -> WriteBd ( DevInst , DmaDesc , Loc , BdNum ) ; }
This API writes a Dma Descriptor which is initialized and setup by other APIs
into the corresponding registers and register fields in the hardware.
This API writes a Dma Descriptor which is initialized and setup by other APIs into the corresponding registers and register fields in the hardware .