mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 07:43:54 -06:00
spapr: Fix implementation of Open Firmware client interface
This addresses the comments from v22. The functional changes are (the VOF ones need retesting with Pegasos2): (VOF) setprop will start failing if the machine class callback did not handle it; (VOF) unit addresses are lowered in path_offset(); (SPAPR) /chosen/bootargs is initialized from kernel_cmdline if the client did not change it. Fixes: 5c991e5d4378 ("spapr: Implement Open Firmware client interface") Cc: BALATON Zoltan <balaton@eik.bme.hu> Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Message-Id: <20210708065625.548396-1-aik@ozlabs.ru> Tested-by: BALATON Zoltan <balaton@eik.bme.hu> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
parent
89bb5a4dfd
commit
21bde1ecb6
11 changed files with 48 additions and 68 deletions
|
@ -54,32 +54,6 @@ int memcmp(const void *ptr1, const void *ptr2, size_t n)
|
|||
return 0;
|
||||
}
|
||||
|
||||
void *memmove(void *dest, const void *src, size_t n)
|
||||
{
|
||||
char *cdest;
|
||||
const char *csrc;
|
||||
int i;
|
||||
|
||||
/* Do the buffers overlap in a bad way? */
|
||||
if (src < dest && src + n >= dest) {
|
||||
/* Copy from end to start */
|
||||
cdest = dest + n - 1;
|
||||
csrc = src + n - 1;
|
||||
for (i = 0; i < n; i++) {
|
||||
*cdest-- = *csrc--;
|
||||
}
|
||||
} else {
|
||||
/* Normal copy is possible */
|
||||
cdest = dest;
|
||||
csrc = src;
|
||||
for (i = 0; i < n; i++) {
|
||||
*cdest++ = *csrc++;
|
||||
}
|
||||
}
|
||||
|
||||
return dest;
|
||||
}
|
||||
|
||||
void *memset(void *dest, int c, size_t size)
|
||||
{
|
||||
unsigned char *d = (unsigned char *)dest;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue