annoying, read from wrong offset in SPI FLASH
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Mon, 11 Apr 2022 15:54:16 +0000 (16:54 +0100)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Mon, 11 Apr 2022 15:54:16 +0000 (16:54 +0100)
coldboot/coldboot.c

index 4f699a53f3d7c998fc4b0b5902cc791a8e703d63..d725c83ec0feec3c6a37c69095d1439bed15c184 100644 (file)
@@ -257,7 +257,7 @@ int main(void) {
         puts("\n");
     }
 #endif
-       volatile uint32_t *qspi = (uint32_t*)spi_offs;
+       volatile uint32_t *qspi = (uint32_t*)SPI_FLASH_BASE+spi_offs;
     //volatile uint8_t *qspi_bytes = (uint8_t*)spi_offs;
      // let's not, eh? writel(0xDEAF0123, (unsigned long)&(qspi[0]));
      // tmp = readl((unsigned long)&(qspi[0]));