stub.c revision 2f8d336478536af789d654599f9523d02e0ca693
/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
* under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation; either version 2.1 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* Copyright (C) 2015 Kay Sievers <kay@vrfy.org>
*/
#include <efi.h>
#include <efilib.h>
#include "util.h"
#include "pefile.h"
#include "graphics.h"
#include "splash.h"
#include "linux.h"
/* magic string to find in the binary image */
CHAR8 *b;
(UINT8 *)".cmdline",
(UINT8 *)".linux",
(UINT8 *)".initrd",
(UINT8 *)".splash",
};
return err;
}
if (!root_dir) {
return EFI_LOAD_ERROR;
}
if (*b > 0)
FreePool(b);
}
return err;
}
if (szs[0] > 0)
cmdline_len = szs[0];
/* if we are not in secure boot mode, accept a custom command line and replace the built-in one */
UINTN i;
for (i = 0; i < cmdline_len; i++)
}
if (szs[3] > 0)
return err;
}