![]() |
sdps
Vitis Drivers API Documentation
|
Implements the interface functions of the XSdPs driver.
See xsdps.h for a detailed description of the device and driver.
MODIFICATION HISTORY:
Ver Who Date Changes
1.00a hk/sg 10/17/13 Initial release 2.0 hk 12/13/13 Added check for arm to use sleep.h and its API's 2.1 hk 04/18/14 Add sleep for microblaze designs. CR# 781117. 2.2 hk 07/28/14 Make changes to enable use of data cache. 2.3 sk 09/23/14 Send command for relative card address when re-initialization is done.CR# 819614. Use XSdPs_Change_ClkFreq API whenever changing clock.CR# 816586. 2.4 sk 12/04/14 Added support for micro SD without WP/CD. CR# 810655. Checked for DAT Inhibit mask instead of CMD Inhibit mask in Cmd Transfer API. Added Support for SD Card v1.0 2.5 sg 07/09/15 Added SD 3.0 features kvn 07/15/15 Modified the code according to MISRAC-2012. 2.6 sk 10/12/15 Added support for SD card v1.0 CR# 840601. 2.7 sk 11/24/15 Considered the slot type befoe checking CD/WP pins. sk 12/10/15 Added support for MMC cards. sk 02/16/16 Corrected the Tuning logic. sk 03/01/16 Removed Bus Width check for eMMC. CR# 938311. 2.8 sk 05/03/16 Standard Speed for SD to 19MHz in ZynqMPSoC. CR#951024 3.0 sk 06/09/16 Added support for mkfs to calculate sector count. sk 07/16/16 Added support for UHS modes. sk 07/07/16 Used usleep API for both arm and microblaze. sk 07/16/16 Added Tap delays accordingly to different SD/eMMC operating modes. 3.1 mi 09/07/16 Removed compilation warnings with extra compiler flags. sk 10/13/16 Reduced the delay during power cycle to 1ms as per spec sk 10/19/16 Used emmc_hwreset pin to reset eMMC. sk 11/07/16 Enable Rst_n bit in ext_csd reg if not enabled. 3.2 sk 11/30/16 Modified the voltage switching sequence as per spec. sk 02/01/17 Added HSD and DDR mode support for eMMC. vns 02/09/17 Added ARMA53_32 support for ZynqMP CR#968397 sk 03/20/17 Add support for EL1 non-secure mode. 3.3 mn 05/17/17 Add support for 64bit DMA addressing mn 07/17/17 Add support for running SD at 200MHz mn 07/26/17 Fixed compilation warnings mn 08/07/17 Modify driver to support 64-bit DMA in arm64 only mn 08/17/17 Added CCI support for A53 and disabled data cache operations when it is enabled. mn 08/22/17 Updated for Word Access System support mn 09/06/17 Resolved compilation errors with IAR toolchain mn 09/26/17 Added UHS_MODE_ENABLE macro to enable UHS mode 3.4 mn 10/17/17 Use different commands for single and multi block transfers mn 03/02/18 Move UHS macro check to SD card initialization routine 3.5 mn 04/18/18 Resolve compilation warnings for sdps driver 3.6 mn 07/06/18 Fix Cppcheck and Doxygen warnings for sdps driver mn 08/01/18 Add support for using 64Bit DMA with 32-Bit Processor mn 08/01/18 Add cache invalidation call before returning from ReadPolled API mn 08/14/18 Resolve compilation warnings for ARMCC toolchain mn 10/01/18 Change Expected Response for CMD3 to R1 for MMC mus 11/05/18 Support 64 bit DMA addresses for Microblaze-X platform. 3.7 mn 02/01/19 Add support for idling of SDIO aru 03/12/19 Modified the code according to MISRAC-2012. 3.8 mn 04/12/19 Modified TapDelay code for supporting ZynqMP and Versal mn 09/17/19 Modified ADMA handling API for 32bit and 64bit addresses 3.9 sd 02/07/20 Added clock support mn 03/03/20 Restructured the code for more readability and modularity mn 03/30/20 Return XST_DEVICE_IS_STARTED when host is already started mn 03/30/20 Move Clock enabling before checking for Host already started 3.10 mn 06/05/20 Check Transfer completion separately from XSdPs_Read and XSdPs_Write APIs mn 06/05/20 Modified code for SD Non-Blocking Read support 3.14 sk 10/22/21 Add support for Erase feature. mn 11/28/21 Fix MISRA-C violations. sk 01/10/22 Add support to read slot_type parameter. 4.0 sk 02/25/22 Add support for eMMC5.1. sk 04/07/22 Add support to read custom tap delay values from design for SD/eMMC. 4.2 ro 06/12/23 Added support for system device-tree flow. 4.3 ap 11/29/23 Add support for Sanitize feature. 4.5 sk 10/28/25 Update IsCacheCoherent logic to include EL1_NS mode. 4.7 tb 10/01/26 Align Doxygen comments with AMD documentation standards
#include "xsdps_core.h"Functions | |
| s32 | XSdPs_CfgInitialize (XSdPs *InstancePtr, XSdPs_Config *ConfigPtr, UINTPTR EffectiveAddr) |
| Initializes a specific XSdPs instance so that the driver is ready to use. More... | |
| s32 | XSdPs_CardInitialize (XSdPs *InstancePtr) |
| Initializes the card with the identification mode sequence. More... | |
| s32 | XSdPs_ReadPolled (XSdPs *InstancePtr, u32 Arg, u32 BlkCnt, u8 *Buff) |
| Performs SD read in polled mode. More... | |
| s32 | XSdPs_WritePolled (XSdPs *InstancePtr, u32 Arg, u32 BlkCnt, const u8 *Buff) |
| Performs SD write in polled mode. More... | |
| s32 | XSdPs_Idle (XSdPs *InstancePtr) |
| Idles the SDIO interface. More... | |
| s32 | XSdPs_Erase (XSdPs *InstancePtr, u32 StartAddr, u32 EndAddr) |
| Performs Erase operation on the given address range. More... | |
| s32 | XSdPs_Sanitize (XSdPs *InstancePtr) |
| Performs Sanitize operation on the unmapped user address range. More... | |