[lkml]   [2001]   [Oct]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: crc32 cleanups
Matt Domsch <> said:
> In trying to get my EFI GUID Partition Table patch included into the stock
> kernel, Andreas Dilger suggested it was time for some crc32 cleanup, as
> the GPT patch added yet another copy of the common crc32 function. So,
> here's my first pass at it. Comments welcome.


> This patch (appended below), makes include/linux/crc32.h and
> lib/crc32.c. It generates a table based on the commonly used polynomial
> at init time provided a driver needs it. It changes ether_crc_le() to use
> this table. It renames the commonly seen ether_crc() to be
> ether_crc_be(), and puts it in crc32.h (allowing lots of copies to be
> deleted).

You could just place the functions (each with its table) into separate .c
files, and place them in the library. The linker will then include them iff
they are referenced somewhere. OTOH, they _are_ all over the place right
now, so they could just be included unconditionally. Thinking of ways to
set up to have them included in case only modules use them makes me
Dr. Horst H. von Brand Usuario #22616
Departamento de Informatica Fono: +56 32 654431
Universidad Tecnica Federico Santa Maria +56 32 654239
Casilla 110-V, Valparaiso, Chile Fax: +56 32 797513
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:17    [W:0.051 / U:0.340 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site