git: 299c64e316f0 - main - stand/kboot: Initialize all the devices

From: Warner Losh <imp_at_FreeBSD.org>
Date: Wed, 07 Dec 2022 18:06:26 UTC
The branch main has been updated by imp:

URL: https://cgit.FreeBSD.org/src/commit/?id=299c64e316f026a9441775f21dfdb69e8125d58e

commit 299c64e316f026a9441775f21dfdb69e8125d58e
Author:     Warner Losh <imp@FreeBSD.org>
AuthorDate: 2022-12-07 17:50:35 +0000
Commit:     Warner Losh <imp@FreeBSD.org>
CommitDate: 2022-12-07 18:00:54 +0000

    stand/kboot: Initialize all the devices
    
    main() of the boot loader is expected to call devinit() early. We do
    this at the same time we do it in the EFI loader (except we don't have a
    buffer cache here, we don't need to initialize time and we don't have
    special efi partition handles to enumerate). This is just after we probe
    for the console.
    
    Sponsored by:           Netflix
---
 stand/kboot/main.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/stand/kboot/main.c b/stand/kboot/main.c
index 7826e06c653f..b8cd27bf3cf9 100644
--- a/stand/kboot/main.c
+++ b/stand/kboot/main.c
@@ -105,6 +105,9 @@ main(int argc, const char **argv)
 	 */
 	cons_probe();
 
+	/* Initialize all the devices */
+	devinit();
+
 	/* Choose bootdev if provided */
 	if (argc > 1)
 		bootdev = argv[1];