diff options
Diffstat (limited to 'libc/sysdeps/linux/hppa')
36 files changed, 403 insertions, 320 deletions
diff --git a/libc/sysdeps/linux/hppa/Makefile.arch b/libc/sysdeps/linux/hppa/Makefile.arch index 9739e74d7..621a5b314 100644 --- a/libc/sysdeps/linux/hppa/Makefile.arch +++ b/libc/sysdeps/linux/hppa/Makefile.arch @@ -5,9 +5,7 @@ # Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # -CSRC := __syscall_error.c brk.c mmap.c syscall.c +CSRC-y := __syscall_error.c brk.c syscall.c -SSRC := __longjmp.S bsd-_setjmp.S bsd-setjmp.S clone.S setjmp.S \ +SSRC-y := __longjmp.S bsd-_setjmp.S bsd-setjmp.S clone.S setjmp.S \ add_n.s lshift.s rshift.s sub_n.s udiv_qrnnd.s - -include $(top_srcdir)libc/sysdeps/linux/Makefile.commonarch diff --git a/libc/sysdeps/linux/hppa/__longjmp.S b/libc/sysdeps/linux/hppa/__longjmp.S index 750863e95..ccc7afce5 100644 --- a/libc/sysdeps/linux/hppa/__longjmp.S +++ b/libc/sysdeps/linux/hppa/__longjmp.S @@ -13,14 +13,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#include <features.h> -#define _SETJMP_H -#define _ASM -#include <bits/setjmp.h> + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ /* __longjmp(jmpbuf, val) */ diff --git a/libc/sysdeps/linux/hppa/add_n.s b/libc/sysdeps/linux/hppa/add_n.s index a396b3471..faf7afe06 100644 --- a/libc/sysdeps/linux/hppa/add_n.s +++ b/libc/sysdeps/linux/hppa/add_n.s @@ -16,9 +16,8 @@ ;! License for more details. ;! You should have received a copy of the GNU Lesser General Public License -;! along with the GNU MP Library; see the file COPYING.LIB. If not, write to -;! the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, -;! MA 02111-1307, USA. +;! along with the GNU MP Library; see the file COPYING.LIB. If not, see +;! <http://www.gnu.org/licenses/>. ;! INPUT PARAMETERS diff --git a/libc/sysdeps/linux/hppa/bits/atomic.h b/libc/sysdeps/linux/hppa/bits/atomic.h new file mode 100644 index 000000000..9890af2f0 --- /dev/null +++ b/libc/sysdeps/linux/hppa/bits/atomic.h @@ -0,0 +1,98 @@ +/* Copyright (C) 2003 Free Software Foundation, Inc. + This file is part of the GNU C Library. + Contributed by Carlos O'Donell <carlos@baldric.uwo.ca>, 2005. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ + +#include <stdint.h> +#include <errno.h> +#include <bits/kernel-features.h> + +#define ABORT_INSTRUCTION __asm__("iitlbp %r0,(%sr0, %r0)") + +/* We need EFAULT, ENOSYS */ +#if !defined EFAULT && !defined ENOSYS +#define EFAULT 14 +#define ENOSYS 251 +#endif + +#ifndef _BITS_ATOMIC_H +#define _BITS_ATOMIC_H 1 + +typedef int8_t atomic8_t; +typedef uint8_t uatomic8_t; +typedef int_fast8_t atomic_fast8_t; +typedef uint_fast8_t uatomic_fast8_t; + +typedef int32_t atomic32_t; +typedef uint32_t uatomic32_t; +typedef int_fast32_t atomic_fast32_t; +typedef uint_fast32_t uatomic_fast32_t; + +typedef intptr_t atomicptr_t; +typedef uintptr_t uatomicptr_t; +typedef intmax_t atomic_max_t; +typedef uintmax_t uatomic_max_t; + +/* prev = *addr; + if (prev == old) + *addr = new; + return prev; */ + +/* Use the kernel atomic light weight syscalls on hppa */ +#define LWS "0xb0" +#define LWS_CAS "0" +/* Note r31 is the link register */ +#define LWS_CLOBBER "r1", "r26", "r25", "r24", "r23", "r22", "r21", "r20", "r28", "r31", "memory" +#define ASM_EAGAIN "11" + +/* The only basic operation needed is compare and exchange. */ +# define atomic_compare_and_exchange_val_acq(mem, newval, oldval) \ + ({ \ + volatile int lws_errno = EFAULT; \ + volatile int lws_ret = 0xdeadbeef; \ + __asm__ volatile( \ + "0: \n\t" \ + "copy %3, %%r26 \n\t" \ + "copy %4, %%r25 \n\t" \ + "copy %5, %%r24 \n\t" \ + "ble " LWS "(%%sr2, %%r0) \n\t" \ + "ldi " LWS_CAS ", %%r20 \n\t" \ + "cmpib,=,n " ASM_EAGAIN ",%%r21,0b \n\t" \ + "nop \n\t" \ + "stw %%r28, %0 \n\t" \ + "sub %%r0, %%r21, %%r21 \n\t" \ + "stw %%r21, %1 \n\t" \ + : "=m" (lws_ret), "=m" (lws_errno), "=m" (*mem) \ + : "r" (mem), "r" (oldval), "r" (newval) \ + : LWS_CLOBBER \ + ); \ + \ + if(lws_errno == EFAULT || lws_errno == ENOSYS) \ + ABORT_INSTRUCTION; \ + \ + lws_ret; \ + }) + +# define atomic_compare_and_exchange_bool_acq(mem, newval, oldval) \ + ({ \ + int ret; \ + ret = atomic_compare_and_exchange_val_acq(mem, newval, oldval); \ + /* Return 1 if it was already acquired */ \ + (ret != oldval); \ + }) + +#endif +/* _BITS_ATOMIC_H */ diff --git a/libc/sysdeps/linux/hppa/bits/eventfd.h b/libc/sysdeps/linux/hppa/bits/eventfd.h new file mode 100644 index 000000000..6182c0736 --- /dev/null +++ b/libc/sysdeps/linux/hppa/bits/eventfd.h @@ -0,0 +1,32 @@ +/* Copyright (C) 2007-2013 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library. If not, see + <http://www.gnu.org/licenses/>. */ + +#ifndef _SYS_EVENTFD_H +# error "Never use <bits/eventfd.h> directly; include <sys/eventfd.h> instead." +#endif + +/* Flags for signalfd. */ +enum + { + EFD_SEMAPHORE = 000000001, +#define EFD_SEMAPHORE EFD_SEMAPHORE + EFD_CLOEXEC = 010000000, +#define EFD_CLOEXEC EFD_CLOEXEC +/* the below value looks suspicious, should be 000200004 for consistency */ + EFD_NONBLOCK = 00200004 /* HPUX has separate NDELAY & NONBLOCK */ +#define EFD_NONBLOCK EFD_NONBLOCK + }; diff --git a/libc/sysdeps/linux/hppa/bits/fcntl.h b/libc/sysdeps/linux/hppa/bits/fcntl.h index c6aaa3afb..ed2f7e538 100644 --- a/libc/sysdeps/linux/hppa/bits/fcntl.h +++ b/libc/sysdeps/linux/hppa/bits/fcntl.h @@ -14,9 +14,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ #ifndef _FCNTL_H # error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead." @@ -50,6 +49,8 @@ # define O_DIRECTORY 00010000 /* Must be a directory. */ # define O_NOFOLLOW 00000200 /* Do not follow links. */ # define O_NOATIME 04000000 /* Do not set atime. */ +# define O_CLOEXEC 010000000 /* set close_on_exec */ +# define O_PATH 020000000 /* Resolve pathname but do not open file. */ #endif #ifdef __USE_LARGEFILE64 @@ -96,6 +97,8 @@ # define F_NOTIFY 1026 /* Request notfications on a directory. */ # define F_DUPFD_CLOEXEC 1030 /* Duplicate file descriptor with close-on-exit set on new fd. */ +# define F_SETPIPE_SZ 1031 /* Set pipe page size array. */ +# define F_GETPIPE_SZ 1032 /* Get pipe page size array. */ #endif /* for F_[GET|SET]FL */ @@ -176,7 +179,7 @@ struct flock64 #endif -#ifdef __USE_GNU +#if defined __USE_GNU && defined __UCLIBC_LINUX_SPECIFIC__ /* Flags for SYNC_FILE_RANGE. */ # define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages in the range before performing the @@ -199,7 +202,7 @@ struct flock64 __BEGIN_DECLS -#ifdef __USE_GNU +#if defined __USE_GNU && defined __UCLIBC_LINUX_SPECIFIC__ /* Provide kernel hint to read ahead. */ extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count) diff --git a/libc/sysdeps/linux/hppa/bits/fenv.h b/libc/sysdeps/linux/hppa/bits/fenv.h index c5f8c4345..f59a32400 100644 --- a/libc/sysdeps/linux/hppa/bits/fenv.h +++ b/libc/sysdeps/linux/hppa/bits/fenv.h @@ -13,9 +13,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ #ifndef _FENV_H # error "Never use <bits/fenv.h> directly; include <fenv.h> instead." diff --git a/libc/sysdeps/linux/hppa/bits/ipc.h b/libc/sysdeps/linux/hppa/bits/ipc.h index d80cf0699..e634a74b3 100644 --- a/libc/sysdeps/linux/hppa/bits/ipc.h +++ b/libc/sysdeps/linux/hppa/bits/ipc.h @@ -12,9 +12,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ #ifndef _SYS_IPC_H # error "Never use <bits/ipc.h> directly; include <sys/ipc.h> instead." diff --git a/libc/sysdeps/linux/hppa/bits/kernel_sigaction.h b/libc/sysdeps/linux/hppa/bits/kernel_sigaction.h index 4ae53fd3c..5834bf37a 100644 --- a/libc/sysdeps/linux/hppa/bits/kernel_sigaction.h +++ b/libc/sysdeps/linux/hppa/bits/kernel_sigaction.h @@ -12,15 +12,4 @@ struct old_kernel_sigaction { unsigned long sa_flags; }; -/* This is the sigaction structure from the Linux 2.1.68 kernel. */ - -struct kernel_sigaction { - __sighandler_t k_sa_handler; - unsigned long sa_flags; - sigset_t sa_mask; -}; - -extern int __syscall_rt_sigaction (int, const struct kernel_sigaction *__unbounded, - struct kernel_sigaction *__unbounded, size_t) attribute_hidden; - #endif diff --git a/libc/sysdeps/linux/hppa/bits/kernel_stat.h b/libc/sysdeps/linux/hppa/bits/kernel_stat.h index e4d784e91..097abfb40 100644 --- a/libc/sysdeps/linux/hppa/bits/kernel_stat.h +++ b/libc/sysdeps/linux/hppa/bits/kernel_stat.h @@ -1,12 +1,8 @@ /* Ripped from linux/include/asm-parisc/stat.h * and renamed 'struct stat' to 'struct kernel_stat' */ -#ifndef _PARISC_STAT_H -#define _PARISC_STAT_H - -#ifndef _LIBC -#error bits/kernel_stat.h is for internal uClibc use only! -#endif +#ifndef _BITS_STAT_STRUCT_H +#define _BITS_STAT_STRUCT_H struct kernel_stat { unsigned int st_dev; /* dev_t is 32 bits on parisc */ @@ -17,12 +13,9 @@ struct kernel_stat { unsigned short st_reserved2; /* old st_gid */ unsigned int st_rdev; off_t st_size; - time_t st_atime; - unsigned int st_atime_nsec; - time_t st_mtime; - unsigned int st_mtime_nsec; - time_t st_ctime; - unsigned int st_ctime_nsec; + struct timespec st_atim; + struct timespec st_mtim; + struct timespec st_ctim; int st_blksize; int st_blocks; unsigned int __unused1; /* ACL stuff */ @@ -39,8 +32,6 @@ struct kernel_stat { unsigned int st_spare4[3]; }; -#define STAT_HAVE_NSEC 1 - /* This is the struct that 32-bit userspace applications are expecting. * How 64-bit apps are going to be compiled, I have no idea. But at least * this way, we don't have a wrapper in the kernel. @@ -60,12 +51,9 @@ struct kernel_stat64 { signed int st_blksize; signed long long st_blocks; - signed int st_atime; - unsigned int st_atime_nsec; - signed int st_mtime; - unsigned int st_mtime_nsec; - signed int st_ctime; - unsigned int st_ctime_nsec; + struct timespec st_atim; + struct timespec st_mtim; + struct timespec st_ctim; unsigned long long st_ino; }; diff --git a/libc/sysdeps/linux/hppa/bits/kernel_types.h b/libc/sysdeps/linux/hppa/bits/kernel_types.h index 4441f9b29..6b2e79476 100644 --- a/libc/sysdeps/linux/hppa/bits/kernel_types.h +++ b/libc/sysdeps/linux/hppa/bits/kernel_types.h @@ -45,6 +45,8 @@ typedef long long __kernel_off64_t; typedef unsigned long long __kernel_ino64_t; typedef unsigned int __kernel_old_dev_t; +typedef long __kernel_long_t; +typedef unsigned long __kernel_ulong_t; typedef struct { #ifdef __USE_ALL diff --git a/libc/sysdeps/linux/hppa/bits/mman.h b/libc/sysdeps/linux/hppa/bits/mman.h index 54531ecf2..cbde4b8d4 100644 --- a/libc/sysdeps/linux/hppa/bits/mman.h +++ b/libc/sysdeps/linux/hppa/bits/mman.h @@ -1,5 +1,5 @@ /* Definitions for POSIX memory map interface. Linux/HPPA version. - Copyright (C) 1997, 1998, 2000, 2003 Free Software Foundation, Inc. + Copyright (C) 1997-2015 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -13,20 +13,19 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library. If not, see + <http://www.gnu.org/licenses/>. */ #ifndef _SYS_MMAN_H # error "Never use <bits/mman.h> directly; include <sys/mman.h> instead." #endif -/* these are basically taken from the kernel definitions */ +/* These are taken from the kernel definitions. */ -#define PROT_READ 0x1 /* page can be read */ -#define PROT_WRITE 0x2 /* page can be written */ -#define PROT_EXEC 0x4 /* page can be executed */ -#define PROT_NONE 0x0 /* page can not be accessed */ +#define PROT_READ 0x1 /* Page can be read */ +#define PROT_WRITE 0x2 /* Page can be written */ +#define PROT_EXEC 0x4 /* Page can be executed */ +#define PROT_NONE 0x0 /* Page can not be accessed */ #define PROT_GROWSDOWN 0x01000000 /* Extend change to start of growsdown vma (mprotect only). */ #define PROT_GROWSUP 0x02000000 /* Extend change to start of @@ -34,59 +33,83 @@ #define MAP_SHARED 0x01 /* Share changes */ #define MAP_PRIVATE 0x02 /* Changes are private */ -#define MAP_TYPE 0x03 /* Mask for type of mapping */ +#ifdef __USE_MISC +# define MAP_TYPE 0x03 /* Mask for type of mapping */ +#endif + +/* Other flags. */ #define MAP_FIXED 0x04 /* Interpret addr exactly */ -#define MAP_ANONYMOUS 0x10 /* don't use a file */ +#ifdef __USE_MISC +# define MAP_FILE 0x0 +# define MAP_ANONYMOUS 0x10 /* Don't use a file */ +# define MAP_ANON MAP_ANONYMOUS +# define MAP_VARIABLE 0 +/* When MAP_HUGETLB is set bits [26:31] encode the log2 of the huge page size. */ +# define MAP_HUGE_SHIFT 26 +# define MAP_HUGE_MASK 0x3f +#endif + +/* These are Linux-specific. */ +#ifdef __USE_MISC +# define MAP_DENYWRITE 0x0800 /* ETXTBSY */ +# define MAP_EXECUTABLE 0x1000 /* Mark it as an executable */ +# define MAP_LOCKED 0x2000 /* Pages are locked */ +# define MAP_NORESERVE 0x4000 /* Don't check for reservations */ +# define MAP_GROWSDOWN 0x8000 /* Stack-like segment */ +# define MAP_POPULATE 0x10000 /* Populate (prefault) pagetables */ +# define MAP_NONBLOCK 0x20000 /* Do not block on IO */ +#endif -#define MAP_DENYWRITE 0x0800 /* ETXTBSY */ -#define MAP_EXECUTABLE 0x1000 /* mark it as an executable */ -#define MAP_LOCKED 0x2000 /* pages are locked */ -#define MAP_NORESERVE 0x4000 /* don't check for reservations */ -#define MAP_GROWSDOWN 0x8000 /* stack-like segment */ -#define MAP_POPULATE 0x10000 /* populate (prefault) pagetables */ -#define MAP_NONBLOCK 0x20000 /* do not block on IO */ +/* Flags to "msync" */ +#define MS_SYNC 1 /* Synchronous memory sync */ +#define MS_ASYNC 2 /* Sync memory asynchronously */ +#define MS_INVALIDATE 4 /* Invalidate the caches */ -#define MS_SYNC 1 /* synchronous memory sync */ -#define MS_ASYNC 2 /* sync memory asynchronously */ -#define MS_INVALIDATE 4 /* invalidate the caches */ +/* Flags to "mlockall" */ +#define MCL_CURRENT 1 /* Lock all current mappings */ +#define MCL_FUTURE 2 /* Lock all future mappings */ -#define MCL_CURRENT 1 /* lock all current mappings */ -#define MCL_FUTURE 2 /* lock all future mappings */ +/* Flags for `mremap'. */ +#ifdef __USE_GNU +# define MREMAP_MAYMOVE 1 +# define MREMAP_FIXED 2 +#endif -/* Advice to "madvise" */ -#ifdef __USE_BSD -# define MADV_NORMAL 0 /* no further special treatment */ -# define MADV_RANDOM 1 /* expect random page references */ -# define MADV_SEQUENTIAL 2 /* expect sequential page references */ -# define MADV_WILLNEED 3 /* will need these pages */ -# define MADV_DONTNEED 4 /* dont need these pages */ -# define MADV_SPACEAVAIL 5 /* insure that resources are reserved */ +/* Advice to "madvise" */ +#ifdef __USE_MISC +# define MADV_NORMAL 0 /* No further special treatment */ +# define MADV_RANDOM 1 /* Expect random page references */ +# define MADV_SEQUENTIAL 2 /* Expect sequential page references */ +# define MADV_WILLNEED 3 /* Will need these pages */ +# define MADV_DONTNEED 4 /* Dont need these pages */ +# define MADV_SPACEAVAIL 5 /* Insure that resources are reserved */ # define MADV_VPS_PURGE 6 /* Purge pages from VM page cache */ # define MADV_VPS_INHERIT 7 /* Inherit parents page size */ # define MADV_REMOVE 9 /* Remove these pages and resources. */ # define MADV_DONTFORK 10 /* Do not inherit across fork. */ # define MADV_DOFORK 11 /* Do inherit across fork. */ +# define MADV_MERGEABLE 65 /* KSM may merge identical pages */ +# define MADV_UNMERGEABLE 66 /* KSM may not merge identical pages */ #endif /* The range 12-64 is reserved for page size specification. */ -#define MADV_4K_PAGES 12 /* Use 4K pages */ -#define MADV_16K_PAGES 14 /* Use 16K pages */ -#define MADV_64K_PAGES 16 /* Use 64K pages */ -#define MADV_256K_PAGES 18 /* Use 256K pages */ -#define MADV_1M_PAGES 20 /* Use 1 Megabyte pages */ -#define MADV_4M_PAGES 22 /* Use 4 Megabyte pages */ -#define MADV_16M_PAGES 24 /* Use 16 Megabyte pages */ -#define MADV_64M_PAGES 26 /* Use 64 Megabyte pages */ - -/* compatibility flags */ -#define MAP_ANON MAP_ANONYMOUS -#define MAP_FILE 0 -#define MAP_VARIABLE 0 - -/* Flags for `mremap'. */ -#ifdef __USE_GNU -# define MREMAP_MAYMOVE 1 -# define MREMAP_FIXED 2 +/* These are Linux-specific. */ +#ifdef __USE_MISC +# define MADV_4K_PAGES 12 /* Use 4K pages. */ +# define MADV_16K_PAGES 14 /* Use 16K pages. */ +# define MADV_64K_PAGES 16 /* Use 64K pages. */ +# define MADV_256K_PAGES 18 /* Use 256K pages. */ +# define MADV_1M_PAGES 20 /* Use 1 Megabyte pages. */ +# define MADV_4M_PAGES 22 /* Use 4 Megabyte pages. */ +# define MADV_16M_PAGES 24 /* Use 16 Megabyte pages. */ +# define MADV_64M_PAGES 26 /* Use 64 Megabyte pages. */ #endif - +/* The POSIX people had to invent similar names for the same things. */ +#ifdef __USE_XOPEN2K +# define POSIX_MADV_NORMAL 0 /* No further special treatment. */ +# define POSIX_MADV_RANDOM 1 /* Expect random page references. */ +# define POSIX_MADV_SEQUENTIAL 2 /* Expect sequential page references. */ +# define POSIX_MADV_WILLNEED 3 /* Will need these pages. */ +# define POSIX_MADV_DONTNEED 4 /* Don't need these pages. */ +#endif diff --git a/libc/sysdeps/linux/hppa/bits/setjmp.h b/libc/sysdeps/linux/hppa/bits/setjmp.h index 4395b8f56..3a0a3b6ad 100644 --- a/libc/sysdeps/linux/hppa/bits/setjmp.h +++ b/libc/sysdeps/linux/hppa/bits/setjmp.h @@ -1,4 +1,4 @@ -/* Copyright (C) 2000 Free Software Foundation, Inc. +/* Copyright (C) 2000, 2005, 2006 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -12,9 +12,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ /* Define the machine-dependent type `jmp_buf'. HPPA version. */ #ifndef _BITS_SETJMP_H @@ -29,17 +28,6 @@ easier, and to ensure proper alignment. Naturally, user code should not depend on either representation. */ -#if defined __USE_MISC || defined _ASM -#define JB_SP (76/4) -#endif - -#ifndef _ASM typedef double __jmp_buf[21]; -#endif - -/* Test if longjmp to JMPBUF would unwind the frame containing a local - variable at ADDRESS. */ -#define _JMPBUF_UNWINDS(_jmpbuf, _address) \ - ((void *)(_address) > (void *)(((unsigned long *) _jmpbuf)[JB_SP])) #endif /* bits/setjmp.h */ diff --git a/libc/sysdeps/linux/hppa/bits/sigaction.h b/libc/sysdeps/linux/hppa/bits/sigaction.h index 33f2b237b..a221ac9c1 100644 --- a/libc/sysdeps/linux/hppa/bits/sigaction.h +++ b/libc/sysdeps/linux/hppa/bits/sigaction.h @@ -13,39 +13,29 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ #ifndef _SIGNAL_H # error "Never include <bits/sigaction.h> directly; use <signal.h> instead." #endif /* Structure describing the action to be taken when a signal arrives. */ -struct sigaction - { - /* Signal handler. */ +struct sigaction { #ifdef __USE_POSIX199309 - union - { - /* Used if SA_SIGINFO is not set. */ - __sighandler_t sa_handler; - /* Used if SA_SIGINFO is set. */ - void (*sa_sigaction) (int, siginfo_t *, void *); - } - __sigaction_handler; -# define sa_handler __sigaction_handler.sa_handler -# define sa_sigaction __sigaction_handler.sa_sigaction + union { + __sighandler_t sa_handler; + void (*sa_sigaction)(int, siginfo_t *, void *); + } __sigaction_handler; +# define sa_handler __sigaction_handler.sa_handler +# define sa_sigaction __sigaction_handler.sa_sigaction #else - __sighandler_t sa_handler; + __sighandler_t sa_handler; #endif - - /* Special flags. */ - unsigned long int sa_flags; - - /* Additional set of signals to be blocked. */ - __sigset_t sa_mask; - }; + unsigned long sa_flags; + sigset_t sa_mask; + /* HPPA has no sa_restorer field. */ +}; /* Bits in `sa_flags'. */ diff --git a/libc/sysdeps/linux/hppa/bits/signum.h b/libc/sysdeps/linux/hppa/bits/signum.h index bf46006c8..243eefdc8 100644 --- a/libc/sysdeps/linux/hppa/bits/signum.h +++ b/libc/sysdeps/linux/hppa/bits/signum.h @@ -13,23 +13,11 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ #ifdef _SIGNAL_H -/* Fake signal functions. */ -#define SIG_ERR ((__sighandler_t) -1) /* Error return. */ -#define SIG_DFL ((__sighandler_t) 0) /* Default action. */ -#define SIG_IGN ((__sighandler_t) 1) /* Ignore signal. */ - -#ifdef __USE_UNIX98 -# define SIG_HOLD ((__sighandler_t) 2) /* Add signal to hold mask. */ -#endif - - -/* Signals. */ #define SIGHUP 1 /* Hangup (POSIX). */ #define SIGINT 2 /* Interrupt (ANSI). */ #define SIGQUIT 3 /* Quit (POSIX). */ @@ -68,15 +56,6 @@ #define SIGXFSZ 34 /* File size limit exceeded (4.2 BSD). */ #define SIGSTKFLT 36 /* Stack fault. */ -#define _NSIG 65 /* Biggest signal number + 1 - (including real-time signals). */ - -#define SIGRTMIN (__libc_current_sigrtmin ()) -#define SIGRTMAX (__libc_current_sigrtmax ()) - -/* These are the hard limits of the kernel. These values should not be - used directly at user level. */ #define __SIGRTMIN 37 -#define __SIGRTMAX (_NSIG - 1) #endif /* <signal.h> included. */ diff --git a/libc/sysdeps/linux/hppa/bits/socket_type.h b/libc/sysdeps/linux/hppa/bits/socket_type.h new file mode 100644 index 000000000..c6df6c3e5 --- /dev/null +++ b/libc/sysdeps/linux/hppa/bits/socket_type.h @@ -0,0 +1,54 @@ +/* Define enum __socket_type for Linux/HP-PARISC. + Copyright (C) 2012 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ + +#ifndef _SYS_SOCKET_H +# error "Never include <bits/socket_type.h> directly; use <sys/socket.h> instead." +#endif + +/* Types of sockets. */ +enum __socket_type +{ + SOCK_STREAM = 1, /* Sequenced, reliable, connection-based + byte streams. */ +#define SOCK_STREAM SOCK_STREAM + SOCK_DGRAM = 2, /* Connectionless, unreliable datagrams + of fixed maximum length. */ +#define SOCK_DGRAM SOCK_DGRAM + SOCK_RAW = 3, /* Raw protocol interface. */ +#define SOCK_RAW SOCK_RAW + SOCK_RDM = 4, /* Reliably-delivered messages. */ +#define SOCK_RDM SOCK_RDM + SOCK_SEQPACKET = 5, /* Sequenced, reliable, connection-based, + datagrams of fixed maximum length. */ +#define SOCK_SEQPACKET SOCK_SEQPACKET + SOCK_DCCP = 6, /* Datagram Congestion Control Protocol. */ +#define SOCK_DCCP SOCK_DCCP + SOCK_PACKET = 10, /* Linux specific way of getting packets + at the dev level. For writing rarp and + other similar things on the user level. */ +#define SOCK_PACKET SOCK_PACKET + + /* Flags to be ORed into the type parameter of socket and socketpair. */ + + SOCK_CLOEXEC = 010000000, /* Atomically set close-on-exec flag for the + new descriptor(s). */ +#define SOCK_CLOEXEC SOCK_CLOEXEC + SOCK_NONBLOCK = 0x40000000 /* Atomically mark descriptor(s) as + non-blocking. */ +#define SOCK_NONBLOCK SOCK_NONBLOCK +}; diff --git a/libc/sysdeps/linux/hppa/bits/stackinfo.h b/libc/sysdeps/linux/hppa/bits/stackinfo.h index 318de7143..8574e7d8d 100644 --- a/libc/sysdeps/linux/hppa/bits/stackinfo.h +++ b/libc/sysdeps/linux/hppa/bits/stackinfo.h @@ -12,9 +12,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ /* This file contains a bit of information about the stack allocation of the processor. */ diff --git a/libc/sysdeps/linux/hppa/bits/syscalls.h b/libc/sysdeps/linux/hppa/bits/syscalls.h index 9035cd5aa..fddad622d 100644 --- a/libc/sysdeps/linux/hppa/bits/syscalls.h +++ b/libc/sysdeps/linux/hppa/bits/syscalls.h @@ -6,10 +6,6 @@ #ifndef __ASSEMBLER__ -#include <errno.h> - -#define SYS_ify(syscall_name) __NR_##syscall_name - /* Assume all syscalls are done from PIC code just to be * safe. The worst case scenario is that you lose a register * and save/restore r19 across the syscall. */ @@ -42,33 +38,26 @@ across the syscall. */ #define K_CALL_CLOB_REGS "%r1", "%r2", K_USING_GR4 \ - "%r20", "%r29", "%r31" - -#undef K_INLINE_SYSCALL -#define K_INLINE_SYSCALL(name, nr, args...) ({ \ - long __sys_res; \ - { \ - register unsigned long __res __asm__("r28"); \ - K_LOAD_ARGS_##nr(args) \ - /* FIXME: HACK stw/ldw r19 around syscall */ \ - __asm__ __volatile__( \ - K_STW_ASM_PIC \ - " ble 0x100(%%sr2, %%r0)\n" \ - " ldi %1, %%r20\n" \ - K_LDW_ASM_PIC \ - : "=r" (__res) \ - : "i" (SYS_ify(name)) K_ASM_ARGS_##nr \ - : "memory", K_CALL_CLOB_REGS K_CLOB_ARGS_##nr \ - ); \ - __sys_res = (long)__res; \ - } \ - if ( (unsigned long)__sys_res >= (unsigned long)-4095 ){ \ - errno = -__sys_res; \ - __sys_res = -1; \ - } \ - __sys_res; \ -}) - + "%r20", "%r29", "%r31" + +#define INTERNAL_SYSCALL_NCS(name, err, nr, args...) \ +(__extension__ \ + ({ \ + register unsigned long __res __asm__("r28"); \ + K_LOAD_ARGS_##nr(args) \ + /* FIXME: HACK stw/ldw r19 around syscall */ \ + __asm__ __volatile__( \ + K_STW_ASM_PIC \ + " ble 0x100(%%sr2, %%r0)\n" \ + " ldi %1, %%r20\n" \ + K_LDW_ASM_PIC \ + : "=r" (__res) \ + : "i" (name) K_ASM_ARGS_##nr \ + : "memory", K_CALL_CLOB_REGS K_CLOB_ARGS_##nr \ + ); \ + __res; \ + }) \ +) #define K_LOAD_ARGS_0() #define K_LOAD_ARGS_1(r26) \ register unsigned long __r26 __asm__("r26") = (unsigned long)(r26); \ @@ -107,49 +96,5 @@ #define K_CLOB_ARGS_1 K_CLOB_ARGS_2, "%r25" #define K_CLOB_ARGS_0 K_CLOB_ARGS_1, "%r26" -#define _syscall0(type,name) \ -type name(void) \ -{ \ - return (type) K_INLINE_SYSCALL(name, 0); \ -} - -#define _syscall1(type,name,type1,arg1) \ -type name(type1 arg1) \ -{ \ - return (type) K_INLINE_SYSCALL(name, 1, arg1); \ -} - -#define _syscall2(type,name,type1,arg1,type2,arg2) \ -type name(type1 arg1, type2 arg2) \ -{ \ - return (type) K_INLINE_SYSCALL(name, 2, arg1, arg2); \ -} - -#define _syscall3(type,name,type1,arg1,type2,arg2,type3,arg3) \ -type name(type1 arg1, type2 arg2, type3 arg3) \ -{ \ - return (type) K_INLINE_SYSCALL(name, 3, arg1, arg2, arg3); \ -} - -#define _syscall4(type,name,type1,arg1,type2,arg2,type3,arg3,type4,arg4) \ -type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4) \ -{ \ - return (type) K_INLINE_SYSCALL(name, 4, arg1, arg2, arg3, arg4); \ -} - -/* select takes 5 arguments */ -#define _syscall5(type,name,type1,arg1,type2,arg2,type3,arg3,type4,arg4,type5,arg5) \ -type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, type5 arg5) \ -{ \ - return (type) K_INLINE_SYSCALL(name, 5, arg1, arg2, arg3, arg4, arg5); \ -} - -/* mmap & mmap2 take 6 arguments */ -#define _syscall6(type,name,type1,arg1,type2,arg2,type3,arg3,type4,arg4,type5,arg5,type6,arg6) \ -type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, type5 arg5, type6 arg6) \ -{ \ - return (type) K_INLINE_SYSCALL(name, 6, arg1, arg2, arg3, arg4, arg5, arg6); \ -} - #endif /* __ASSEMBLER__ */ #endif /* _BITS_SYSCALLS_H */ diff --git a/libc/sysdeps/linux/hppa/bits/uClibc_arch_features.h b/libc/sysdeps/linux/hppa/bits/uClibc_arch_features.h index 2c04f1b77..19fa05109 100644 --- a/libc/sysdeps/linux/hppa/bits/uClibc_arch_features.h +++ b/libc/sysdeps/linux/hppa/bits/uClibc_arch_features.h @@ -9,28 +9,28 @@ #define __UCLIBC_ABORT_INSTRUCTION__ "iitlbp %r0,(%sr0,%r0)" /* can your target use syscall6() for mmap ? */ -#undef __UCLIBC_MMAP_HAS_6_ARGS__ +#define __UCLIBC_MMAP_HAS_6_ARGS__ -/* does your target use syscall4() for truncate64 ? (32bit arches only) */ -#undef __UCLIBC_TRUNCATE64_HAS_4_ARGS__ +/* does your target align 64bit values in register pairs ? (32bit arches only) */ +#undef __UCLIBC_SYSCALL_ALIGN_64BIT__ /* does your target have a broken create_module() ? */ #undef __UCLIBC_BROKEN_CREATE_MODULE__ +/* does your target have to worry about older [gs]etrlimit() ? */ +#undef __UCLIBC_HANDLE_OLDER_RLIMIT__ + /* does your target have an asm .set ? */ #define __UCLIBC_HAVE_ASM_SET_DIRECTIVE__ -/* define if target doesn't like .global */ -#undef __UCLIBC_ASM_GLOBAL_DIRECTIVE__ - /* define if target supports .weak */ #define __UCLIBC_HAVE_ASM_WEAK_DIRECTIVE__ /* define if target supports .weakext */ #undef __UCLIBC_HAVE_ASM_WEAKEXT_DIRECTIVE__ -/* needed probably only for ppc64 */ -#undef __UCLIBC_HAVE_ASM_GLOBAL_DOT_NAME__ +/* define if target supports CFI pseudo ops */ +#undef __UCLIBC_HAVE_ASM_CFI_DIRECTIVES__ /* define if target supports IEEE signed zero floats */ #define __UCLIBC_HAVE_SIGNED_ZERO__ diff --git a/libc/sysdeps/linux/hppa/brk.c b/libc/sysdeps/linux/hppa/brk.c index dab2d57ca..0a8590d02 100644 --- a/libc/sysdeps/linux/hppa/brk.c +++ b/libc/sysdeps/linux/hppa/brk.c @@ -13,9 +13,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ #include <errno.h> #include <sys/syscall.h> @@ -24,13 +23,12 @@ /* This must be initialized data because commons can't have aliases. */ void *__curbrk attribute_hidden = 0; -libc_hidden_proto(brk) int brk (void *addr) { void *newbrk; - __curbrk = newbrk = (void *) K_INLINE_SYSCALL (brk, 1, addr); + __curbrk = newbrk = (void *) INLINE_SYSCALL (brk, 1, addr); if (newbrk < addr) { diff --git a/libc/sysdeps/linux/hppa/bsd-_setjmp.S b/libc/sysdeps/linux/hppa/bsd-_setjmp.S index 30e53f562..5ecaf4cd7 100644 --- a/libc/sysdeps/linux/hppa/bsd-_setjmp.S +++ b/libc/sysdeps/linux/hppa/bsd-_setjmp.S @@ -13,9 +13,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ /* This just does a tail-call to `__sigsetjmp (ARG, 1)'. We cannot do it in C because it must be a tail-call, so frame-unwinding diff --git a/libc/sysdeps/linux/hppa/bsd-setjmp.S b/libc/sysdeps/linux/hppa/bsd-setjmp.S index 04ddba465..24053f3ab 100644 --- a/libc/sysdeps/linux/hppa/bsd-setjmp.S +++ b/libc/sysdeps/linux/hppa/bsd-setjmp.S @@ -13,9 +13,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ /* This just does a tail-call to `__sigsetjmp (ARG, 1)'. We cannot do it in C because it must be a tail-call, so frame-unwinding diff --git a/libc/sysdeps/linux/hppa/clone.S b/libc/sysdeps/linux/hppa/clone.S index b8e354cda..f6c153b01 100644 --- a/libc/sysdeps/linux/hppa/clone.S +++ b/libc/sysdeps/linux/hppa/clone.S @@ -14,9 +14,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ /* clone() is even more special than fork() as it mucks with stacks and invokes a function in the right context after its all over. */ diff --git a/libc/sysdeps/linux/hppa/crt1.S b/libc/sysdeps/linux/hppa/crt1.S index 8b42dacde..87080b137 100644 --- a/libc/sysdeps/linux/hppa/crt1.S +++ b/libc/sysdeps/linux/hppa/crt1.S @@ -30,9 +30,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ .import main, code .import $global$, data diff --git a/libc/sysdeps/linux/hppa/jmpbuf-offsets.h b/libc/sysdeps/linux/hppa/jmpbuf-offsets.h new file mode 100644 index 000000000..c579e83bb --- /dev/null +++ b/libc/sysdeps/linux/hppa/jmpbuf-offsets.h @@ -0,0 +1,19 @@ +/* Private macros for accessing __jmp_buf contents. HPPA version. + Copyright (C) 2006 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ + +#define JB_SP (76/4) diff --git a/libc/sysdeps/linux/hppa/jmpbuf-unwind.h b/libc/sysdeps/linux/hppa/jmpbuf-unwind.h new file mode 100644 index 000000000..0590754f8 --- /dev/null +++ b/libc/sysdeps/linux/hppa/jmpbuf-unwind.h @@ -0,0 +1,12 @@ +/* + * Copyright (C) 2000-2006 Erik Andersen <andersen@uclibc.org> + * + * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. + */ +#include <setjmp.h> +#include <jmpbuf-offsets.h> + +/* Test if longjmp to JMPBUF would unwind the frame containing a local + variable at ADDRESS. */ +#define _JMPBUF_UNWINDS(_jmpbuf, _address) \ + ((void *)(_address) > (void *)(((unsigned long *) _jmpbuf)[JB_SP])) diff --git a/libc/sysdeps/linux/hppa/lshift.s b/libc/sysdeps/linux/hppa/lshift.s index 151b283e5..d86bb6a30 100644 --- a/libc/sysdeps/linux/hppa/lshift.s +++ b/libc/sysdeps/linux/hppa/lshift.s @@ -15,9 +15,8 @@ ;! License for more details. ;! You should have received a copy of the GNU Lesser General Public License -;! along with the GNU MP Library; see the file COPYING.LIB. If not, write to -;! the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, -;! MA 02111-1307, USA. +;! along with the GNU MP Library; see the file COPYING.LIB. If not, see +;! <http://www.gnu.org/licenses/>. ;! INPUT PARAMETERS diff --git a/libc/sysdeps/linux/hppa/mmap.c b/libc/sysdeps/linux/hppa/mmap.c deleted file mode 100644 index baaee6847..000000000 --- a/libc/sysdeps/linux/hppa/mmap.c +++ /dev/null @@ -1,20 +0,0 @@ -/* vi: set sw=4 ts=4: */ -/* - * mmap() for uClibc/x86_64 - * - * Copyright (C) 2000-2006 Erik Andersen <andersen@uclibc.org> - * Copyright (C) 2005 by Mike Frysinger <vapier@gentoo.org> - * - * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. - */ - -#include <errno.h> -#include <unistd.h> -#include <sys/mman.h> -#include <sys/syscall.h> - -libc_hidden_proto(mmap) - -_syscall6(void *, mmap, void *, start, size_t, length, int, prot, - int, flags, int, fd, off_t, offset); -libc_hidden_def(mmap) diff --git a/libc/sysdeps/linux/hppa/rshift.s b/libc/sysdeps/linux/hppa/rshift.s index dff189dc4..5517825c1 100644 --- a/libc/sysdeps/linux/hppa/rshift.s +++ b/libc/sysdeps/linux/hppa/rshift.s @@ -15,9 +15,8 @@ ;! License for more details. ;! You should have received a copy of the GNU Lesser General Public License -;! along with the GNU MP Library; see the file COPYING.LIB. If not, write to -;! the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, -;! MA 02111-1307, USA. +;! along with the GNU MP Library; see the file COPYING.LIB. If not, see +;! <http://www.gnu.org/licenses/>. ;! INPUT PARAMETERS diff --git a/libc/sysdeps/linux/hppa/setjmp.S b/libc/sysdeps/linux/hppa/setjmp.S index fdc4c424b..fa5bb8eca 100644 --- a/libc/sysdeps/linux/hppa/setjmp.S +++ b/libc/sysdeps/linux/hppa/setjmp.S @@ -13,9 +13,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ .text .align 4 diff --git a/libc/sysdeps/linux/hppa/sub_n.s b/libc/sysdeps/linux/hppa/sub_n.s index 7764961a2..768b670a0 100644 --- a/libc/sysdeps/linux/hppa/sub_n.s +++ b/libc/sysdeps/linux/hppa/sub_n.s @@ -16,9 +16,8 @@ ;! License for more details. ;! You should have received a copy of the GNU Lesser General Public License -;! along with the GNU MP Library; see the file COPYING.LIB. If not, write to -;! the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, -;! MA 02111-1307, USA. +;! along with the GNU MP Library; see the file COPYING.LIB. If not, see +;! <http://www.gnu.org/licenses/>. ;! INPUT PARAMETERS diff --git a/libc/sysdeps/linux/hppa/sys/procfs.h b/libc/sysdeps/linux/hppa/sys/procfs.h index 2e6d10956..8d12dfb65 100644 --- a/libc/sysdeps/linux/hppa/sys/procfs.h +++ b/libc/sysdeps/linux/hppa/sys/procfs.h @@ -1,4 +1,4 @@ -/* Copyright (C) 1996, 1997, 1999, 2000 Free Software Foundation, Inc. +/* Copyright (C) 1996-2015 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -12,9 +12,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library. If not, see + <http://www.gnu.org/licenses/>. */ #ifndef _SYS_PROCFS_H #define _SYS_PROCFS_H 1 @@ -29,15 +28,21 @@ GDB unless you know what you are doing. */ #include <features.h> -#include <signal.h> #include <sys/time.h> #include <sys/types.h> -#include <sys/ucontext.h> #include <sys/user.h> -#include <asm/elf.h> __BEGIN_DECLS +typedef unsigned long elf_greg_t; +#define ELF_NGREG 80 /* We only need 64 at present, but leave space + for expansion. */ +typedef elf_greg_t elf_gregset_t[ELF_NGREG]; + +#define ELF_NFPREG 32 +typedef double elf_fpreg_t; +typedef elf_fpreg_t elf_fpregset_t[ELF_NFPREG]; + struct elf_siginfo { int si_signo; /* Signal number. */ diff --git a/libc/sysdeps/linux/hppa/sys/ucontext.h b/libc/sysdeps/linux/hppa/sys/ucontext.h index 143114384..4c293ef6c 100644 --- a/libc/sysdeps/linux/hppa/sys/ucontext.h +++ b/libc/sysdeps/linux/hppa/sys/ucontext.h @@ -12,9 +12,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ /* Don't rely on this, the interface is currently messed up and may need to be broken to be fixed. */ diff --git a/libc/sysdeps/linux/hppa/sys/user.h b/libc/sysdeps/linux/hppa/sys/user.h new file mode 100644 index 000000000..c871f1a03 --- /dev/null +++ b/libc/sysdeps/linux/hppa/sys/user.h @@ -0,0 +1 @@ +/* This file is not needed, but in practice gdb might try to include it. */ diff --git a/libc/sysdeps/linux/hppa/syscall.c b/libc/sysdeps/linux/hppa/syscall.c index cd11e084e..e22b290f1 100644 --- a/libc/sysdeps/linux/hppa/syscall.c +++ b/libc/sysdeps/linux/hppa/syscall.c @@ -12,9 +12,8 @@ Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ #include <stdarg.h> #include <errno.h> diff --git a/libc/sysdeps/linux/hppa/udiv_qrnnd.s b/libc/sysdeps/linux/hppa/udiv_qrnnd.s index 8e9c07a20..5304c6a86 100644 --- a/libc/sysdeps/linux/hppa/udiv_qrnnd.s +++ b/libc/sysdeps/linux/hppa/udiv_qrnnd.s @@ -16,9 +16,8 @@ ;! License for more details. ;! You should have received a copy of the GNU Lesser General Public License -;! along with the GNU MP Library; see the file COPYING.LIB. If not, write to -;! the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, -;! MA 02111-1307, USA. +;! along with the GNU MP Library; see the file COPYING.LIB. If not, see +;! <http://www.gnu.org/licenses/>. ;! INPUT PARAMETERS |
