summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-socfpga/include/mach
diff options
context:
space:
mode:
authorTrent Piepho <tpiepho@kymetacorp.com>2015-12-10 21:51:39 +0000
committerSascha Hauer <s.hauer@pengutronix.de>2015-12-14 11:32:30 +0100
commitc44e12f0bde314f33f45bab31b1f7c69157d89b4 (patch)
tree538a02cbe5f4768e3b643b2b1991f0d09dc42732 /arch/arm/mach-socfpga/include/mach
parenta9e7e68279de3aec38b038211a15a80cfc612c4e (diff)
downloadbarebox-c44e12f0bde314f33f45bab31b1f7c69157d89b4.tar.gz
socfpga: Allow setting partition xloader boots from for mmc
The xloader boots the 2nd stage barebox from socfpga_barebox_part when using NOR. But when using MMC it boots from a hardcoded "disk0.1". Add the mmc device name to the partition description and use it for mmc booting. Add an extern declaration of socfpga_barebox_part to the socfpga header so that a board can change it to use a different partition. Initialize socfpga_barebox_part to the default value instead of NULL to avoid the NULL check later. Signed-off-by: Trent Piepho <tpiepho@kymetacorp.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/arm/mach-socfpga/include/mach')
-rw-r--r--arch/arm/mach-socfpga/include/mach/generic.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/arm/mach-socfpga/include/mach/generic.h b/arch/arm/mach-socfpga/include/mach/generic.h
index 1f4247f..2a7e0ea 100644
--- a/arch/arm/mach-socfpga/include/mach/generic.h
+++ b/arch/arm/mach-socfpga/include/mach/generic.h
@@ -18,6 +18,10 @@ static inline void __udelay(unsigned us)
struct socfpga_barebox_part {
unsigned int nor_offset;
unsigned int nor_size;
+ const char *mmc_disk;
};
+/* Partition/device for xloader to load main bootloader from */
+extern const struct socfpga_barebox_part *barebox_part;
+
#endif /* __MACH_SOCFPGA_GENERIC_H */