x86, relocs: Consolidate processing logic
authorKees Cook <keescook@chromium.org>
Fri, 12 Apr 2013 20:13:43 +0000 (13:13 -0700)
committerH. Peter Anvin <hpa@linux.intel.com>
Tue, 16 Apr 2013 22:19:13 +0000 (15:19 -0700)
commit5d442e63d6a1b5736fd48a907bd7d2d87e411816
tree624bf6368b566e7b809ddd64324c1292f297ac2f
parentbf11655cf2ecdcfaacbc8324da4a3edfe276ba9d
x86, relocs: Consolidate processing logic

Instead of counting and then processing relocations, do it in a single
pass. This splits the processing logic into separate functions for
realmode and 32-bit (and paves the way for 64-bit). Also extracts helper
functions when emitting relocations.

Based on work by Neill Clift and Michael Davidson.

Signed-off-by: Kees Cook <keescook@chromium.org>
Link: http://lkml.kernel.org/r/1365797627-20874-3-git-send-email-keescook@chromium.org
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
arch/x86/tools/relocs.c