Android-x86
Fork
Donation

  • R/O
  • HTTP
  • SSH
  • HTTPS

bionic: Commit

bionic


Commit MetaInfo

Revisiona56cd49594d4a8a873008bd3173a5b426db5e491 (tree)
Time2009-10-08 12:35:43
AuthorChih-Wei Huang <cwhuang@linu...>
CommiterChih-Wei Huang

Log Message

Fix bluetooth compiling error on x86

* termios.h: add missed definitions
* sigsetjmp.S: add sigsetjmp, siglongjmp

Change Summary

Incremental Difference

--- a/libc/Android.mk
+++ b/libc/Android.mk
@@ -326,6 +326,7 @@ libc_common_src_files += \
326326 arch-x86/bionic/_exit_with_stack_teardown.S \
327327 arch-x86/bionic/setjmp.S \
328328 arch-x86/bionic/_setjmp.S \
329+ arch-x86/bionic/sigsetjmp.S \
329330 arch-x86/bionic/vfork.S \
330331 arch-x86/string/bzero.S \
331332 arch-x86/string/memset.S \
--- /dev/null
+++ b/libc/arch-x86/bionic/sigsetjmp.S
@@ -0,0 +1,55 @@
1+#include <machine/asm.h>
2+#include <machine/setjmp.h>
3+
4+ENTRY(sigsetjmp)
5+ movl 4(%esp),%ecx
6+ movl 8(%esp),%eax
7+ movl %eax,28(%ecx)
8+ jz 1f
9+ PIC_PROLOGUE
10+ pushl $0
11+#ifdef PIC
12+ call PIC_PLT(_C_LABEL(sigblock))
13+#else
14+ call _C_LABEL(sigblock)
15+#endif
16+ addl $4,%esp
17+ PIC_EPILOGUE
18+ movl 4(%esp),%ecx
19+ movl %eax,24(%ecx)
20+ 1: movl 0(%esp),%edx
21+ movl %edx, 0(%ecx)
22+ movl %ebx, 4(%ecx)
23+ movl %esp, 8(%ecx)
24+ movl %ebp,12(%ecx)
25+ movl %esi,16(%ecx)
26+ movl %edi,20(%ecx)
27+ xorl %eax,%eax
28+ ret
29+
30+ENTRY(siglongjmp)
31+ movl 4(%esp),%edx
32+ cmpl $0,28(%edx)
33+ jz 1f
34+ PIC_PROLOGUE
35+ pushl 24(%edx)
36+#ifdef PIC
37+ call PIC_PLT(_C_LABEL(sigsetmask))
38+#else
39+ call _C_LABEL(sigsetmask)
40+#endif
41+ addl $4,%esp
42+ PIC_EPILOGUE
43+ 1: movl 4(%esp),%edx
44+ movl 8(%esp),%eax
45+ movl 0(%edx),%ecx
46+ movl 4(%edx),%ebx
47+ movl 8(%edx),%esp
48+ movl 12(%edx),%ebp
49+ movl 16(%edx),%esi
50+ movl 20(%edx),%edi
51+ testl %eax,%eax
52+ jnz 2f
53+ incl %eax
54+ 2: movl %ecx,0(%esp)
55+ ret
--- a/libc/kernel/arch-x86/asm/termios.h
+++ b/libc/kernel/arch-x86/asm/termios.h
@@ -47,4 +47,21 @@ struct termio {
4747 #define TIOCM_OUT2 0x4000
4848 #define TIOCM_LOOP 0x8000
4949
50+#define N_TTY 0
51+#define N_SLIP 1
52+#define N_MOUSE 2
53+#define N_PPP 3
54+#define N_STRIP 4
55+#define N_AX25 5
56+#define N_X25 6
57+#define N_6PACK 7
58+#define N_MASC 8
59+#define N_R3964 9
60+#define N_PROFIBUS_FDL 10
61+#define N_IRDA 11
62+#define N_SMSBLOCK 12
63+#define N_HDLC 13
64+#define N_SYNC_PPP 14
65+#define N_HCI 15
66+
5067 #endif
Show on old repository browser