mirror of
https://github.com/AuroraWright/SafeA9LHInstaller.git
synced 2025-06-26 21:52:47 +00:00
Minor stuff (2)
This commit is contained in:
parent
3ef2ab2cc7
commit
a46bf2a4ba
@ -37,8 +37,7 @@ DSTATUS disk_initialize (
|
|||||||
BYTE pdrv /* Physical drive nmuber to identify the drive */
|
BYTE pdrv /* Physical drive nmuber to identify the drive */
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
if(pdrv == CTRNAND)
|
if(pdrv == CTRNAND) ctrNandInit();
|
||||||
ctrNandInit();
|
|
||||||
|
|
||||||
return RES_OK;
|
return RES_OK;
|
||||||
}
|
}
|
||||||
|
@ -275,8 +275,8 @@ static u32 calcSDSize(u8 *csd, int type)
|
|||||||
result = (result << 8) | csd[7];
|
result = (result << 8) | csd[7];
|
||||||
result = (result << 2) | (csd[6] >> 6);
|
result = (result << 2) | (csd[6] >> 6);
|
||||||
result = (result + 1) * mult * block_len / 512;
|
result = (result + 1) * mult * block_len / 512;
|
||||||
}
|
|
||||||
break;
|
break;
|
||||||
|
}
|
||||||
case 1:
|
case 1:
|
||||||
result = csd[7] & 0x3F;
|
result = csd[7] & 0x3F;
|
||||||
result = (result << 8) | csd[6];
|
result = (result << 8) | csd[6];
|
||||||
@ -473,5 +473,5 @@ void sdmmc_get_cid(bool isNand, u32 *info)
|
|||||||
bool sdmmc_sdcard_init()
|
bool sdmmc_sdcard_init()
|
||||||
{
|
{
|
||||||
InitSD();
|
InitSD();
|
||||||
return Nand_Init() + SD_Init() == 0;
|
return (Nand_Init() | SD_Init()) == 0;
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user