lib/sw_services/xilisf/examples/xilisf_qspipsu_stm_intr_example.c
int FlashRead(XIsf *InstancePtr, u32 Address, u32 ByteCount, u8 Command)
{
	XIsf_ReadParam ReadParam;
	int Status = XST_FAILURE;

	/*
	 * Set the
	 * - Address in the Serial Flash where the data is to be read from.
	 * - Number of bytes to be read from the Serial Flash.
	 * - Read Buffer to which the data is to be read.
	 */
	ReadParam.Address = Address;
	ReadParam.NumBytes = ByteCount;
	ReadParam.ReadPtr = ReadBuffer;
	if(Command != XISF_READ){
		ReadParam.NumDummyBytes = 1;
	}

	/*
	 * Perform the Read operation.
	 */
	TransferInProgress = TRUE;
	Status = XIsf_Read(&Isf, Command, (void*) &ReadParam);
	if(Status != XST_SUCCESS) {
		return XST_FAILURE;
	}

	/*
	 * Wait till the Transfer is complete and check if there are any errors
	 * in the transaction.
	 */
	while(TransferInProgress);
	if(ErrorCount != 0) {
		return XST_FAILURE;
	}
	return XST_SUCCESS;
}
/*****************************************************************************/
/**
* This function reads from the  serial FLASH connected to the
* QSPIPSU interface.
*
* @param	InstancePtr is a pointer to the XIsf component to use.
* @param	Address contains the address to read data from in the FLASH.
* @param	ByteCount contains the number of bytes to read.
* @param	Command is the command used to read data from the flash.
*
* @return	None.
*
* @note		None.
*
******************************************************************************/
This function reads from the  serial FLASH connected to the
QSPIPSU interface.
This function reads from the serial FLASH connected to the QSPIPSU interface .
int FlashRead(XIsf *InstancePtr, u32 Address, u32 ByteCount, u8 Command)
{
	XIsf_ReadParam ReadParam;
	int Status = XST_FAILURE;
	ReadParam.Address = Address;
	ReadParam.NumBytes = ByteCount;
	ReadParam.ReadPtr = ReadBuffer;
	if(Command != XISF_READ){
		ReadParam.NumDummyBytes = 1;
	}
	TransferInProgress = TRUE;
	Status = XIsf_Read(&Isf, Command, (void*) &ReadParam);
	if(Status != XST_SUCCESS) {
		return XST_FAILURE;
	}
	while(TransferInProgress);
	if(ErrorCount != 0) {
		return XST_FAILURE;
	}
	return XST_SUCCESS;
}
int FlashRead ( XIsf * InstancePtr , u32 Address , u32 ByteCount , u8 Command ) { XIsf_ReadParam ReadParam ; int Status = XST_FAILURE ; ReadParam . Address = Address ; ReadParam . NumBytes = ByteCount ; ReadParam . ReadPtr = ReadBuffer ; if ( Command != XISF_READ ) { ReadParam . NumDummyBytes = 1 ; } TransferInProgress = TRUE ; Status = XIsf_Read ( & Isf , Command , ( void * ) & ReadParam ) ; if ( Status != XST_SUCCESS ) { return XST_FAILURE ; } while ( TransferInProgress ) ; if ( ErrorCount != 0 ) { return XST_FAILURE ; } return XST_SUCCESS ; }
This function reads from the  serial FLASH connected to the
QSPIPSU interface.
This function reads from the serial FLASH connected to the QSPIPSU interface .
/*
	 * Set the
	 * - Address in the Serial Flash where the data is to be read from.
	 * - Number of bytes to be read from the Serial Flash.
	 * - Read Buffer to which the data is to be read.
	 */ /*
	 * Perform the Read operation.
	 */ /*
	 * Wait till the Transfer is complete and check if there are any errors
	 * in the transaction.
	 */