mirror of
https://git.savannah.gnu.org/git/grub.git
synced 2026-10-27 09:39:22 +00:00
add a mem option into Linux automatically only if the user doesn't specify it explicitly.
This commit is contained in:
1 parent
3899310dca
commit
edb9c0d7b0
3 files changed
+18
-8
No files matched your search
+11
-6
@@ -271,12 +271,17 @@ load_image (char *kernel, char *arg, kernel_t suggested_type)
|
||||
*((unsigned short *) CL_OFFSET) = CL_MY_LOCATION - CL_BASE_ADDR;
|
||||
*((unsigned short *) CL_MAGIC_ADDR) = CL_MAGIC;
|
||||
|
||||
grub_memmove (dest, "mem=", 4);
|
||||
dest += 4;
|
||||
|
||||
dest = convert_to_ascii (dest, 'u', (extended_memory + 0x400));
|
||||
*(dest++) = 'K';
|
||||
*(dest++) = ' ';
|
||||
/* Add a mem option automatically only if the user doesn't
|
||||
specify it explicitly. */
|
||||
if (! grub_strstr (src, "mem="))
|
||||
{
|
||||
grub_memmove (dest, "mem=", 4);
|
||||
dest += 4;
|
||||
|
||||
dest = convert_to_ascii (dest, 'u', (extended_memory + 0x400));
|
||||
*(dest++) = 'K';
|
||||
*(dest++) = ' ';
|
||||
}
|
||||
|
||||
while (*src && *src != ' ')
|
||||
src++;
|
||||
|
||||
Reference in new issue
Block a user