3 # Copyright © 2009 IBM Corporation
5 # This program is free software; you can redistribute it and/or
6 # modify it under the terms of the GNU General Public License
7 # as published by the Free Software Foundation; either version
8 # 2 of the License, or (at your option) any later version.
10 # This script checks the relcoations of a vmlinux for "suspicious"
17 die "$0 [path to objdump] [path to vmlinux]\n";
20 # Have Kbuild supply the path to objdump so we handle cross compilation.
23 my $bad_relocs_count = 0;
27 open(FD
, "$objdump -R $vmlinux|") or die;
31 # Only look at relcoation lines.
34 # These relocations are okay
35 next if (/R_PPC64_RELATIVE/ or /R_PPC64_NONE/ or
36 /R_PPC64_ADDR64\s+mach_/);
38 # If we see this type of relcoation it's an idication that
39 # we /may/ be using an old version of binutils.
40 if (/R_PPC64_UADDR64/) {
48 if ($bad_relocs_count) {
49 print "WARNING: $bad_relocs_count bad relocations\n";
54 print "WARNING: You need at binutils >= 2.19 to build a ".
55 "CONFIG_RELCOATABLE kernel\n";
This page took 0.032324 seconds and 6 git commands to generate.