Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F108098194
D16858.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1021 B
Referenced Files
None
Subscribers
None
D16858.diff
View Options
Index: head/stand/efi/loader/autoload.c
===================================================================
--- head/stand/efi/loader/autoload.c
+++ head/stand/efi/loader/autoload.c
@@ -27,11 +27,30 @@
#include <sys/cdefs.h>
__FBSDID("$FreeBSD$");
+#if defined(LOADER_FDT_SUPPORT)
+#include <sys/param.h>
+#include <fdt_platform.h>
+#endif
+
#include "loader_efi.h"
int
efi_autoload(void)
{
+#if defined(LOADER_FDT_SUPPORT)
+ /*
+ * Setup the FDT early so that we're not loading files during bi_load.
+ * Any such loading is inherently broken since bi_load uses the space
+ * just after all currently loaded files for the data that will be
+ * passed to the kernel and newly loaded files will be positioned in
+ * that same space.
+ *
+ * We're glossing over errors here because LOADER_FDT_SUPPORT does not
+ * imply that we're on a platform where FDT is a requirement. If we
+ * fix this, then the error handling here should be fixed accordingly.
+ */
+ fdt_setup_fdtp();
+#endif
return (0);
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Jan 22, 9:05 AM (2 h, 16 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16027600
Default Alt Text
D16858.diff (1021 B)
Attached To
Mode
D16858: efiloader: Setup FDT in autoload to fix overlays clobbering kenv
Attached
Detach File
Event Timeline
Log In to Comment