Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 7 Mar 2015 19:14:02 +0000 (UTC)
From:      Edward Tomasz Napierala <trasz@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r279738 - head/sys/boot/amd64/boot1.efi
Message-ID:  <201503071914.t27JE2xr011997@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: trasz
Date: Sat Mar  7 19:14:01 2015
New Revision: 279738
URL: https://svnweb.freebsd.org/changeset/base/279738

Log:
  Add error reporting (but not actual handling yet, apart from
  reporting them) for EFI calls to boot1.efi.
  
  MFC after:	1 month
  Sponsored by:	The FreeBSD Foundation

Modified:
  head/sys/boot/amd64/boot1.efi/boot1.c

Modified: head/sys/boot/amd64/boot1.efi/boot1.c
==============================================================================
--- head/sys/boot/amd64/boot1.efi/boot1.c	Sat Mar  7 18:48:00 2015	(r279737)
+++ head/sys/boot/amd64/boot1.efi/boot1.c	Sat Mar  7 19:14:01 2015	(r279738)
@@ -307,12 +307,19 @@ load(const char *fname)
 	/* XXX: For secure boot, we need our own loader here */
 	status = systab->BootServices->LoadImage(TRUE, image, bootdevpath,
 	    buffer, bufsize, &loaderhandle);
+	if (EFI_ERROR(status))
+		printf("LoadImage failed with error %d\n", status);
 
 	status = systab->BootServices->HandleProtocol(loaderhandle,
 	    &LoadedImageGUID, (VOID**)&loaded_image);
+	if (EFI_ERROR(status))
+		printf("HandleProtocol failed with error %d\n", status);
+
 	loaded_image->DeviceHandle = bootdevhandle;
 
 	status = systab->BootServices->StartImage(loaderhandle, NULL, NULL);
+	if (EFI_ERROR(status))
+		printf("StartImage failed with error %d\n", status);
 }
 
 static void



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201503071914.t27JE2xr011997>