summaryrefslogtreecommitdiffstats
path: root/drivers/crypto/vmx/ppc-xlate.pl
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/crypto/vmx/ppc-xlate.pl')
-rw-r--r--[-rwxr-xr-x]drivers/crypto/vmx/ppc-xlate.pl29
1 files changed, 5 insertions, 24 deletions
diff --git a/drivers/crypto/vmx/ppc-xlate.pl b/drivers/crypto/vmx/ppc-xlate.pl
index f89e814..a591884 100755..100644
--- a/drivers/crypto/vmx/ppc-xlate.pl
+++ b/drivers/crypto/vmx/ppc-xlate.pl
@@ -27,25 +27,13 @@ my $globl = sub {
/osx/ && do { $name = "_$name";
last;
};
- /linux.*(32|64le)/
- && do { $ret .= ".globl $name\n";
- $ret .= ".type $name,\@function";
- last;
- };
- /linux.*64/ && do { $ret .= ".globl $name\n";
- $ret .= ".type $name,\@function\n";
- $ret .= ".section \".opd\",\"aw\"\n";
- $ret .= ".align 3\n";
- $ret .= "$name:\n";
- $ret .= ".quad .$name,.TOC.\@tocbase,0\n";
- $ret .= ".previous\n";
-
- $name = ".$name";
+ /linux/
+ && do { $ret = "_GLOBAL($name)";
last;
};
}
- $ret = ".globl $name" if (!$ret);
+ $ret = ".globl $name\nalign 5\n$name:" if (!$ret);
$$global = $name;
$ret;
};
@@ -187,6 +175,8 @@ my $mtsle = sub {
" .long ".sprintf "0x%X",(31<<26)|($arg<<21)|(147*2);
};
+print "#include <asm/ppc_asm.h>\n" if $flavour =~ /linux/;
+
while($line=<>) {
$line =~ s|[#!;].*$||; # get rid of asm-style comments...
@@ -200,15 +190,6 @@ while($line=<>) {
}
{
- $line =~ s|(^[\.\w]+)\:\s*||;
- my $label = $1;
- if ($label) {
- printf "%s:",($GLOBALS{$label} or $label);
- printf "\n.localentry\t$GLOBALS{$label},0" if ($GLOBALS{$label} && $flavour =~ /linux.*64le/);
- }
- }
-
- {
$line =~ s|^\s*(\.?)(\w+)([\.\+\-]?)\s*||;
my $c = $1; $c = "\t" if ($c eq "");
my $mnemonic = $2;
OpenPOWER on IntegriCloud