Load 32 MiB bootimage from a 2048 sector offset (first partiton)
This commit is contained in:
parent
ee888b8c7b
commit
552553e526
@ -10,7 +10,11 @@
|
|||||||
|
|
||||||
#define MAX_CORES 8
|
#define MAX_CORES 8
|
||||||
|
|
||||||
#define PAYLOAD_SIZE (16 << 11)
|
//#define PAYLOAD_START 0
|
||||||
|
//#define PAYLOAD_CRC7 0xE1
|
||||||
|
#define PAYLOAD_START 2048
|
||||||
|
#define PAYLOAD_CRC7 0x51
|
||||||
|
#define PAYLOAD_SIZE (16 << 12)
|
||||||
|
|
||||||
#define F_CLK 60000000UL
|
#define F_CLK 60000000UL
|
||||||
|
|
||||||
@ -163,7 +167,7 @@ static int copy(void)
|
|||||||
kprintf("LOADING ");
|
kprintf("LOADING ");
|
||||||
|
|
||||||
REG32(spi, SPI_REG_SCKDIV) = (F_CLK / 20000000UL);
|
REG32(spi, SPI_REG_SCKDIV) = (F_CLK / 20000000UL);
|
||||||
if (sd_cmd(0x52, 0, 0xE1) != 0x00) {
|
if (sd_cmd(0x52, PAYLOAD_START, PAYLOAD_CRC7) != 0x00) {
|
||||||
sd_cmd_end();
|
sd_cmd_end();
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user