mirror of
https://sourceware.org/git/glibc.git
synced 2025-08-01 10:06:57 +03:00
Fix misspellings in sysdeps/unix -- BZ 25337
Applying this commit results in bit-identical rebuild of libc.so.6 math/libm.so.6 elf/ld-linux-x86-64.so.2 mathvec/libmvec.so.1 Reviewed-by: Florian Weimer <fweimer@redhat.com>
This commit is contained in:
@ -20,7 +20,7 @@
|
|||||||
|
|
||||||
#define SP_ALIGN_MASK ~15
|
#define SP_ALIGN_MASK ~15
|
||||||
|
|
||||||
/* Size of an X regiser in bytes. */
|
/* Size of an X register in bytes. */
|
||||||
#define SZREG 8
|
#define SZREG 8
|
||||||
|
|
||||||
/* Size of a V register in bytes. */
|
/* Size of a V register in bytes. */
|
||||||
|
@ -44,7 +44,7 @@ weak_alias (__getcontext, getcontext)
|
|||||||
|
|
||||||
|
|
||||||
/* An internal routine used by getcontext and setcontext.
|
/* An internal routine used by getcontext and setcontext.
|
||||||
The incomming return address register is $0. */
|
The incoming return address register is $0. */
|
||||||
|
|
||||||
.align 4
|
.align 4
|
||||||
.globl __getcontext_x
|
.globl __getcontext_x
|
||||||
|
@ -95,7 +95,7 @@ asm(".arch ev56");
|
|||||||
#define TSUNAMI_DENSE_MEM (0x80000000000UL)
|
#define TSUNAMI_DENSE_MEM (0x80000000000UL)
|
||||||
|
|
||||||
/* Polaris has SPARSE space, but we prefer to use only DENSE
|
/* Polaris has SPARSE space, but we prefer to use only DENSE
|
||||||
because of some idiosyncracies in actually using SPARSE. */
|
because of some idiosyncrasies in actually using SPARSE. */
|
||||||
#define POLARIS_IO_BASE (0xf9fc000000UL)
|
#define POLARIS_IO_BASE (0xf9fc000000UL)
|
||||||
#define POLARIS_DENSE_MEM (0xf900000000UL)
|
#define POLARIS_DENSE_MEM (0xf900000000UL)
|
||||||
|
|
||||||
|
@ -31,5 +31,5 @@
|
|||||||
typedef unsigned long int elf_greg_t;
|
typedef unsigned long int elf_greg_t;
|
||||||
typedef unsigned long int elf_gregset_t[ELF_NGREG];
|
typedef unsigned long int elf_gregset_t[ELF_NGREG];
|
||||||
|
|
||||||
/* There's no seperate floating point reg file in ARCv2. */
|
/* There's no separate floating point reg file in ARCv2. */
|
||||||
typedef struct { } elf_fpregset_t;
|
typedef struct { } elf_fpregset_t;
|
||||||
|
@ -43,7 +43,7 @@ ENTRY (__clone)
|
|||||||
bz L (__sys_err)
|
bz L (__sys_err)
|
||||||
|
|
||||||
/* save some of the orig args
|
/* save some of the orig args
|
||||||
r0 containg @fn will be clobbered AFTER syscall (with ret val)
|
r0 containing @fn will be clobbered AFTER syscall (with ret val)
|
||||||
rest are clobbered BEFORE syscall due to different arg ordering. */
|
rest are clobbered BEFORE syscall due to different arg ordering. */
|
||||||
mov r10, r0 /* @fn. */
|
mov r10, r0 /* @fn. */
|
||||||
mov r11, r3 /* @args. */
|
mov r11, r3 /* @args. */
|
||||||
|
@ -182,11 +182,11 @@ hidden_proto (__syscall_error)
|
|||||||
__ret = (long int) (arg1); \
|
__ret = (long int) (arg1); \
|
||||||
LOAD_ARGS_0 (nm, arg1)
|
LOAD_ARGS_0 (nm, arg1)
|
||||||
|
|
||||||
/* Note that the use of _tmpX might look superflous, however it is needed
|
/* Note that the use of _tmpX might look superfluous, however it is needed
|
||||||
to ensure that register variables are not clobbered if arg happens to be
|
to ensure that register variables are not clobbered if arg happens to be
|
||||||
a function call itself. e.g. sched_setaffinity() calling getpid() for arg2
|
a function call itself. e.g. sched_setaffinity() calling getpid() for arg2
|
||||||
Also this specific order of recursive calling is important to segregate
|
Also this specific order of recursive calling is important to segregate
|
||||||
the tmp args evaluation (function call case described above) and assigment
|
the tmp args evaluation (function call case described above) and assignment
|
||||||
of register variables. */
|
of register variables. */
|
||||||
|
|
||||||
# define LOAD_ARGS_2(nm, arg1, arg2) \
|
# define LOAD_ARGS_2(nm, arg1, arg2) \
|
||||||
|
@ -28,7 +28,7 @@
|
|||||||
to store the child thread ID at its locationm, to erase it in child memory
|
to store the child thread ID at its locationm, to erase it in child memory
|
||||||
when the child exits, and do a wakeup on the futex at that address.
|
when the child exits, and do a wakeup on the futex at that address.
|
||||||
|
|
||||||
The architecture with non-default kernel abi semantic should correctlly
|
The architecture with non-default kernel abi semantic should correctly
|
||||||
override it with one of the supported calling convention (check generic
|
override it with one of the supported calling convention (check generic
|
||||||
kernel-features.h for the clone abi variants). */
|
kernel-features.h for the clone abi variants). */
|
||||||
static inline pid_t
|
static inline pid_t
|
||||||
|
@ -73,7 +73,7 @@
|
|||||||
/* We have no predefined limit on the number of threads. */
|
/* We have no predefined limit on the number of threads. */
|
||||||
#undef PTHREAD_THREADS_MAX
|
#undef PTHREAD_THREADS_MAX
|
||||||
|
|
||||||
/* Maximum amount by which a process can descrease its asynchronous I/O
|
/* Maximum amount by which a process can decrease its asynchronous I/O
|
||||||
priority level. */
|
priority level. */
|
||||||
#define AIO_PRIO_DELTA_MAX 20
|
#define AIO_PRIO_DELTA_MAX 20
|
||||||
|
|
||||||
|
@ -78,7 +78,7 @@
|
|||||||
# define MADV_UNMERGEABLE 13 /* KSM may not merge identical pages. */
|
# define MADV_UNMERGEABLE 13 /* KSM may not merge identical pages. */
|
||||||
# define MADV_HUGEPAGE 14 /* Worth backing with hugepages. */
|
# define MADV_HUGEPAGE 14 /* Worth backing with hugepages. */
|
||||||
# define MADV_NOHUGEPAGE 15 /* Not worth backing with hugepages. */
|
# define MADV_NOHUGEPAGE 15 /* Not worth backing with hugepages. */
|
||||||
# define MADV_DONTDUMP 16 /* Explicity exclude from the core dump,
|
# define MADV_DONTDUMP 16 /* Explicitly exclude from the core dump,
|
||||||
overrides the coredump filter bits. */
|
overrides the coredump filter bits. */
|
||||||
# define MADV_DODUMP 17 /* Clear the MADV_DONTDUMP flag. */
|
# define MADV_DODUMP 17 /* Clear the MADV_DONTDUMP flag. */
|
||||||
# define MADV_WIPEONFORK 18 /* Zero memory on fork, child only. */
|
# define MADV_WIPEONFORK 18 /* Zero memory on fork, child only. */
|
||||||
|
@ -84,7 +84,7 @@
|
|||||||
/* We support user-defined stacks. */
|
/* We support user-defined stacks. */
|
||||||
#define _POSIX_THREAD_ATTR_STACKADDR 200809L
|
#define _POSIX_THREAD_ATTR_STACKADDR 200809L
|
||||||
|
|
||||||
/* We support priority inheritence. */
|
/* We support priority inheritance. */
|
||||||
#define _POSIX_THREAD_PRIO_INHERIT 200809L
|
#define _POSIX_THREAD_PRIO_INHERIT 200809L
|
||||||
|
|
||||||
/* We support priority protection, though only for non-robust
|
/* We support priority protection, though only for non-robust
|
||||||
@ -92,7 +92,7 @@
|
|||||||
#define _POSIX_THREAD_PRIO_PROTECT 200809L
|
#define _POSIX_THREAD_PRIO_PROTECT 200809L
|
||||||
|
|
||||||
#ifdef __USE_XOPEN2K8
|
#ifdef __USE_XOPEN2K8
|
||||||
/* We support priority inheritence for robust mutexes. */
|
/* We support priority inheritance for robust mutexes. */
|
||||||
# define _POSIX_THREAD_ROBUST_PRIO_INHERIT 200809L
|
# define _POSIX_THREAD_ROBUST_PRIO_INHERIT 200809L
|
||||||
|
|
||||||
/* We do not support priority protection for robust mutexes. */
|
/* We do not support priority protection for robust mutexes. */
|
||||||
|
@ -143,7 +143,7 @@ enum
|
|||||||
{
|
{
|
||||||
BUS_ADRALN = 1, /* Invalid address alignment. */
|
BUS_ADRALN = 1, /* Invalid address alignment. */
|
||||||
# define BUS_ADRALN BUS_ADRALN
|
# define BUS_ADRALN BUS_ADRALN
|
||||||
BUS_ADRERR, /* Non-existant physical address. */
|
BUS_ADRERR, /* Non-existent physical address. */
|
||||||
# define BUS_ADRERR BUS_ADRERR
|
# define BUS_ADRERR BUS_ADRERR
|
||||||
BUS_OBJERR, /* Object specific hardware error. */
|
BUS_OBJERR, /* Object specific hardware error. */
|
||||||
# define BUS_OBJERR BUS_OBJERR
|
# define BUS_OBJERR BUS_OBJERR
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* termios tcflag symbolic contants definitions. Linux/generic version.
|
/* termios tcflag symbolic constant definitions. Linux/generic version.
|
||||||
Copyright (C) 2019-2023 Free Software Foundation, Inc.
|
Copyright (C) 2019-2023 Free Software Foundation, Inc.
|
||||||
This file is part of the GNU C Library.
|
This file is part of the GNU C Library.
|
||||||
|
|
||||||
|
@ -36,7 +36,7 @@ print_auxv (void)
|
|||||||
|| av->a_type == AT_PLATFORM
|
|| av->a_type == AT_PLATFORM
|
||||||
|| av->a_type == AT_BASE_PLATFORM)
|
|| av->a_type == AT_BASE_PLATFORM)
|
||||||
/* The address of the strings is not useful at all, so print
|
/* The address of the strings is not useful at all, so print
|
||||||
the strings themselvs. */
|
the strings themselves. */
|
||||||
_dl_diagnostics_print_string ((const char *) av->a_un.a_val);
|
_dl_diagnostics_print_string ((const char *) av->a_un.a_val);
|
||||||
else
|
else
|
||||||
_dl_printf ("0x%lx", (unsigned long int) av->a_un.a_val);
|
_dl_printf ("0x%lx", (unsigned long int) av->a_un.a_val);
|
||||||
|
@ -20,7 +20,7 @@
|
|||||||
and shared (rtld) modes:
|
and shared (rtld) modes:
|
||||||
|
|
||||||
1. PROCINFO_DECL is defined, meaning we are only interested in
|
1. PROCINFO_DECL is defined, meaning we are only interested in
|
||||||
declarations. For static it requires use the extern keywork along with
|
declarations. For static it requires use the extern keyword along with
|
||||||
the attribute_relro while for shared it will be embedded in the
|
the attribute_relro while for shared it will be embedded in the
|
||||||
rtld_global_ro.
|
rtld_global_ro.
|
||||||
|
|
||||||
|
@ -32,7 +32,7 @@ def extract_system_call_name(macro):
|
|||||||
else:
|
else:
|
||||||
raise ValueError('invalid system call name: {!r}'.format(macro))
|
raise ValueError('invalid system call name: {!r}'.format(macro))
|
||||||
|
|
||||||
# Matches macros for systme call names.
|
# Matches macros for system call names.
|
||||||
RE_SYSCALL = re.compile('__NR_.*')
|
RE_SYSCALL = re.compile('__NR_.*')
|
||||||
|
|
||||||
# Some __NR_ constants are not real
|
# Some __NR_ constants are not real
|
||||||
@ -54,7 +54,7 @@ def kernel_constants(cc):
|
|||||||
return {extract_system_call_name(name) : int(value)
|
return {extract_system_call_name(name) : int(value)
|
||||||
for name, value in glibcextract.compute_macro_consts(
|
for name, value in glibcextract.compute_macro_consts(
|
||||||
'#include <asm/unistd.h>\n'
|
'#include <asm/unistd.h>\n'
|
||||||
# Regularlize the kernel definitions if necessary.
|
# Regularize the kernel definitions if necessary.
|
||||||
'#include <fixup-asm-unistd.h>',
|
'#include <fixup-asm-unistd.h>',
|
||||||
cc, macro_re=RE_SYSCALL, exclude_re=RE_PSEUDO_SYSCALL)
|
cc, macro_re=RE_SYSCALL, exclude_re=RE_PSEUDO_SYSCALL)
|
||||||
.items()}
|
.items()}
|
||||||
|
@ -51,7 +51,7 @@
|
|||||||
|
|
||||||
Return:
|
Return:
|
||||||
|
|
||||||
On success the thread ID of the child process is returend in
|
On success the thread ID of the child process is returned in
|
||||||
the callers context.
|
the callers context.
|
||||||
On error return -1, and set errno to the value returned by
|
On error return -1, and set errno to the value returned by
|
||||||
the syscall.
|
the syscall.
|
||||||
|
@ -53,7 +53,7 @@
|
|||||||
#define LOAD_PIC(LREG) \
|
#define LOAD_PIC(LREG) \
|
||||||
copy LREG , %r19
|
copy LREG , %r19
|
||||||
/* Inline assembly defines */
|
/* Inline assembly defines */
|
||||||
#define TREG_ASM "%r4" /* Cant clobber r3, it holds framemarker */
|
#define TREG_ASM "%r4" /* Can't clobber r3, it holds framemarker */
|
||||||
#define SAVE_ASM_PIC " copy %%r19, %" TREG_ASM "\n"
|
#define SAVE_ASM_PIC " copy %%r19, %" TREG_ASM "\n"
|
||||||
#define LOAD_ASM_PIC " copy %" TREG_ASM ", %%r19\n"
|
#define LOAD_ASM_PIC " copy %" TREG_ASM ", %%r19\n"
|
||||||
#define CLOB_TREG TREG_ASM ,
|
#define CLOB_TREG TREG_ASM ,
|
||||||
@ -134,7 +134,7 @@
|
|||||||
/* SAVE_RP says we do */ ASM_LINE_SEP \
|
/* SAVE_RP says we do */ ASM_LINE_SEP \
|
||||||
stw %rp, -20(%sr0,%sp) ASM_LINE_SEP \
|
stw %rp, -20(%sr0,%sp) ASM_LINE_SEP \
|
||||||
.cfi_offset 2, -20 ASM_LINE_SEP \
|
.cfi_offset 2, -20 ASM_LINE_SEP \
|
||||||
/*FIXME: Call mcount? (carefull with stack!) */
|
/*FIXME: Call mcount? (careful with stack!) */
|
||||||
|
|
||||||
/* Some syscall wrappers do not call other functions, and
|
/* Some syscall wrappers do not call other functions, and
|
||||||
hence are classified as leaf, so add NO_CALLS for gdb */
|
hence are classified as leaf, so add NO_CALLS for gdb */
|
||||||
@ -151,7 +151,7 @@
|
|||||||
/* SAVE_RP says we do */ ASM_LINE_SEP \
|
/* SAVE_RP says we do */ ASM_LINE_SEP \
|
||||||
stw %rp, -20(%sr0,%sp) ASM_LINE_SEP \
|
stw %rp, -20(%sr0,%sp) ASM_LINE_SEP \
|
||||||
.cfi_offset 2, -20 ASM_LINE_SEP \
|
.cfi_offset 2, -20 ASM_LINE_SEP \
|
||||||
/*FIXME: Call mcount? (carefull with stack!) */
|
/*FIXME: Call mcount? (careful with stack!) */
|
||||||
|
|
||||||
#undef END
|
#undef END
|
||||||
#define END(name) \
|
#define END(name) \
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
<https://www.gnu.org/licenses/>. */
|
<https://www.gnu.org/licenses/>. */
|
||||||
|
|
||||||
#if BUILD_PIE_DEFAULT
|
#if BUILD_PIE_DEFAULT
|
||||||
/* Can't use "call *%gs:SYSINFO_OFFSET" during statup in static PIE. */
|
/* Can't use "call *%gs:SYSINFO_OFFSET" during startup in static PIE. */
|
||||||
# define I386_USE_SYSENTER 0
|
# define I386_USE_SYSENTER 0
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -61,7 +61,7 @@
|
|||||||
might return a large offset. Therefore we must not anymore test
|
might return a large offset. Therefore we must not anymore test
|
||||||
for < 0, but test for a real error by making sure the value in %eax
|
for < 0, but test for a real error by making sure the value in %eax
|
||||||
is a real error number. Linus said he will make sure the no syscall
|
is a real error number. Linus said he will make sure the no syscall
|
||||||
returns a value in -1 .. -4095 as a valid result so we can savely
|
returns a value in -1 .. -4095 as a valid result so we can safely
|
||||||
test with -4095. */
|
test with -4095. */
|
||||||
|
|
||||||
/* We don't want the label for the error handle to be global when we define
|
/* We don't want the label for the error handle to be global when we define
|
||||||
|
@ -86,6 +86,6 @@ libc_hidden_def (__clone2)
|
|||||||
|
|
||||||
/* For now we leave __clone undefined. This is unlikely to be a */
|
/* For now we leave __clone undefined. This is unlikely to be a */
|
||||||
/* problem, since at least the i386 __clone in glibc always failed */
|
/* problem, since at least the i386 __clone in glibc always failed */
|
||||||
/* with a 0 sp (eventhough the kernel explicitly handled it). */
|
/* with a 0 sp (even though the kernel explicitly handled it). */
|
||||||
/* Thus all such calls needed to pass an explicit sp, and as a result, */
|
/* Thus all such calls needed to pass an explicit sp, and as a result, */
|
||||||
/* would be unlikely to work on ia64. */
|
/* would be unlikely to work on ia64. */
|
||||||
|
@ -48,7 +48,7 @@ ia64_rse_rnat_addr (unsigned long *slot_addr)
|
|||||||
return (unsigned long *) ((unsigned long) slot_addr | (0x3f << 3));
|
return (unsigned long *) ((unsigned long) slot_addr | (0x3f << 3));
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Calcuate the number of registers in the dirty partition starting at
|
/* Calculate the number of registers in the dirty partition starting at
|
||||||
BSPSTORE with a size of DIRTY bytes. This isn't simply DIRTY
|
BSPSTORE with a size of DIRTY bytes. This isn't simply DIRTY
|
||||||
divided by eight because the 64th slot is used to store ar.rnat. */
|
divided by eight because the 64th slot is used to store ar.rnat. */
|
||||||
|
|
||||||
|
@ -86,7 +86,7 @@
|
|||||||
a large offset. Therefore we must not anymore test for < 0, but test
|
a large offset. Therefore we must not anymore test for < 0, but test
|
||||||
for a real error by making sure the value in %d0 is a real error
|
for a real error by making sure the value in %d0 is a real error
|
||||||
number. Linus said he will make sure the no syscall returns a value
|
number. Linus said he will make sure the no syscall returns a value
|
||||||
in -1 .. -4095 as a valid result so we can savely test with -4095. */
|
in -1 .. -4095 as a valid result so we can safely test with -4095. */
|
||||||
|
|
||||||
/* We don't want the label for the error handler to be visible in the symbol
|
/* We don't want the label for the error handler to be visible in the symbol
|
||||||
table when we define it here. */
|
table when we define it here. */
|
||||||
|
@ -68,7 +68,7 @@ struct timer
|
|||||||
|
|
||||||
|
|
||||||
/* For !SIGEV_THREAD, the resulting 'timer_t' is the returned kernel timer
|
/* For !SIGEV_THREAD, the resulting 'timer_t' is the returned kernel timer
|
||||||
identifer (kernel_timer_t), while for SIGEV_THREAD it uses the fact malloc
|
identifier (kernel_timer_t), while for SIGEV_THREAD it uses the fact malloc
|
||||||
returns at least _Alignof (max_align_t) pointers plus that valid
|
returns at least _Alignof (max_align_t) pointers plus that valid
|
||||||
kernel_timer_t are always positive to set the MSB bit of the returned
|
kernel_timer_t are always positive to set the MSB bit of the returned
|
||||||
'timer_t' to indicate the timer handles a SIGEV_THREAD. */
|
'timer_t' to indicate the timer handles a SIGEV_THREAD. */
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
#define ATOMIC_EXCHANGE_USES_CAS 0
|
#define ATOMIC_EXCHANGE_USES_CAS 0
|
||||||
|
|
||||||
/* Compare and exchange.
|
/* Compare and exchange.
|
||||||
For all "bool" routines, we return FALSE if exchange succesful. */
|
For all "bool" routines, we return FALSE if exchange successful. */
|
||||||
|
|
||||||
#define __arch_compare_and_exchange_bool_8_int(mem, newval, oldval, model) \
|
#define __arch_compare_and_exchange_bool_8_int(mem, newval, oldval, model) \
|
||||||
({ \
|
({ \
|
||||||
|
@ -83,7 +83,7 @@
|
|||||||
#undef ret_NOERRNO
|
#undef ret_NOERRNO
|
||||||
#define ret_NOERRNO ret
|
#define ret_NOERRNO ret
|
||||||
|
|
||||||
/* Perfroms a system call, returning the error code. */
|
/* Performs a system call, returning the error code. */
|
||||||
#undef PSEUDO_ERRVAL
|
#undef PSEUDO_ERRVAL
|
||||||
#define PSEUDO_ERRVAL(name, syscall_name, args) \
|
#define PSEUDO_ERRVAL(name, syscall_name, args) \
|
||||||
PSEUDO_NOERRNO (name, syscall_name, args); \
|
PSEUDO_NOERRNO (name, syscall_name, args); \
|
||||||
|
@ -38,7 +38,7 @@
|
|||||||
a large offset. Therefore we must not anymore test for < 0, but test
|
a large offset. Therefore we must not anymore test for < 0, but test
|
||||||
for a real error by making sure the value in %d0 is a real error
|
for a real error by making sure the value in %d0 is a real error
|
||||||
number. Linus said he will make sure the no syscall returns a value
|
number. Linus said he will make sure the no syscall returns a value
|
||||||
in -1 .. -4095 as a valid result so we can savely test with -4095. */
|
in -1 .. -4095 as a valid result so we can safely test with -4095. */
|
||||||
|
|
||||||
/* We don't want the label for the error handler to be visible in the symbol
|
/* We don't want the label for the error handler to be visible in the symbol
|
||||||
table when we define it here. */
|
table when we define it here. */
|
||||||
|
@ -43,7 +43,7 @@
|
|||||||
#ifdef __ASSEMBLER__
|
#ifdef __ASSEMBLER__
|
||||||
|
|
||||||
/* In microblaze ABI function call arguments are passed in registers
|
/* In microblaze ABI function call arguments are passed in registers
|
||||||
r5...r10. The return value is stored in r3 (or r3:r4 regiters pair).
|
r5...r10. The return value is stored in r3 (or r3:r4 register pair).
|
||||||
Linux syscall uses the same convention with the addition that the
|
Linux syscall uses the same convention with the addition that the
|
||||||
syscall number is passed in r12. To enter the kernel "brki r14,8"
|
syscall number is passed in r12. To enter the kernel "brki r14,8"
|
||||||
instruction is used.
|
instruction is used.
|
||||||
@ -58,7 +58,7 @@
|
|||||||
a large offset. Therefore we must not anymore test for < 0, but test
|
a large offset. Therefore we must not anymore test for < 0, but test
|
||||||
for a real error by making sure the value in %d0 is a real error
|
for a real error by making sure the value in %d0 is a real error
|
||||||
number. Linus said he will make sure the no syscall returns a value
|
number. Linus said he will make sure the no syscall returns a value
|
||||||
in -1 .. -4095 as a valid result so we can savely test with -4095. */
|
in -1 .. -4095 as a valid result so we can safely test with -4095. */
|
||||||
|
|
||||||
/* We don't want the label for the error handler to be visible in the symbol
|
/* We don't want the label for the error handler to be visible in the symbol
|
||||||
table when we define it here. */
|
table when we define it here. */
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* Tests register values retreived by getcontext() for mips o32.
|
/* Tests register values retrieved by getcontext() for mips o32.
|
||||||
Copyright (C) 2017-2023 Free Software Foundation, Inc.
|
Copyright (C) 2017-2023 Free Software Foundation, Inc.
|
||||||
This file is part of the GNU C Library.
|
This file is part of the GNU C Library.
|
||||||
|
|
||||||
|
@ -32,9 +32,9 @@
|
|||||||
|
|
||||||
/* Defined in the kernel headers: */
|
/* Defined in the kernel headers: */
|
||||||
#define NOTIFY_COOKIE_LEN 32 /* Length of the cookie used. */
|
#define NOTIFY_COOKIE_LEN 32 /* Length of the cookie used. */
|
||||||
#define NOTIFY_WOKENUP 1 /* Code for notifcation. */
|
#define NOTIFY_WOKENUP 1 /* Code for notification. */
|
||||||
#define NOTIFY_REMOVED 2 /* Code for closed message queue
|
#define NOTIFY_REMOVED 2 /* Code for closed message queue
|
||||||
of de-notifcation. */
|
of de-notification. */
|
||||||
|
|
||||||
|
|
||||||
/* Data structure for the queued notification requests. */
|
/* Data structure for the queued notification requests. */
|
||||||
@ -61,7 +61,7 @@ static int netlink_socket = -1;
|
|||||||
|
|
||||||
|
|
||||||
/* Barrier used to make sure data passed to the new thread is not
|
/* Barrier used to make sure data passed to the new thread is not
|
||||||
resused by the parent. */
|
reused by the parent. */
|
||||||
static pthread_barrier_t notify_barrier;
|
static pthread_barrier_t notify_barrier;
|
||||||
|
|
||||||
|
|
||||||
|
@ -27,7 +27,7 @@ __BEGIN_DECLS
|
|||||||
|
|
||||||
#define SHAPER_QLEN 10
|
#define SHAPER_QLEN 10
|
||||||
/*
|
/*
|
||||||
* This is a bit speed dependant (read it shouldnt be a constant!)
|
* This is a bit speed dependent (read it shouldn't be a constant!)
|
||||||
*
|
*
|
||||||
* 5 is about right for 28.8 upwards. Below that double for every
|
* 5 is about right for 28.8 upwards. Below that double for every
|
||||||
* halving of speed or so. - ie about 20 for 9600 baud.
|
* halving of speed or so. - ie about 20 for 9600 baud.
|
||||||
|
@ -62,7 +62,7 @@
|
|||||||
#define AX25_DIGI_INBAND 0x01 /* Allow digipeating within port */
|
#define AX25_DIGI_INBAND 0x01 /* Allow digipeating within port */
|
||||||
#define AX25_DIGI_XBAND 0x02 /* Allow digipeating across ports */
|
#define AX25_DIGI_XBAND 0x02 /* Allow digipeating across ports */
|
||||||
|
|
||||||
/* Maximim number of digipeaters: */
|
/* Maximum number of digipeaters: */
|
||||||
#define AX25_MAX_DIGIS 8
|
#define AX25_MAX_DIGIS 8
|
||||||
|
|
||||||
|
|
||||||
@ -80,7 +80,7 @@ struct sockaddr_ax25
|
|||||||
};
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The sockaddr struct with the digipeater adresses:
|
* The sockaddr struct with the digipeater addresses:
|
||||||
*/
|
*/
|
||||||
struct full_sockaddr_ax25
|
struct full_sockaddr_ax25
|
||||||
{
|
{
|
||||||
|
@ -83,7 +83,7 @@ __netlink_assert_response (int fd, ssize_t result)
|
|||||||
__libc_fatal (message);
|
__libc_fatal (message);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
/* Restore orignal errno value. */
|
/* Restore original errno value. */
|
||||||
__set_errno (error_code);
|
__set_errno (error_code);
|
||||||
}
|
}
|
||||||
else if (result < sizeof (struct nlmsghdr))
|
else if (result < sizeof (struct nlmsghdr))
|
||||||
|
@ -93,7 +93,7 @@ weak_alias (__setcontext, setcontext)
|
|||||||
|
|
||||||
If this NOP word does not exist, FDE lookup just repeatedly finds
|
If this NOP word does not exist, FDE lookup just repeatedly finds
|
||||||
__setcontext's FDE in an infinite loop, due to the convention of
|
__setcontext's FDE in an infinite loop, due to the convention of
|
||||||
using 'address - 1' for FDE lookup. Modifiying/deleting the below
|
using 'address - 1' for FDE lookup. Modifying/deleting the below
|
||||||
__startcontext's FDE has no help on this. */
|
__startcontext's FDE has no help on this. */
|
||||||
nop
|
nop
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* Setup of nscd worker threads. Linux verison.
|
/* Setup of nscd worker threads. Linux version.
|
||||||
Copyright (C) 2004-2023 Free Software Foundation, Inc.
|
Copyright (C) 2004-2023 Free Software Foundation, Inc.
|
||||||
This file is part of the GNU C Library.
|
This file is part of the GNU C Library.
|
||||||
|
|
||||||
|
@ -80,7 +80,7 @@ weak_alias (__setcontext, setcontext)
|
|||||||
makecontext we have set r9 to the start of &__startcontext.
|
makecontext we have set r9 to the start of &__startcontext.
|
||||||
|
|
||||||
If this NOP did not exist the unwinder would repeatedly find
|
If this NOP did not exist the unwinder would repeatedly find
|
||||||
__setcontext's FDE in an infinite loop. Modifiying/deleting the below
|
__setcontext's FDE in an infinite loop. Modifying/deleting the below
|
||||||
__startcontext's FDE has no help on this. */
|
__startcontext's FDE has no help on this. */
|
||||||
l.nop
|
l.nop
|
||||||
|
|
||||||
|
@ -139,7 +139,7 @@ __statfs_link_max (int result, const struct statfs *fsbuf, const char *file,
|
|||||||
/* Not possible, return the default value. */
|
/* Not possible, return the default value. */
|
||||||
return LINUX_LINK_MAX;
|
return LINUX_LINK_MAX;
|
||||||
|
|
||||||
/* Some error occured. */
|
/* Some error occurred. */
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -202,7 +202,7 @@ __statfs_filesize_max (int result, const struct statfs *fsbuf)
|
|||||||
/* Not possible, return the default value. */
|
/* Not possible, return the default value. */
|
||||||
return 32;
|
return 32;
|
||||||
|
|
||||||
/* Some error occured. */
|
/* Some error occurred. */
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -251,7 +251,7 @@ __statfs_symlinks (int result, const struct statfs *fsbuf)
|
|||||||
/* Not possible, return the default value. */
|
/* Not possible, return the default value. */
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
/* Some error occured. */
|
/* Some error occurred. */
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -286,7 +286,7 @@ __statfs_chown_restricted (int result, const struct statfs *fsbuf)
|
|||||||
/* Not possible, return the default value. */
|
/* Not possible, return the default value. */
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
/* Some error occured. */
|
/* Some error occurred. */
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -28,7 +28,7 @@ __personality (unsigned long persona)
|
|||||||
task_struct->pesonality is "unsigned int".
|
task_struct->pesonality is "unsigned int".
|
||||||
Starting with kernel commit v2.6.35-rc1-372-g485d527, the personality
|
Starting with kernel commit v2.6.35-rc1-372-g485d527, the personality
|
||||||
syscall accepts "unsigned int" instead of "long unsigned int".
|
syscall accepts "unsigned int" instead of "long unsigned int".
|
||||||
Inbetween, a personality argument that does not fit into "unsigned int"
|
In between, a personality argument that does not fit into "unsigned int"
|
||||||
would result to system call returning -EINVAL.
|
would result to system call returning -EINVAL.
|
||||||
We explicitly truncate the personality argument to "unsigned int"
|
We explicitly truncate the personality argument to "unsigned int"
|
||||||
to eliminate the uncertainty. */
|
to eliminate the uncertainty. */
|
||||||
|
@ -29,7 +29,7 @@
|
|||||||
|
|
||||||
Second option will be used by arm which define __NR_arm_fadvise64_64
|
Second option will be used by arm which define __NR_arm_fadvise64_64
|
||||||
(redefined to __NR_fadvise64_64 in kernel-features.h) that behaves as
|
(redefined to __NR_fadvise64_64 in kernel-features.h) that behaves as
|
||||||
__NR_fadvise64_64 (without the aligment argument required for the ABI).
|
__NR_fadvise64_64 (without the alignment argument required for the ABI).
|
||||||
|
|
||||||
Third option will be used by mips o32. Mips will use a 7 argument
|
Third option will be used by mips o32. Mips will use a 7 argument
|
||||||
syscall with __NR_fadvise64.
|
syscall with __NR_fadvise64.
|
||||||
|
@ -53,7 +53,7 @@ static inline void
|
|||||||
__always_inline
|
__always_inline
|
||||||
do_set_elision_enable (int32_t elision_enable)
|
do_set_elision_enable (int32_t elision_enable)
|
||||||
{
|
{
|
||||||
/* Enable elision if it's avaliable in hardware. It's not necessary to check
|
/* Enable elision if it's available in hardware. It's not necessary to check
|
||||||
if __libc_enable_secure isn't enabled since elision_enable will be set
|
if __libc_enable_secure isn't enabled since elision_enable will be set
|
||||||
according to the default, which is disabled. */
|
according to the default, which is disabled. */
|
||||||
if (elision_enable == 1)
|
if (elision_enable == 1)
|
||||||
@ -126,7 +126,7 @@ __lll_elision_init (void)
|
|||||||
syscalls which makes the glibc workaround superflours. Worse, glibc
|
syscalls which makes the glibc workaround superflours. Worse, glibc
|
||||||
transaction abortions leads to a performance issues on recent kernels.
|
transaction abortions leads to a performance issues on recent kernels.
|
||||||
|
|
||||||
So Lock Elision is just enabled when it has been explict set (either
|
So Lock Elision is just enabled when it has been explicitly set (either
|
||||||
by tunables of by a configure switch) and if kernel aborts HTM
|
by tunables of by a configure switch) and if kernel aborts HTM
|
||||||
transactions on syscalls (PPC_FEATURE2_HTM_NOSC) */
|
transactions on syscalls (PPC_FEATURE2_HTM_NOSC) */
|
||||||
|
|
||||||
|
@ -57,7 +57,7 @@ get_timebase_freq_fallback (void)
|
|||||||
the last 512 bytes of cpuinfo, so two 512 byte half_bufs
|
the last 512 bytes of cpuinfo, so two 512 byte half_bufs
|
||||||
will be sufficient to contain the timebase and will
|
will be sufficient to contain the timebase and will
|
||||||
handle the case where the timebase spans the half_buf
|
handle the case where the timebase spans the half_buf
|
||||||
boundry. */
|
boundary. */
|
||||||
const ssize_t half_buf = sizeof (buf) / 2;
|
const ssize_t half_buf = sizeof (buf) / 2;
|
||||||
while (n >= half_buf)
|
while (n >= half_buf)
|
||||||
{
|
{
|
||||||
|
@ -28,7 +28,7 @@
|
|||||||
# define ATOMIC_EXCHANGE_USES_CAS 0
|
# define ATOMIC_EXCHANGE_USES_CAS 0
|
||||||
|
|
||||||
/* Compare and exchange.
|
/* Compare and exchange.
|
||||||
For all "bool" routines, we return FALSE if exchange succesful. */
|
For all "bool" routines, we return FALSE if exchange successful. */
|
||||||
|
|
||||||
# define __arch_compare_and_exchange_bool_8_int(mem, newval, oldval, model) \
|
# define __arch_compare_and_exchange_bool_8_int(mem, newval, oldval, model) \
|
||||||
({ \
|
({ \
|
||||||
|
@ -121,7 +121,7 @@
|
|||||||
# undef ret_NOERRNO
|
# undef ret_NOERRNO
|
||||||
# define ret_NOERRNO ret
|
# define ret_NOERRNO ret
|
||||||
|
|
||||||
/* Perfroms a system call, returning the error code. */
|
/* Performs a system call, returning the error code. */
|
||||||
# undef PSEUDO_ERRVAL
|
# undef PSEUDO_ERRVAL
|
||||||
# define PSEUDO_ERRVAL(name, syscall_name, args) \
|
# define PSEUDO_ERRVAL(name, syscall_name, args) \
|
||||||
PSEUDO_NOERRNO (name, syscall_name, args) \
|
PSEUDO_NOERRNO (name, syscall_name, args) \
|
||||||
|
@ -53,7 +53,7 @@ static inline void
|
|||||||
__always_inline
|
__always_inline
|
||||||
do_set_elision_enable (int32_t elision_enable)
|
do_set_elision_enable (int32_t elision_enable)
|
||||||
{
|
{
|
||||||
/* Enable elision if it's avaliable in hardware. It's not necessary to check
|
/* Enable elision if it's available in hardware. It's not necessary to check
|
||||||
if __libc_enable_secure isn't enabled since elision_enable will be set
|
if __libc_enable_secure isn't enabled since elision_enable will be set
|
||||||
according to the default, which is disabled. */
|
according to the default, which is disabled. */
|
||||||
if (elision_enable == 1)
|
if (elision_enable == 1)
|
||||||
|
@ -121,7 +121,7 @@
|
|||||||
pointer access) are filtered and the \
|
pointer access) are filtered and the \
|
||||||
transaction will abort. In this case \
|
transaction will abort. In this case \
|
||||||
the normal lock path will execute it \
|
the normal lock path will execute it \
|
||||||
again and result in a core dump wich does \
|
again and result in a core dump which does \
|
||||||
now show at tbegin but the real executed \
|
now show at tbegin but the real executed \
|
||||||
instruction. \
|
instruction. \
|
||||||
However it is not guaranteed that this \
|
However it is not guaranteed that this \
|
||||||
@ -131,7 +131,7 @@
|
|||||||
memory for being accessible! */ \
|
memory for being accessible! */ \
|
||||||
"2: tbegin 0, 0xFF0E\n\t" \
|
"2: tbegin 0, 0xFF0E\n\t" \
|
||||||
/* Branch away in abort case (this is the \
|
/* Branch away in abort case (this is the \
|
||||||
prefered sequence. See PoP in chapter 5 \
|
preferred sequence. See PoP in chapter 5 \
|
||||||
Transactional-Execution Facility \
|
Transactional-Execution Facility \
|
||||||
Operation). */ \
|
Operation). */ \
|
||||||
" jnz 0f\n\t" \
|
" jnz 0f\n\t" \
|
||||||
|
@ -42,7 +42,7 @@
|
|||||||
a large offset. Therefore we must not anymore test for < 0, but test
|
a large offset. Therefore we must not anymore test for < 0, but test
|
||||||
for a real error by making sure the value in gpr2 is a real error
|
for a real error by making sure the value in gpr2 is a real error
|
||||||
number. Linus said he will make sure that no syscall returns a value
|
number. Linus said he will make sure that no syscall returns a value
|
||||||
in -1 .. -4095 as a valid result so we can savely test with -4095. */
|
in -1 .. -4095 as a valid result so we can safely test with -4095. */
|
||||||
|
|
||||||
#undef PSEUDO
|
#undef PSEUDO
|
||||||
#define PSEUDO(name, syscall_name, args) \
|
#define PSEUDO(name, syscall_name, args) \
|
||||||
|
@ -46,7 +46,7 @@
|
|||||||
a large offset. Therefore we must not anymore test for < 0, but test
|
a large offset. Therefore we must not anymore test for < 0, but test
|
||||||
for a real error by making sure the value in gpr2 is a real error
|
for a real error by making sure the value in gpr2 is a real error
|
||||||
number. Linus said he will make sure that no syscall returns a value
|
number. Linus said he will make sure that no syscall returns a value
|
||||||
in -1 .. -4095 as a valid result so we can savely test with -4095. */
|
in -1 .. -4095 as a valid result so we can safely test with -4095. */
|
||||||
|
|
||||||
#undef PSEUDO
|
#undef PSEUDO
|
||||||
#define PSEUDO(name, syscall_name, args) \
|
#define PSEUDO(name, syscall_name, args) \
|
||||||
|
@ -24,7 +24,7 @@ static long int linux_sysconf (int name);
|
|||||||
|
|
||||||
/* Possible arguments for get_cache_info.
|
/* Possible arguments for get_cache_info.
|
||||||
The values are reflecting the level/attribute/type indications
|
The values are reflecting the level/attribute/type indications
|
||||||
of ecag-instruction (extract cpu attribue). */
|
of ecag-instruction (extract cpu attribute). */
|
||||||
#define CACHE_LEVEL_MAX 8
|
#define CACHE_LEVEL_MAX 8
|
||||||
#define CACHE_ATTR_LINESIZE 1
|
#define CACHE_ATTR_LINESIZE 1
|
||||||
#define CACHE_ATTR_SIZE 2
|
#define CACHE_ATTR_SIZE 2
|
||||||
|
@ -119,7 +119,7 @@ struct sg_scsi_id {
|
|||||||
/* Used by SG_GET_REQUEST_TABLE ioctl(). */
|
/* Used by SG_GET_REQUEST_TABLE ioctl(). */
|
||||||
typedef struct sg_req_info {
|
typedef struct sg_req_info {
|
||||||
char req_state; /* 0 -> not used, 1 -> written, 2 -> ready to read */
|
char req_state; /* 0 -> not used, 1 -> written, 2 -> ready to read */
|
||||||
char orphan; /* 0 -> normal request, 1 -> from interruped SG_IO */
|
char orphan; /* 0 -> normal request, 1 -> from interrupted SG_IO */
|
||||||
char sg_io_owned; /* 0 -> complete with read(), 1 -> owned by SG_IO */
|
char sg_io_owned; /* 0 -> complete with read(), 1 -> owned by SG_IO */
|
||||||
char problem; /* 0 -> no problem detected, 1 -> error to report */
|
char problem; /* 0 -> no problem detected, 1 -> error to report */
|
||||||
int pack_id; /* pack_id associated with request */
|
int pack_id; /* pack_id associated with request */
|
||||||
|
@ -20,7 +20,7 @@
|
|||||||
#include <ipc_priv.h>
|
#include <ipc_priv.h>
|
||||||
#include <sysdep.h>
|
#include <sysdep.h>
|
||||||
|
|
||||||
/* Perform user-defined atomical operation of array of semaphores. */
|
/* Perform user-defined atomic operation of array of semaphores. */
|
||||||
|
|
||||||
int
|
int
|
||||||
semop (int semid, struct sembuf *sops, size_t nsops)
|
semop (int semid, struct sembuf *sops, size_t nsops)
|
||||||
|
@ -34,7 +34,7 @@ semtimedop_syscall (int semid, struct sembuf *sops, size_t nsops,
|
|||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Perform user-defined atomical operation of array of semaphores. */
|
/* Perform user-defined atomic operation of array of semaphores. */
|
||||||
int
|
int
|
||||||
__semtimedop64 (int semid, struct sembuf *sops, size_t nsops,
|
__semtimedop64 (int semid, struct sembuf *sops, size_t nsops,
|
||||||
const struct __timespec64 *timeout)
|
const struct __timespec64 *timeout)
|
||||||
|
@ -21,7 +21,7 @@
|
|||||||
#include <asm/ptrace.h>
|
#include <asm/ptrace.h>
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
|
|
||||||
/* asm/ptrace.h polutes the namespace. */
|
/* asm/ptrace.h pollutes the namespace. */
|
||||||
#undef PTRACE_GETREGS
|
#undef PTRACE_GETREGS
|
||||||
#undef PTRACE_SETREGS
|
#undef PTRACE_SETREGS
|
||||||
#undef PTRACE_GETFPREGS
|
#undef PTRACE_GETFPREGS
|
||||||
|
@ -41,7 +41,7 @@
|
|||||||
might return a large offset. Therefore we must not anymore test
|
might return a large offset. Therefore we must not anymore test
|
||||||
for < 0, but test for a real error by making sure the value in R0
|
for < 0, but test for a real error by making sure the value in R0
|
||||||
is a real error number. Linus said he will make sure the no syscall
|
is a real error number. Linus said he will make sure the no syscall
|
||||||
returns a value in -1 .. -4095 as a valid result so we can savely
|
returns a value in -1 .. -4095 as a valid result so we can safely
|
||||||
test with -4095. */
|
test with -4095. */
|
||||||
|
|
||||||
#define _IMM1 #-1
|
#define _IMM1 #-1
|
||||||
|
@ -102,7 +102,7 @@ weak_alias (__setcontext, setcontext)
|
|||||||
|
|
||||||
If this NOP word does not exist, FDE lookup just repeatedly finds
|
If this NOP word does not exist, FDE lookup just repeatedly finds
|
||||||
__setcontext's FDE in an infinite loop, due to the convention of using
|
__setcontext's FDE in an infinite loop, due to the convention of using
|
||||||
'address - 1' for FDE lookup. Modifiying/deleting the below
|
'address - 1' for FDE lookup. Modifying/deleting the below
|
||||||
__startcontext's FDE has no help on this. */
|
__startcontext's FDE has no help on this. */
|
||||||
|
|
||||||
nop
|
nop
|
||||||
|
@ -24,7 +24,7 @@
|
|||||||
#include <bits/wordsize.h>
|
#include <bits/wordsize.h>
|
||||||
|
|
||||||
/* Linux/SPARC kernels up to 2.3.18 do not care much
|
/* Linux/SPARC kernels up to 2.3.18 do not care much
|
||||||
about what namespace polution, so use a kludge now. */
|
about what namespace pollution, so use a kludge now. */
|
||||||
#undef PTRACE_GETREGS
|
#undef PTRACE_GETREGS
|
||||||
#undef PTRACE_SETREGS
|
#undef PTRACE_SETREGS
|
||||||
#undef PTRACE_GETFPREGS
|
#undef PTRACE_GETFPREGS
|
||||||
|
@ -164,7 +164,7 @@ typedef greg_t gregset_t[__NGREG];
|
|||||||
* The following structures define how a register window can appear on the
|
* The following structures define how a register window can appear on the
|
||||||
* stack. This structure is available (when required) through the `gwins'
|
* stack. This structure is available (when required) through the `gwins'
|
||||||
* field of an mcontext (nested within ucontext). SPARC_MAXWINDOW is the
|
* field of an mcontext (nested within ucontext). SPARC_MAXWINDOW is the
|
||||||
* maximum number of outstanding regiters window defined in the SPARC
|
* maximum number of outstanding registers window defined in the SPARC
|
||||||
* architecture (*not* implementation).
|
* architecture (*not* implementation).
|
||||||
*/
|
*/
|
||||||
# define __SPARC_MAXREGWINDOW 31 /* max windows in SPARC arch. */
|
# define __SPARC_MAXREGWINDOW 31 /* max windows in SPARC arch. */
|
||||||
@ -200,7 +200,7 @@ typedef struct
|
|||||||
/*
|
/*
|
||||||
* struct fq defines the minimal format of a floating point instruction queue
|
* struct fq defines the minimal format of a floating point instruction queue
|
||||||
* entry. The size of entries in the floating point queue are implementation
|
* entry. The size of entries in the floating point queue are implementation
|
||||||
* dependent. The union FQu is guarenteed to be the first field in any ABI
|
* dependent. The union FQu is guaranteed to be the first field in any ABI
|
||||||
* conformant system implementation. Any additional fields provided by an
|
* conformant system implementation. Any additional fields provided by an
|
||||||
* implementation should not be used applications designed to be ABI conformant. */
|
* implementation should not be used applications designed to be ABI conformant. */
|
||||||
|
|
||||||
|
@ -203,7 +203,7 @@ __spawni_child (void *arguments)
|
|||||||
{
|
{
|
||||||
/* POSIX states that if fildes was already an open file descriptor,
|
/* POSIX states that if fildes was already an open file descriptor,
|
||||||
it shall be closed before the new file is opened. This avoid
|
it shall be closed before the new file is opened. This avoid
|
||||||
pontential issues when posix_spawn plus addopen action is called
|
potential issues when posix_spawn plus addopen action is called
|
||||||
with the process already at maximum number of file descriptor
|
with the process already at maximum number of file descriptor
|
||||||
opened and also for multiple actions on single-open special
|
opened and also for multiple actions on single-open special
|
||||||
paths (like /dev/watchdog). */
|
paths (like /dev/watchdog). */
|
||||||
@ -325,7 +325,7 @@ __spawnix (pid_t * pid, const char *file,
|
|||||||
ptrdiff_t argc = 0;
|
ptrdiff_t argc = 0;
|
||||||
/* Linux allows at most max (0x7FFFFFFF, 1/4 stack size) arguments
|
/* Linux allows at most max (0x7FFFFFFF, 1/4 stack size) arguments
|
||||||
to be used in a execve call. We limit to INT_MAX minus one due the
|
to be used in a execve call. We limit to INT_MAX minus one due the
|
||||||
compatiblity code that may execute a shell script (maybe_script_execute)
|
compatibility code that may execute a shell script (maybe_script_execute)
|
||||||
where it will construct another argument list with an additional
|
where it will construct another argument list with an additional
|
||||||
argument. */
|
argument. */
|
||||||
ptrdiff_t limit = INT_MAX - 1;
|
ptrdiff_t limit = INT_MAX - 1;
|
||||||
|
@ -70,7 +70,7 @@
|
|||||||
Some tests assume "/bin/sh" names a file that exists and is not a
|
Some tests assume "/bin/sh" names a file that exists and is not a
|
||||||
directory. */
|
directory. */
|
||||||
|
|
||||||
/* Evalutes to the arguments in a list initializer which can be used
|
/* Evaluates to the arguments in a list initializer which can be used
|
||||||
as a single macro argument. */
|
as a single macro argument. */
|
||||||
#define LIST(...) { __VA_ARGS__ }
|
#define LIST(...) { __VA_ARGS__ }
|
||||||
|
|
||||||
|
@ -89,7 +89,7 @@ do_test_with_offset (off_t offset)
|
|||||||
FAIL_EXIT1 ("fail trying to read " XSTR (BLK_SIZE) " bytes");
|
FAIL_EXIT1 ("fail trying to read " XSTR (BLK_SIZE) " bytes");
|
||||||
|
|
||||||
if (memcmp (bwrite, bread, BLK_SIZE) != 0)
|
if (memcmp (bwrite, bread, BLK_SIZE) != 0)
|
||||||
FAIL_EXIT1 ("buffer written different than buffer readed");
|
FAIL_EXIT1 ("buffer written different from buffer read");
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -55,7 +55,7 @@ probe_lock (void)
|
|||||||
*shared_errno = -1;
|
*shared_errno = -1;
|
||||||
support_isolate_in_subprocess (subprocess, NULL);
|
support_isolate_in_subprocess (subprocess, NULL);
|
||||||
if (*shared_errno == 0)
|
if (*shared_errno == 0)
|
||||||
/* Lock was aquired by the subprocess, so this process has not
|
/* Lock was acquired by the subprocess, so this process has not
|
||||||
locked it. */
|
locked it. */
|
||||||
return false;
|
return false;
|
||||||
else
|
else
|
||||||
|
@ -60,7 +60,7 @@ do_test (void)
|
|||||||
int fd = open64 (temp_filename, O_RDWR, 0666);
|
int fd = open64 (temp_filename, O_RDWR, 0666);
|
||||||
TEST_VERIFY_EXIT (fd != -1);
|
TEST_VERIFY_EXIT (fd != -1);
|
||||||
|
|
||||||
/* It tries then to allocate another open file descriptior with a valid
|
/* It tries then to allocate another open file descriptor with a valid
|
||||||
non-LFS bits struct flock but which will result in a conflicted region
|
non-LFS bits struct flock but which will result in a conflicted region
|
||||||
which can not be represented in a non-LFS struct flock. */
|
which can not be represented in a non-LFS struct flock. */
|
||||||
struct flock lck = {
|
struct flock lck = {
|
||||||
|
@ -61,7 +61,7 @@ do_test (void)
|
|||||||
int pidfd = pidfd_open (pid, 0);
|
int pidfd = pidfd_open (pid, 0);
|
||||||
TEST_VERIFY (pidfd != -1);
|
TEST_VERIFY (pidfd != -1);
|
||||||
|
|
||||||
/* The syscall only succeedes if the target process is exiting and there
|
/* The syscall only succeeds if the target process is exiting and there
|
||||||
is no guarantee that calling if after pidfd_send_signal will not error
|
is no guarantee that calling if after pidfd_send_signal will not error
|
||||||
(ince the process might have already been reaped by the OS). So just
|
(ince the process might have already been reaped by the OS). So just
|
||||||
check if it does fail when the process is stll running. */
|
check if it does fail when the process is stll running. */
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
|
|
||||||
/* This file is included by the tst-affinity*.c files to test the two
|
/* This file is included by the tst-affinity*.c files to test the two
|
||||||
variants of the functions, under different conditions. The
|
variants of the functions, under different conditions. The
|
||||||
following functions have to be definied:
|
following functions have to be defined:
|
||||||
|
|
||||||
static int getaffinity (size_t, cpu_set_t *);
|
static int getaffinity (size_t, cpu_set_t *);
|
||||||
static int setaffinity (size_t, const cpu_set_t *);
|
static int setaffinity (size_t, const cpu_set_t *);
|
||||||
|
@ -77,7 +77,7 @@ static void
|
|||||||
do_test_large_buffer (bool mc)
|
do_test_large_buffer (bool mc)
|
||||||
{
|
{
|
||||||
struct mmsghdr mmhdr = { 0 };
|
struct mmsghdr mmhdr = { 0 };
|
||||||
/* It should be large enought for either timeval/timespec and the
|
/* It should be large enough for either timeval/timespec and the
|
||||||
64 time type as well. */
|
64 time type as well. */
|
||||||
|
|
||||||
union
|
union
|
||||||
@ -142,7 +142,7 @@ do_test_large_buffer (bool mc)
|
|||||||
|
|
||||||
/* Check if recvmsg does not create the additional 64 bit timestamp if
|
/* Check if recvmsg does not create the additional 64 bit timestamp if
|
||||||
only 32 bit timestamp is enabled if the ancillary buffer is not large
|
only 32 bit timestamp is enabled if the ancillary buffer is not large
|
||||||
enought. Also checks if MSG_CTRUNC is set iff for 64 bit recvmsg
|
enough. Also checks if MSG_CTRUNC is set iff for 64 bit recvmsg
|
||||||
symbol. */
|
symbol. */
|
||||||
static void
|
static void
|
||||||
do_test_small_buffer (bool mc)
|
do_test_small_buffer (bool mc)
|
||||||
|
@ -284,7 +284,7 @@ do_test_multiple_ancillary (void)
|
|||||||
TEST_VERIFY_EXIT (r != -1);
|
TEST_VERIFY_EXIT (r != -1);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Enougth data for default SO_TIMESTAMP, the IP_RECVORIGDSTADDR, and the
|
/* Enough data for default SO_TIMESTAMP, the IP_RECVORIGDSTADDR, and the
|
||||||
extra 64-bit SO_TIMESTAMP. */
|
extra 64-bit SO_TIMESTAMP. */
|
||||||
enum { msgbuflen = CMSG_SPACE (2 * sizeof (uint64_t))
|
enum { msgbuflen = CMSG_SPACE (2 * sizeof (uint64_t))
|
||||||
+ CMSG_SPACE (sizeof (struct sockaddr_in))
|
+ CMSG_SPACE (sizeof (struct sockaddr_in))
|
||||||
|
@ -55,7 +55,7 @@ struct test_msginfo
|
|||||||
int msgmni;
|
int msgmni;
|
||||||
};
|
};
|
||||||
|
|
||||||
/* It tries to obtain some system-wide SysV messsage queue information from
|
/* It tries to obtain some system-wide SysV message queue information from
|
||||||
/proc to check against IPC_INFO/MSG_INFO. The /proc only returns the
|
/proc to check against IPC_INFO/MSG_INFO. The /proc only returns the
|
||||||
tunables value of MSGMAX, MSGMNB, and MSGMNI.
|
tunables value of MSGMAX, MSGMNB, and MSGMNI.
|
||||||
|
|
||||||
|
@ -66,7 +66,7 @@ subprocess (void *closure)
|
|||||||
{
|
{
|
||||||
int original_tid = expected_signal_tid;
|
int original_tid = expected_signal_tid;
|
||||||
|
|
||||||
/* Do not expect that the folloing signals are delivered to the
|
/* Do not expect that the following signals are delivered to the
|
||||||
subprocess. The parent process retains the original
|
subprocess. The parent process retains the original
|
||||||
expected_signal_tid value. */
|
expected_signal_tid value. */
|
||||||
expected_signal_tid = 0;
|
expected_signal_tid = 0;
|
||||||
@ -77,7 +77,7 @@ subprocess (void *closure)
|
|||||||
TEST_COMPARE (expected_signal_tid, 0);
|
TEST_COMPARE (expected_signal_tid, 0);
|
||||||
|
|
||||||
/* This call has the correct PID/TID combination and is therefore
|
/* This call has the correct PID/TID combination and is therefore
|
||||||
expected to suceed. */
|
expected to succeed. */
|
||||||
TEST_COMPARE (tgkill (getppid (), original_tid, SIGUSR1), 0);
|
TEST_COMPARE (tgkill (getppid (), original_tid, SIGUSR1), 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -508,7 +508,7 @@ run_chroot_tests (const char *slavename, int slave)
|
|||||||
char *linkname = xasprintf ("/proc/self/fd/%d", slave);
|
char *linkname = xasprintf ("/proc/self/fd/%d", slave);
|
||||||
char *target = proc_fd_readlink (linkname);
|
char *target = proc_fd_readlink (linkname);
|
||||||
free (linkname);
|
free (linkname);
|
||||||
/* Depeding on how we set up the chroot, the kernel may or may not
|
/* Depending on how we set up the chroot, the kernel may or may not
|
||||||
trim the leading path to the target (it may give us "/6",
|
trim the leading path to the target (it may give us "/6",
|
||||||
instead of "/dev/pts/6"). We test it both ways (do_in_chroot_1
|
instead of "/dev/pts/6"). We test it both ways (do_in_chroot_1
|
||||||
and do_in_chroot_2). This test group relies on the target
|
and do_in_chroot_2). This test group relies on the target
|
||||||
|
@ -49,7 +49,7 @@ struct elision_config __elision_aconf =
|
|||||||
static __always_inline void
|
static __always_inline void
|
||||||
do_set_elision_enable (int32_t elision_enable)
|
do_set_elision_enable (int32_t elision_enable)
|
||||||
{
|
{
|
||||||
/* Enable elision if it's avaliable in hardware. It's not necessary to check
|
/* Enable elision if it's available in hardware. It's not necessary to check
|
||||||
if __libc_enable_secure isn't enabled since elision_enable will be set
|
if __libc_enable_secure isn't enabled since elision_enable will be set
|
||||||
according to the default, which is disabled. */
|
according to the default, which is disabled. */
|
||||||
if (elision_enable == 1)
|
if (elision_enable == 1)
|
||||||
|
@ -43,7 +43,7 @@
|
|||||||
might return a large offset. Therefore we must not anymore test
|
might return a large offset. Therefore we must not anymore test
|
||||||
for < 0, but test for a real error by making sure the value in %eax
|
for < 0, but test for a real error by making sure the value in %eax
|
||||||
is a real error number. Linus said he will make sure the no syscall
|
is a real error number. Linus said he will make sure the no syscall
|
||||||
returns a value in -1 .. -4095 as a valid result so we can savely
|
returns a value in -1 .. -4095 as a valid result so we can safely
|
||||||
test with -4095. */
|
test with -4095. */
|
||||||
|
|
||||||
/* We don't want the label for the error handle to be global when we define
|
/* We don't want the label for the error handle to be global when we define
|
||||||
|
Reference in New Issue
Block a user