search for: 94878f9

Displaying 3 results from an estimated 3 matches for "94878f9".

Did you mean: 648789
2014 Feb 13
5
[PATCH] Potential bug in emalloc
From: Sylvain Gault <sylvain.gault at gmail.com> I found something suspicious while hunting another bug a while ago. The conditions for that bug to occur seems quite hard to meet, but it's still code quality improvement. See the commit message for details. Sylvain Gault (1): efi: Suspicious size reduction in emalloc efi/main.c | 4 +--- 1 file changed, 1 insertion(+), 3
2014 Feb 13
0
[PATCH] efi: Suspicious size reduction in emalloc
...e less than required. On 64 bits, allocate_pages may be called more times than needed. This closes bug #39. Signed-off-by: Sylvain Gault <sylvain.gault at gmail.com> --- efi/main.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/efi/main.c b/efi/main.c index 0e6b137..94878f9 100644 --- a/efi/main.c +++ b/efi/main.c @@ -691,10 +691,8 @@ EFI_STATUS emalloc(UINTN size, UINTN align, EFI_PHYSICAL_ADDRESS *addr) /* Low-memory is super-precious! */ if (end <= 1 << 20) continue; - if (start < 1 << 20) { - size -= (1 << 20) - start; + if (s...
2014 Feb 22
2
[PATCH] efi: off-by-one in gdt allocation
...ction lgdt take a segment limit that is one less than the actual size, so that base+limit points to the last byte. Signed-off-by: Sylvain Gault <sylvain.gault at gmail.com> --- efi/main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/efi/main.c b/efi/main.c index 94878f9..bdf9353 100644 --- a/efi/main.c +++ b/efi/main.c @@ -450,7 +450,7 @@ struct dt_desc { uint64_t *base; } __packed; -struct dt_desc gdt = { 0x800, (uint64_t *)0 }; +struct dt_desc gdt = { 0x7ff, (uint64_t *)0 }; struct dt_desc idt = { 0, 0 }; static inline EFI_MEMORY_DESCRIPTOR * @@ -852,12...