|
|
0dc71c |
From 5d1749ea5730be5c9c32228461b784317a500f4b Mon Sep 17 00:00:00 2001
|
|
|
0dc71c |
From: Vladimir Serbinenko <phcoder@gmail.com>
|
|
|
0dc71c |
Date: Wed, 26 Mar 2014 08:48:30 +0100
|
|
|
0dc71c |
Subject: [PATCH 068/143] * grub-core/lib/relocator.c: Fix the case when
|
|
|
0dc71c |
end of leftover is used.
|
|
|
0dc71c |
|
|
|
0dc71c |
---
|
|
|
0dc71c |
ChangeLog | 4 ++++
|
|
|
0dc71c |
grub-core/lib/relocator.c | 2 ++
|
|
|
0dc71c |
2 files changed, 6 insertions(+)
|
|
|
0dc71c |
|
|
|
0dc71c |
diff --git a/ChangeLog b/ChangeLog
|
|
|
0dc71c |
index 091535b..9404eda 100644
|
|
|
0dc71c |
--- a/ChangeLog
|
|
|
0dc71c |
+++ b/ChangeLog
|
|
|
0dc71c |
@@ -1,3 +1,7 @@
|
|
|
0dc71c |
+2014-03-26 Vladimir Serbinenko <phcoder@gmail.com>
|
|
|
0dc71c |
+
|
|
|
0dc71c |
+ * grub-core/lib/relocator.c: Fix the case when end of leftover is used.
|
|
|
0dc71c |
+
|
|
|
0dc71c |
2014-03-26 Fu Wei <fu.wei@linaro.org>
|
|
|
0dc71c |
|
|
|
0dc71c |
* grub-core/loader/arm64/linux.c: Remove redundant "0x".
|
|
|
0dc71c |
diff --git a/grub-core/lib/relocator.c b/grub-core/lib/relocator.c
|
|
|
0dc71c |
index 9f9770b..cb11ea5 100644
|
|
|
0dc71c |
--- a/grub-core/lib/relocator.c
|
|
|
0dc71c |
+++ b/grub-core/lib/relocator.c
|
|
|
0dc71c |
@@ -865,6 +865,8 @@ malloc_in_range (struct grub_relocator *rel,
|
|
|
0dc71c |
% GRUB_RELOCATOR_FIRMWARE_REQUESTS_QUANT;
|
|
|
0dc71c |
struct grub_relocator_fw_leftover *lo
|
|
|
0dc71c |
= events[last_lo].leftover;
|
|
|
0dc71c |
+ if (offend == 0 && alloc_end != alloc_start)
|
|
|
0dc71c |
+ offend = GRUB_RELOCATOR_FIRMWARE_REQUESTS_QUANT;
|
|
|
0dc71c |
lo->freebytes[offstart / 8]
|
|
|
0dc71c |
&= ((1 << (8 - (start % 8))) - 1);
|
|
|
0dc71c |
grub_memset (lo->freebytes + (offstart + 7) / 8, 0,
|
|
|
0dc71c |
--
|
|
|
0dc71c |
1.9.3
|
|
|
0dc71c |
|