diff options
author | Takashi Iwai <tiwai@suse.de> | 2012-12-11 02:07:13 +0100 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2012-12-14 03:36:44 +0100 |
commit | 919aa45e43a84d40c27c83f6117cfa6542cee14e (patch) | |
tree | 5da5152ca40016670a066abd948b0960da2c0d4b /kernel/modsign_certificate.S | |
parent | modules: don't hand 0 to vmalloc. (diff) | |
download | linux-919aa45e43a84d40c27c83f6117cfa6542cee14e.tar.xz linux-919aa45e43a84d40c27c83f6117cfa6542cee14e.zip |
MODSIGN: Avoid using .incbin in C source
Using the asm .incbin statement in C sources breaks any gcc wrapper which
assumes that preprocessed C source is self-contained. Use a separate .S
file to include the siging key and certificate.
[ This means we no longer need SYMBOL_PREFIX which is defined in kernel.h
from cbdbf2abb7844548a7d7a6a2ae7af6b6fbcea401, so I removed it -- RR ]
Tested-by: Michal Marek <mmarek@suse.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Acked-by: James Hogan <james.hogan@imgtec.com>
Diffstat (limited to 'kernel/modsign_certificate.S')
-rw-r--r-- | kernel/modsign_certificate.S | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/kernel/modsign_certificate.S b/kernel/modsign_certificate.S new file mode 100644 index 000000000000..246b4c6e6135 --- /dev/null +++ b/kernel/modsign_certificate.S @@ -0,0 +1,19 @@ +/* SYMBOL_PREFIX defined on commandline from CONFIG_SYMBOL_PREFIX */ +#ifndef SYMBOL_PREFIX +#define ASM_SYMBOL(sym) sym +#else +#define PASTE2(x,y) x##y +#define PASTE(x,y) PASTE2(x,y) +#define ASM_SYMBOL(sym) PASTE(SYMBOL_PREFIX, sym) +#endif + +#define GLOBAL(name) \ + .globl ASM_SYMBOL(name); \ + ASM_SYMBOL(name): + + .section ".init.data","aw" + +GLOBAL(modsign_certificate_list) + .incbin "signing_key.x509" + .incbin "extra_certificates" +GLOBAL(modsign_certificate_list_end) |