[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 05/23] x86/boot/reloc: create generic alloc and copy funct
From: |
Jan Beulich |
Subject: |
Re: [PATCH v2 05/23] x86/boot/reloc: create generic alloc and copy functions |
Date: |
Mon, 17 Aug 2015 09:51:58 -0600 |
>>> On 20.07.15 at 16:29, <address@hidden> wrote:
> Create generic alloc and copy functions. We need
> separate tools for memory allocation and copy to
> provide multiboot2 protocol support.
>
> Signed-off-by: Daniel Kiper <address@hidden>
> Reviewed-by: Andrew Cooper <address@hidden>
> ---
> v2 - suggestions/fixes:
> - generalize new functions names
> (suggested by Jan Beulich),
> - reduce number of casts
> (suggested by Jan Beulich).
This contradicts retaining Andrew's R-b tag. Please remember to
drop tags for everything you make non-trivial changes to.
> @@ -55,50 +56,64 @@ static void *reloc_mbi_struct(void *old, unsigned int
> bytes)
> " sub %1,%0 \n"
> " and $~15,%0 \n"
> " mov %0,alloc-1b(%%edx) \n"
> - " mov %0,%%edi \n"
> - " rep movsb \n"
> - : "=&r" (new), "+c" (bytes), "+S" (old)
> - : : "edx", "edi", "memory");
> - return new;
> + : "=&r" (s) : "r" (bytes) : "edx", "memory");
Can't "bytes" use a simple "g" constraint now?
Preferably (i.e. if correct) this changed
Acked-by: Jan Beulich <address@hidden>
Jan
- Re: [PATCH v2 05/23] x86/boot/reloc: create generic alloc and copy functions,
Jan Beulich <=