• Skip to sidebar navigation
  • Skip to content

Bitbucket

  • More
    ProjectsRepositories
  • Help
    • Online help
    • Learn Git
    • Welcome to Bitbucket
    • Keyboard shortcuts
  • Log In
Alexander Dahl
  1. Alexander Dahl

buildroot

Public
Actions
  • Clone
  • Compare

Learn more about cloning repositories

You have read-only access

Navigation
  • Source
  • Commits
  • Branches
  • All Branches Graph
  • Forks
  1. Alexander Dahl
  2. buildroot

Source

buildroot/package/libffi/0004-m68k-support-ISA-A-Coldfire-CPUs.patch
Waldemar BrodkorbWaldemar Brodkorb committed 548657513d320 Aug 2016
Raw file
Source viewDiff to previous
 
1
From 733bb188b898385cfb5ad28cc0e3ecaf38237350 Mon Sep 17 00:00:00 2001
2
From: Waldemar Brodkorb <wbx@openadk.org>
3
Date: Sat, 20 Aug 2016 00:52:19 +0200
4
Subject: [PATCH] m68k: support ISA-A Coldfire CPUs
5
​
6
Fix compilation for m68k/coldfire CPUs like mcf5208.
7
​
8
Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
9
Signed-off-by: Thorsten Glaser <tg@mirbsd.de>
10
---
11
 src/m68k/sysv.S |   29 ++++++++++++++++++++++++++++-
12
 1 file changed, 28 insertions(+), 1 deletion(-)
13
​
14
diff --git a/src/m68k/sysv.S b/src/m68k/sysv.S
15
index ec2b14f..ea40f11 100644
16
--- a/src/m68k/sysv.S
17
+++ b/src/m68k/sysv.S
18
@@ -3,7 +3,7 @@
19
    sysv.S - Copyright (c) 2012 Alan Hourihane
20
        Copyright (c) 1998, 2012 Andreas Schwab
21
        Copyright (c) 2008 Red Hat, Inc.
22
-       Copyright (c) 2012 Thorsten Glaser
23
+       Copyright (c) 2012, 2016 Thorsten Glaser
24
 
25
    m68k Foreign Function Interface
26
 
27
@@ -72,6 +72,15 @@ CALLFUNC(ffi_call_SYSV):
28
    pea 4(%sp)
29
 #if !defined __PIC__
30
    jsr CALLFUNC(ffi_prep_args)
31
+#elif defined(__uClinux__) && defined(__ID_SHARED_LIBRARY__)
32
+   move.l  _current_shared_library_a5_offset_(%a5),%a0
33
+   move.l  CALLFUNC(ffi_prep_args@GOT)(%a0),%a0
34
+   jsr     (%a0)
35
+#elif defined(__mcoldfire__) && !defined(__mcfisab__) && !defined(__mcfisac__)
36
+   move.l  #_GLOBAL_OFFSET_TABLE_@GOTPC,%a0
37
+   lea     (-6,%pc,%a0),%a0
38
+   move.l  CALLFUNC(ffi_prep_args@GOT)(%a0),%a0
39
+   jsr     (%a0)
40
 #else
41
    bsr.l   CALLFUNC(ffi_prep_args@PLTPC)
42
 #endif
43
@@ -215,6 +224,15 @@ CALLFUNC(ffi_closure_SYSV):
44
    move.l  %a0,-(%sp)
45
 #if !defined __PIC__
46
    jsr CALLFUNC(ffi_closure_SYSV_inner)
47
+#elif defined(__uClinux__) && defined(__ID_SHARED_LIBRARY__)
48
+   move.l  _current_shared_library_a5_offset_(%a5),%a0
49
+   move.l  CALLFUNC(ffi_closure_SYSV_inner@GOT)(%a0),%a0
50
+   jsr     (%a0)
51
+#elif defined(__mcoldfire__) && !defined(__mcfisab__) && !defined(__mcfisac__)
52
+   move.l  #_GLOBAL_OFFSET_TABLE_@GOTPC,%a0
53
+   lea     (-6,%pc,%a0),%a0
54
+   move.l  CALLFUNC(ffi_closure_SYSV_inner@GOT)(%a0),%a0
55
+   jsr     (%a0)
56
 #else
57
    bsr.l   CALLFUNC(ffi_closure_SYSV_inner@PLTPC)
58
 #endif
59
@@ -317,6 +335,15 @@ CALLFUNC(ffi_closure_struct_SYSV):
60
    move.l  %a0,-(%sp)
61
 #if !defined __PIC__
62
    jsr CALLFUNC(ffi_closure_SYSV_inner)
63
+#elif defined(__uClinux__) && defined(__ID_SHARED_LIBRARY__)
  • Git repository management for enterprise teams powered by Atlassian Bitbucket
  • Atlassian Bitbucket v6.7.2
  • Documentation
  • Request a feature
  • About
  • Contact Atlassian
Atlassian

Everything looks good. We'll let you know here if there's anything you should know about.