
22 Oct
2014
22 Oct
'14
1:04 a.m.
Hi,
Signed-off-by: Gerd Hoffmann kraxel@redhat.com
No, I didn't signed this patch off. And I will not because it is broken.
for (cnt = (maxsize / sizeof(long)) >> 1; cnt > 0; cnt >>= 1) { addr = base + cnt; /* pointer arith! */ @@ -44,6 +44,7 @@ long get_ram_size(long *base, long maxsize) addr = base; sync(); save[i] = *addr;
base[0] might not be the original value any more at this point ...
- addr = base;
- sync();
- *addr = save[last]; return (maxsize);
... so this may corrupt memory.
cheers, Gerd