mirror of https://github.com/acidanthera/audk.git
OvmfPkg/QemuKernelLoaderFsDxe: don't quit when named blobs are present
Allows to use the qemu kernel loader pseudo file system for other purposes than loading a linux kernel (or efi binary). Passing startup.nsh for EFI shell is one example. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
parent
46ae4e4b95
commit
c45051450e
|
@ -71,6 +71,7 @@ STATIC KERNEL_BLOB_ITEMS mKernelBlobItems[] = {
|
|||
|
||||
STATIC KERNEL_BLOB *mKernelBlobs;
|
||||
STATIC UINT64 mKernelBlobCount;
|
||||
STATIC UINT64 mKernelNamedBlobCount;
|
||||
STATIC UINT64 mTotalBlobBytes;
|
||||
|
||||
//
|
||||
|
@ -1139,6 +1140,8 @@ QemuKernelFetchNamedBlobs (
|
|||
FreePool (DirEntry);
|
||||
return Status;
|
||||
}
|
||||
|
||||
mKernelNamedBlobCount++;
|
||||
}
|
||||
|
||||
FreePool (DirEntry);
|
||||
|
@ -1218,8 +1221,8 @@ QemuKernelLoaderFsDxeEntrypoint (
|
|||
}
|
||||
|
||||
Blob = FindKernelBlob (L"kernel");
|
||||
if (Blob == NULL) {
|
||||
DEBUG ((DEBUG_INFO, "%a: no kernel present -> quit\n", __func__));
|
||||
if ((Blob == NULL) && (mKernelNamedBlobCount == 0)) {
|
||||
DEBUG ((DEBUG_INFO, "%a: no kernel and no named blobs present -> quit\n", __func__));
|
||||
Status = EFI_NOT_FOUND;
|
||||
goto FreeBlobs;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue