aboutsummaryrefslogtreecommitdiff
path: root/newlib/libc/sys
AgeCommit message (Collapse)AuthorFilesLines
2015-07-29Add <sys/lock.h>Sebastian Huber1-0/+235
Provide self-contained synchronization objects for RTEMS. The API was designed to be able to use it for the Newlib internal locks, the C11 threads support, the GCC thread model support and the libgomp operating system configuration in combination with <pthread.h>. References: https://lists.rtems.org/pipermail/devel/2015-July/011989.html https://lists.rtems.org/pipermail/devel/2015-July/012000.html Tickets: https://devel.rtems.org/ticket/1247 https://devel.rtems.org/ticket/2274. v2: Fix typo in _Condition_Wait_recursive_timed() declaration. newlib/ChangeLog 2015-07-28 Sebastian Huber <sebastian.huber@embedded-brains.de> * libc/sys/rtems/include/sys/lock.h: New.
2015-04-23Add <sys/_stdint.h> for FreeBSD compatibilitySebastian Huber1-1/+0
* libc/include/sys/_stdint.h: New file. * libc/include/stdint.h (int8_t): Move to <sys/_stdint.h>. (uint8_t): Likewise. (int16_t): Likewise. (uint16_t): Likewise. (int32_t): Likewise. (uint32_t): Likewise. (int64_t): Likewise. (uint64_t): Likewise. (intptr_t): Likewise. (uintptr_t): Likewise. * libc/include/sys/types.h: Include <sys/_stdint.h>. * libc/sys/rtems/machine/_types.h: Remove <stdint.h> include. * libc/sys/time.h>: Replace __uint32_t with uint32_t and __uint64_t with uint64_t. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2015-03-12Import libc/sys/rtems/include/semaphore.h from FreeBSD.Sebastian Huber1-0/+56
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2015-01-22* libc/sys/sparc64/sys/time.h: #include <sys/types.h> for time_t.Yaakov Selkowitz1-0/+2
2015-01-22 * libc/sys/or1k/mlock.c: Fix dependency on libgloss.Corinna Vinschen1-2/+4
2015-01-20Fix typo in entry headerCorinna Vinschen2-2/+6
2015-01-14 * configure.host: Add extra system for OpenRISC baremetalCorinna Vinschen8-0/+6731
* libc/include/sys/config.h: Dynamic reentrancy for or1k sys targets * libc/sys/or1k/: New system for or1k baremetal * libc/sys/or1k/Makefile.am: New file * libc/sys/or1k/Makefile.in: New file * libc/sys/or1k/aclocal.m4: New file * libc/sys/or1k/configure.in: New file * libc/sys/or1k/configure: New file * libc/sys/or1k/getreent.S: New file * libc/sys/or1k/mlock.S: New file * libc/sys/or1k/or1k-asm.S: New file
2014-12-182014-12-18 Jeff Johnston <jjohnstn@redhat.com>Jeff Johnston33-320/+324
* NEWS: Update with 2.2.0 info. * README: Ditto. * acinclude.m4: Change version number to 2.2.0. * libc/libc.texinfo: Ditto. * libm/libm.texinfo: Ditto. * configure: Regenerated. * Makefile.in: Regenerated. * doc/configure: Ditto. * libc/*/configure: Ditto. * libm/*/configure: Ditto. * libc/sys/linux/shared.ld: Add VERS_2.2
2014-11-20 * libc/sys/rtems/sys/syslimits.h (NGROUPS_MAX): Adjust value soCorinna Vinschen1-1/+1
that NGROUPS is even.
2014-08-01headers: properly decorate attributesEric Blake12-48/+48
Found by: find -name '*.h' |xargs grep -i 'attribute.*(([a-z]' For an example of the type of bugs this causes, try compiling this valid C11 program (it's valid because 'noreturn' is reserved for use in the user namespace unless you include <stdnoreturn.h>): $ cat foo.c #define noreturn __attribute__((noreturn)) #include <stdlib.h> $ gcc -c -o foo.o -Wall foo.c In file included from /usr/include/stdlib.h:11:0, from foo.c:2: foo.c:1:18: error: expected ')' before '__attribute__' #define noreturn __attribute__((noreturn)) ^ /usr/include/stdlib.h:66:28: error: expected ',' or ';' before ')' token _VOID _EXFUN(abort,(_VOID) _ATTRIBUTE ((noreturn))); ^ * libc/machine/spu/spu_timer_internal.h: Decorate attribute names with __, for namespace safety. * libc/machine/xscale/machine/profile.h: Likewise. * libc/include/stdlib.h: Likewise. * libc/include/_ansi.h: Likewise. * libc/include/sys/unistd.h: Likewise. * libc/sys/linux/linuxthreads/libc-symbols.h: Likewise. * libc/sys/linux/linuxthreads/internals.h: Likewise. * libc/sys/linux/machine/i386/weakalias.h: Likewise. * libc/sys/linux/machine/i386/dl-procinfo.h: Likewise. * libc/sys/linux/machine/i386/dl-machine.h: Likewise. * libc/sys/linux/libc-symbols.h: Likewise. * libc/sys/linux/iconv/gconv_charset.h: Likewise. * libc/sys/linux/include/resolv.h: Likewise. * libc/sys/linux/sys/unistd.h: Likewise. * libc/sys/linux/dl/atomicity.h: Likewise. * libc/sys/linux/dl/dynamic-link.h: Likewise. * libc/sys/linux/dl/ldsodefs.h: Likewise.
2014-04-14 * libc/sys/rtems/sys/cpuset.h (CPU_SET_S): Add const qualifier.Corinna Vinschen1-2/+2
(CPU_SET): Likewise.
2014-04-042014-04-04 Ashish Kapania <akapania@ti.com>Jeff Johnston9-2/+6435
* configure.host (sys_dir, newlib_cflags): Set sys_dir to tirtos and use -D__DYNAMIC_REENT__ and -DMALLOC_PROVIDED compiler options for TIRTOS target. * libc/stdio/local.h (_STDIO_CLOSE_PER_REENT_STD_STREAMS): Change #ifdef to not define this macro when __tirtos__ is defined. * libc/sys/tirtos : Add support for TIRTOS. * libc/sys/tirtos/Makefile.am, libc/sys/tirtos/lock.c: New files. * libc/sys/tirtos/configure.in, libc/sys/tirtos/include/sys/lock.h: Ditto.
2014-02-112014-02-11 Joey Ye <joey.ye@arm.com>Jeff Johnston1-3/+3
* libc/sys/arm/syscalls.c (_sbrk): Define as weak symbols. (_read, _write): Ditto.
2013-12-232013-12-23 Jeff Johnston <jjohnstn@redhat.com>Jeff Johnston32-345/+391
* NEWS: Update with 2.1.0 info. * README: Ditto. * acinclude.m4: Change version number to 2.1.0. * aclocal.m4: Regenerated. * configure: Ditto. * Makefile.in: Regenerated. * doc/aclocal.m4: Ditto. * doc/configure: Ditto. * libc/*/aclocal.m4: Ditto. * libc/*/configure: Ditto. * libc/libc.texinfo: Ditto. * libm/*/aclocal.m4: Ditto. * libm/*/configure: Ditto. * libm/libm.texinfo: Ditto. * libc/sys/linux/shared.ld: Add VERS_2.1
2013-12-10 * libc/sys/rtems/include/limits.h: Update page size to matchCorinna Vinschen1-1/+1
libc/sys/rtems/machine/param.h.
2013-12-03 * libc/sys/rtems/sys/cpuset.h: Use __inline instead of inline.Corinna Vinschen1-31/+30
2013-12-03 * libc/include/machine/_default_types.h: Move extern "C" afterCorinna Vinschen2-2/+3
header includes. Include <sys/features.h> for __GNUC_PREREQ__(). (__u?int.*_t): Define via GCC provided __U?INT.*_TYPE__ if available. (__intptr_t): Define. (__uintptr_t): Likewise. * libc/include/stdint.h: Include <machine/_default_types.h> instead of <_ansi.h>. (u?int.*_t): Define via __u?int.*_t provided by <machine/_default_types.h>. (u?int_fast.*_t): Define via GCC provided __U?INT_FAST.*_TYPE__ if available. (U?INT.*(MIN|MAX)): Define via GCC provided __U?INT.*(MIN|MAX)__ if available. (U?INT.*_C): Define via GCC provided __U?INT.*_C if available. * libc/include/sys/cdefs.h: Use <machine/_default_types.h> instead of <stdint.h>. * libc/sys/rtems/sys/cpuset.h: Likewise. * libc/sys/rtems/machine/_types.h: Include <stdint.h> for FreeBSD compatibility.
2013-11-272013-11-27 Sebastian Huber <sebastian.huber@embedded-brains.de>Joel Sherrill5-68/+262
* libc/sys/rtems/cpusetalloc.c: New file. * libc/sys/rtems/cpusetfree.c: Likewise. * libc/sys/rtems/Makefile.am (lib_a_SOURCES): Add new files. * libc/sys/rtems/Makefile.in: Regenerate. * libc/sys/rtems/sys/cpuset.h: Delete #if 0 block. Include <stddef.h> for size_t. (_NCPUBITS): Avoid NBBY and assume 8 bits per char. (__cpuset_mask): Use int instead of size_t parameter for Linux compatibility. (__cpuset_index): Likewise. (__cpuset_alloc): Declare. (__cpuset_free): Likewise. (CPU_ALLOC_SIZE): Likewise. (CPU_ALLOC): Define. (CPU_FREE): Likewise. (CPU_ZERO_S): Likewise. (CPU_FILL_S): Likewise. (CPU_SET_S): Likewise. (CPU_CLR_S): Likewise. (CPU_ISSET_S): Likewise. (CPU_COUNT_S): Likewise. (CPU_AND_S): Likewise. (CPU_OR_S): Likewise. (CPU_XOR_S): Likewise. (CPU_NAND_S): Likewise. (CPU_EQUAL_S): Likewise. (CPU_ZERO): Use CPU_ZERO_S(). (CPU_FILL): Use CPU_FILL_S(). (CPU_SET): Use CPU_SET_S(). (CPU_CLR): Use CPU_CLR_S(). (CPU_ISSET): Use CPU_ISSET_S(). (CPU_COUNT): Use CPU_COUNT_S(). (CPU_AND): Use CPU_AND_S(). (CPU_OR): Use CPU_OR_S(). (CPU_XOR): Use CPU_XOR_S(). (CPU_NAND): Use CPU_NAND_S(). (CPU_EQUAL): Use CPU_EQUAL_S(). (CPU_CMP): Delete superfluous const qualifier. (CPU_EMPTY): Likewise.
2013-11-252013-11-25 Sahil Patnayakuni <sahil.patnayakuni@gmail.com>Joel Sherrill2-4/+4
* libc/include/time.h (time): Add restrict keyword. * libc/include/wchar.h (wcsftime): Add restrict keyword. * libc/time/asctime_r.c (asctime_r): Same. * libc/time/gmtime_r.c (gmtime_r): Same. * libc/time/lcltime_r.c (lcltime_r): Same. * libc/time/strftime.c (strftime): Same. * libc/time/strptime.c (strptime): Same. * libc/sys/linux/linuxthreads/timer_create.c (timer_create): Same. * libc/sys/linux/linuxthreads/timer_settime.c (timer_settime): Same.
2013-11-232013-11-22 Bryan Dunsmore <dunsmoreb@gmail.com>Joel Sherrill1-1/+1
* libc/include/sys/time.h (gettimeofday): Add restrict keyword. (setitimer): Likewise. * libc/sys/rdos/gettod.c (gettimeofday): Likewise. * libc/sys/rtems/crt0.c (gettimeofday): Likewise.
2013-11-222013-11-22 Chirayu Desai <chirayudesai1@gmail.com>Joel Sherrill1-1/+1
* libc/include/sys/unistd.h (readlink): Add restrict keyword. (readlinkat): Ditto. (swab): Ditto. * libc/sys/rdos/readlink.c (readlink): Ditto. * libc/string/swab.c (swab): Ditto.
2013-11-222013-11-21 Daniel Ramirez <javamonn@gmail.com>Joel Sherrill1-1/+1
* libc/sys/linux/statvfs.c (statvfs): Added restrict keyword.
2013-11-212013-11-21 Joel Sherrill <joel.sherrill@oarcorp.com>Joel Sherrill22-795/+795
* libc/sys/rdos/chown.c, libc/sys/rdos/close.c, libc/sys/rdos/execve.c, libc/sys/rdos/fork.c, libc/sys/rdos/fstat.c, libc/sys/rdos/getpid.c, libc/sys/rdos/gettod.c, libc/sys/rdos/isatty.c, libc/sys/rdos/kill.c, libc/sys/rdos/link.c, libc/sys/rdos/lseek.c, libc/sys/rdos/open.c, libc/sys/rdos/rdos.h, libc/sys/rdos/read.c, libc/sys/rdos/readlink.c, libc/sys/rdos/sbrk.c, libc/sys/rdos/stat.c, libc/sys/rdos/symlink.c, libc/sys/rdos/times.c, libc/sys/rdos/unlink.c, libc/sys/rdos/wait.c, libc/sys/rdos/write.c: Convert from DOS to UNIX CRLF.
2013-11-212013-11-21 Joel Sherrill <joel.sherrill@oarcorp.com>Joel Sherrill6-0/+12
* libc/posix/readdir_r.c: Add restrict keyword. * libc/machine/spu/sys/dirent.h, libc/sys/decstation/sys/dirent.h, libc/sys/linux/sys/dirent.h, libc/sys/rtems/sys/dirent.h, libc/sys/sparc64/sys/dirent.h, libc/sys/sun4/sys/dirent.h, libc/sys/sysvi386/sys/dirent.h: Add readdir_r() prototype.
2013-11-212013-11-21 Joel Sherrill <joel.sherrill@oarcorp.com>Joel Sherrill1-1/+1
* libc/sys/rdos/stat.c: Remove stray +.
2013-11-212013-11-21 Daniel Ramirez <javamonn@gmail.com>Joel Sherrill4-7/+7
* libc/include/sys/stat.h, libc/sys/linux/sys/stat.h, libc/sys/m88kbug/syscalls.c, libc/sys/rdos/stat.c, libc/sys/sparc64/sys/stat.h: Add restrict keyword.
2013-11-202013-11-20 Daniel Ramirez <javamonn@gmail.com>Joel Sherrill1-2/+4
* libc/iconv/lib/iconv.c, libc/include/iconv.h, libc/sys/linux/iconv/iconv.c: Add restrict keyword.
2013-11-193013-11-19 Jennifer Averett <jennifer.averett@oarcorp.com>Joel Sherrill1-0/+207
* libc/sys/rtems/sys/cpuset.h: New file.
2013-11-192013-11-18 Joel Sherrill <joel.sherrill@oarcorp.com>Joel Sherrill1-1/+1
* libc/include/stdlib.h: Add prototype of realpath(). * libc/sys/linux/realpath.c: Add restrict keyword.
2013-10-18 * libc/include/sys/unistd.h (MAXPATHLEN): Delete.Corinna Vinschen1-2/+0
* libc/include/sys/param.h (MAXPATHLEN): Define. * libc/sys/rtems/sys/param.h (MAXPATHLEN): Likewise. * libc/unix/getcwd.c: Include <sys/param.h> for MAXPATHLEN.
2013-10-152013-10-10 Sebastian Huber <sebastian.huber@embedded-brains.de>Joel Sherrill1-23/+33
* libc/libc/sys/rtems/sys/param.h: Update some parameters to the latest FreeBSD values.
2013-10-152013-10-10 Sebastian Huber <sebastian.huber@embedded-brains.de>Joel Sherrill1-0/+3
* libc/sys/rtems/machine/_types.h (_HAVE_SYSTYPES): Define.
2013-10-152013-10-10 Sebastian Huber <sebastian.huber@embedded-brains.de>Joel Sherrill2-0/+4
* libc/sys/rtems/machine/_types.h (__dev_t): Define. (__dev_t_defined) Likewise. * libc/include/sys/_types.h (__dev_t): Delete RTEMS specific definition.
2013-10-152013-10-10 Sebastian Huber <sebastian.huber@embedded-brains.de>Joel Sherrill1-26/+0
* libc/sys/rtems/machine/_types.h (_ssize_t): Delete. (__ssize_t_defined) Likewise.
2013-08-12 * libc/sys/arm/crt0.S: Remove 'start'.Corinna Vinschen1-1/+0
2013-07-23 * libc/sys/linux/include/netdb.h, libc/sys/linux/net/getaddrinfo.c,Corinna Vinschen3-9/+12
libc/sys/linux/net/getnameinfo.c: Add restrict keyword to getnameinfo() and getaddrinfo() to increase standards compliance and match glibc. * libc/include/string.h, libc/string/memccpy.c, libc/string/memcpy.c, libc/string/stpcpy.c, libc/string/stpncpy.c, libc/string/strcat.c, libc/string/strncat.c, libc/string/strncpy.c, libc/string/strtok.c, libc/string/strtok_r.c, libc/string/strxfrm.c libc/machine/microblaze/strcpy.c, libc/machine/xscale/memcpy.c, libc/machine/cris/memcpy.c: Add __restrict to prototype to increase standards compliance.
2013-07-19 * libc/sys/arm/syscalls.c (do_AngelSWI): Delete.Corinna Vinschen3-37/+25
* libc/sys/arm/libcfuncs.c (do_AngelSWI): Delete. * libc/sys/arm/swi.h: Copy over from libgloss.
2013-04-16 * libc/sys/rtems/sys/queue.h: Delete file.Corinna Vinschen1-530/+0
* libc/include/sys/cdefs.h (__containerof): New define. (__DEQUALIFY): Likewise. * libc/include/sys/queue.h (TRACEBUF_INITIALIZER): Likewise. (TRACEBUF): Likewise. (LIST_FOREACH_SAFE): Likewise. (LIST_PREV): Likewise. (LIST_SWAP): Likewise. (QMD_LIST_CHECK_HEAD): Likewise. (QMD_LIST_CHECK_NEXT): Likewise. (QMD_LIST_CHECK_PREV): Likewise. (QMD_SAVELINK): Likewise. (QMD_TAILQ_CHECK_HEAD): Likewise. (QMD_TAILQ_CHECK_NEXT): Likewise. (QMD_TAILQ_CHECK_PREV): Likewise. (QMD_TAILQ_CHECK_TAIL): Likewise. (QMD_TRACE_ELEM): Likewise. (QMD_TRACE_HEAD): Likewise. (SLIST_FOREACH_PREVPTR): Likewise. (SLIST_FOREACH_SAFE): Likewise. (SLIST_REMOVE_AFTER): Likewise. (SLIST_SWAP): Likewise. (STAILQ_FOREACH_SAFE): Likewise. (STAILQ_REMOVE_AFTER): Likewise. (STAILQ_SWAP): Likewise. (TAILQ_FOREACH_REVERSE_SAFE): Likewise. (TAILQ_FOREACH_SAFE): Likewise. (TAILQ_SWAP): Likewise. (TRASHIT): Likewise. (SLIST_REMOVE): Use SLIST_REMOVE_AFTER(). (STAILQ_LAST): Use __containerof(). (STAILQ_REMOVE): Use STAILQ_REMOVE_AFTER().
2013-02-01 * crt0.S: Add recognition of the e3v5 architecture variant.Nick Clifton1-2/+2
2013-01-15 * libc/sys/sysnecv850/crt0.S (_start): Enable FPU for theNick Clifton1-0/+12
V850e2v3. * v850/crt0.S (_start): Enable FPU for the V850e2v3.
2012-12-202012-12-20 Jeff Johnston <jjohnstn@redhat.com>Jeff Johnston100-1694/+3488
* NEWS: Update with 2.0.0 info. * README: Ditto. * acinclude.m4: Change version number to 2.0.0. * aclocal.m4: Regenerated. * configure: Ditto. * Makefile.in: Regenerated. * doc/aclocal.m4: Ditto. * doc/configure: Ditto. * libc/*/aclocal.m4: Ditto. * libc/*/configure: Ditto. * libc/libc.texinfo: Ditto. * libm/*/aclocal.m4: Ditto. * libm/*/configure: Ditto. * libm/libm.texinfo: Ditto. * libc/sys/linux/shared.ld: Add VERS_2.0
2012-10-21 * libc/sys/mmixware/sbrk.c (_sbrk): Drop unused extern declarationHans-Peter Nilsson1-2/+18
of "end". Mark allocated memory by applying PRELD.
2012-10-02* libc/sys/sysnecv850/sbrk.c (_sbrk): Change heap_start to be anDJ Delorie1-2/+2
array of undefined size, to avoid problems when compiled with -msda=4. * v850/sbrk.c (_sbrk): Change heap_start to be an array of undefined size, to avoid problems when compiled with -msda=4.
2012-07-30 * libc/sys/sysnecv850/crt0.S (_start): Use v850e-specificKevin Buettner1-1/+1
start up code for v850e2 and v850e2v3 too.
2012-07-182012-07-18 Ralf Corsépius <ralf.corsepius@rtems.org>Ralf Corsepius1-3/+3
* libc/sys/rtems/machine/_types.h (_ssize_t): Use signed int for __v850__, __851__.
2012-07-132012-07-13 Ralf Corsépius <ralf.corsepius@rtems.org>Ralf Corsepius1-2/+3
* libc/sys/rtems/machine/_types.h (_ssize_t): Add __ARM_EABI__, __v850__, __851__.
2012-05-10 * libc/sys/rtems/machine/_types.h: Add Microblaze.Corinna Vinschen1-1/+1
2012-05-09 * libc/sys/rtems/crt0.c: Add stubs for access(), ftruncate(),Corinna Vinschen1-1/+8
_getpid_r(), geteuid(), getgid, _getgid_r, getpid(), getppid(), and _getpid_r().
2012-03-092012-03-09 Jeff Johnston <jjohnstn@redhat.com>Jeff Johnston4-4/+4
* libc/include/machine/setjmp-dj.h: Modify license to include modification in clause as permitted by DJ Delorie. * libc/machine/arm/access.c: Ditto. * libc/machine/i386/setjmp.S: Ditto. * libc/sys/h8300hms/sys/file.h: Ditto. * libc/sys/linux/machine/i386/setjmp.S: Ditto. * libc/sys/sysmec/access.c: Ditto. * libc/sys/sysnecv850/access.c: Ditto.
2012-02-212012-02-21 Jeremy Bennett <jeremy.bennett@embecosm.com>Jeff Johnston8-2/+6416
Alan Lehotsky <apl@alum.mit.edu> Joern Rennecke <joern.rennecke@embecosm.com> * configure.host: Add Epiphany support. * libc/include/machine/ieeefp.h: Likewise. * libc/include/machine/setjmp.h: Likewise. * libc/machine/configure.in, libc/sys/configure.in: Likewise. * libc/machine/configure, libc/sys/configure: Regenerate. * libc/machine/epiphany, libc/sys/epiphany: New directories. * NEWS: Mention addition of Epiphany.