#include <generated/csr.h>
#include <generated/soc.h>
-#ifdef CSR_ETHMAC_BASE
-#include <udp.h>
-#include <tftp.h>
-#endif
+#include "sfl.h"
+#include "boot.h"
-#ifdef CSR_SPIFLASH_BASE
#include <spiflash.h>
-#endif
-#include "sfl.h"
-#include "boot.h"
+#include <libliteeth/udp.h>
+#include <libliteeth/tftp.h>
+
+#include <liblitesdcard/spisdcard.h>
extern void boot_helper(unsigned long r1, unsigned long r2, unsigned long r3, unsigned long addr);
// SPI HARDWARE BITBANG
#ifdef CSR_SPISDCARD_BASE
-#include "spisdcard.h"
void spisdcardboot(void)
{
#include <stdio.h>
#include <stdlib.h>
-
#include <id.h>
-#include <generated/csr.h>
#include <crc.h>
#include <system.h>
+#include <generated/csr.h>
+
#include "../command.h"
#include "../helpers.h"
#include <generated/csr.h>
-#include "sdram.h"
+#include <liblitedram/sdram.h>
#include "../command.h"
#include "../helpers.h"
#include <generated/csr.h>
-#include "mdio.h"
+#include <libliteeth/mdio.h>
#include "../command.h"
#include "../helpers.h"
#include <generated/csr.h>
-#include "sdcard.h"
+#include <liblitesdcard/sdcard.h>
#include "../command.h"
#include "../helpers.h"
#include <stdio.h>
#include <stdlib.h>
+#include <generated/csr.h>
+
#include "../command.h"
#include "../helpers.h"
#include <irq.h>
#include <crc.h>
+#include "boot.h"
+#include "readline.h"
+#include "helpers.h"
+#include "command.h"
+
#include <generated/csr.h>
#include <generated/soc.h>
#include <generated/mem.h>
#include <generated/git.h>
-#ifdef CSR_ETHMAC_BASE
-#include "udp.h"
-#endif
-
-#ifdef CSR_SPIFLASH_BASE
#include <spiflash.h>
-#endif
-#ifdef CSR_ETHPHY_MDIO_W_ADDR
-#include "mdio.h"
-#endif
+#include <liblitedram/sdram.h>
-#include "sdram.h"
-#include "sdcard.h"
-//#include "spi.h"
-#include "boot.h"
-#include "readline.h"
-#include "helpers.h"
-#include "command.h"
+#include <libliteeth/udp.h>
+#include <libliteeth/mdio.h>
+
+#include <liblitespi/spiflash.h>
+
+#include <liblitesdcard/sdcard.h>
static void boot_sequence(void)
{
#
INCLUDES = -I$(SOC_DIRECTORY)/software/include/base \
-I$(SOC_DIRECTORY)/software/include \
- -I$(SOC_DIRECTORY)/common \
+ -I$(SOC_DIRECTORY)/software \
-I$(BUILDINC_DIRECTORY) \
- -I$(CPU_DIRECTORY) \
- -I$(SOC_DIRECTORY)/software/liblitedram \
- -I$(SOC_DIRECTORY)/software/libliteeth \
- -I$(SOC_DIRECTORY)/software/liblitesdcard
+ -I$(CPU_DIRECTORY)
COMMONFLAGS = $(DEPFLAGS) -Os $(CPUFLAGS) -g3 -fomit-frame-pointer -Wall -fno-builtin -nostdinc $(INCLUDES)
CFLAGS = $(COMMONFLAGS) -fexceptions -Wstrict-prototypes -Wold-style-definition -Wmissing-prototypes
CXXFLAGS = $(COMMONFLAGS) -std=c++11 -I$(SOC_DIRECTORY)/software/include/basec++ -fexceptions -fno-rtti -ffreestanding