xilffs: Add card check logic to support Zynq Ultrascale+ MPSoC

Add card detection logic as per Zynq Ultrascale+ MPSoc specification.

Signed-off-by: Srinivas Goud <srinivas.goud@xilinx.com>
Signed-off-by: Harini Katakam <harinik@xilinx.com>
This commit is contained in:
Harini Katakam 2015-05-14 14:21:07 +05:30 committed by Nava kishore Manne
parent ca1fb25835
commit 2e8bfd71a8

View file

@ -73,6 +73,7 @@
* Updated the FatFs to R0.10b
* Removed alignment for local buffers as CacheInvalidate
* will take care of it.
* sg 03/03/15 Added card detection check logic
*
* </pre>
*
@ -211,6 +212,18 @@ DSTATUS disk_initialize (
XSdPs_Config *SdConfig;
/*
* Card detection check
* If the HC detects the No Card State, power will be cleared
*/
while(!((XSDPS_PSR_CARD_DPL_MASK |
XSDPS_PSR_CARD_STABLE_MASK |
XSDPS_PSR_CARD_INSRT_MASK) ==
( XSdPs_GetPresentStatusReg((u32)XPAR_XSDPS_0_BASEADDR) &
(XSDPS_PSR_CARD_DPL_MASK |
XSDPS_PSR_CARD_STABLE_MASK |
XSDPS_PSR_CARD_INSRT_MASK))));
/*
* Check if card is in the socket
*/