lkml.org 
[lkml]   [2008]   [Jan]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] x86: add a crc32 checksum to the kernel image.
H. Peter Anvin wrote:
>
> Hm. I have some minor concerns about this:
>
> * The classical length field is only available in multiples of 16 (I
> realize your patches change that to some degree, but I'd hate to make
> the guarantee that the image payload is the last thing in the image --
> it loses flexibility for the future.) The end of the image isn't
> available in all cases, so this would require padding it out to a
> 16-byte boundary before appending the CRC32. An mmap is guaranteed to
> be zero-padded out to the next page boundary, so explicitly rounding sz
> up (instead of when calculating sys_size) should do the job.
>

Thinking about this more carefully, we should probably have it rounded
up to a 16-byte boundary *including* the CRC32, so the CRC32 is included
in the notional image.

-hpa


\
 
 \ /
  Last update: 2008-02-01 01:27    [W:0.106 / U:1.524 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site