sparc, sparc64: implement kern_features decoder
* sparc.c: New file. * Makefile.am (EXTRA_DIST): Add it. * linux/sparc/syscallent.h ([340]): Remove NF flag, set kern_features decoder. * linux/sparc64/syscallent.h ([340]): Likewise. * xlat/sparc_kern_features.in: New file. * NEWS: Mention this enhancement. Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
This commit is contained in:
parent
dfc59e7061
commit
b46d5b8caf
@ -293,6 +293,7 @@ strace_SOURCES = \
|
||||
sock.c \
|
||||
sockaddr.c \
|
||||
socketutils.c \
|
||||
sparc.c \
|
||||
sram_alloc.c \
|
||||
stat.c \
|
||||
stat.h \
|
||||
|
1
NEWS
1
NEWS
@ -23,6 +23,7 @@ Noteworthy changes in release ?.?? (????-??-??)
|
||||
* Implemented block/character device number printing in -yy mode.
|
||||
* Known pixel/SDR format names are printed as comments for pixelformat fields
|
||||
in v4l2 structures.
|
||||
* Enhanced decoding of kern_features syscall.
|
||||
|
||||
* Bug fixes
|
||||
* Fixed build on m68k.
|
||||
|
@ -338,7 +338,7 @@
|
||||
[337] = { 2, TD, SEN(setns), "setns" },
|
||||
[338] = { 6, 0, SEN(process_vm_readv), "process_vm_readv" },
|
||||
[339] = { 6, 0, SEN(process_vm_writev), "process_vm_writev" },
|
||||
[340] = { 0, PU|NF, SEN(printargs), "kern_features" },
|
||||
[340] = { 0, PU, SEN(kern_features), "kern_features" },
|
||||
[341] = { 5, 0, SEN(kcmp), "kcmp" },
|
||||
[342] = { 3, TD, SEN(finit_module), "finit_module" },
|
||||
[343] = { 3, 0, SEN(sched_setattr), "sched_setattr" },
|
||||
|
@ -336,7 +336,7 @@
|
||||
[337] = { 2, TD, SEN(setns), "setns" },
|
||||
[338] = { 6, 0, SEN(process_vm_readv), "process_vm_readv" },
|
||||
[339] = { 6, 0, SEN(process_vm_writev), "process_vm_writev" },
|
||||
[340] = { 0, PU|NF, SEN(printargs), "kern_features" },
|
||||
[340] = { 0, PU, SEN(kern_features), "kern_features" },
|
||||
[341] = { 5, 0, SEN(kcmp), "kcmp" },
|
||||
[342] = { 3, TD, SEN(finit_module), "finit_module" },
|
||||
[343] = { 3, 0, SEN(sched_setattr), "sched_setattr" },
|
||||
|
46
sparc.c
Normal file
46
sparc.c
Normal file
@ -0,0 +1,46 @@
|
||||
/*
|
||||
* SPARC-specific syscall decoders.
|
||||
*
|
||||
* Copyright (c) 2018 The strace developers.
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
* are met:
|
||||
* 1. Redistributions of source code must retain the above copyright
|
||||
* notice, this list of conditions and the following disclaimer.
|
||||
* 2. Redistributions in binary form must reproduce the above copyright
|
||||
* notice, this list of conditions and the following disclaimer in the
|
||||
* documentation and/or other materials provided with the distribution.
|
||||
* 3. The name of the author may not be used to endorse or promote products
|
||||
* derived from this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
|
||||
* NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
||||
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#include "defs.h"
|
||||
|
||||
#if defined SPARC || defined SPARC64
|
||||
|
||||
# include "xlat/sparc_kern_features.h"
|
||||
|
||||
SYS_FUNC(kern_features)
|
||||
{
|
||||
if (entering(tcp) || syserror(tcp))
|
||||
return 0;
|
||||
|
||||
tcp->auxstr = sprintflags("", sparc_kern_features,
|
||||
(kernel_ulong_t) tcp->u_rval);
|
||||
return RVAL_HEX | RVAL_STR;
|
||||
}
|
||||
|
||||
#endif /* SPARC || SPARC64 */
|
1
xlat/sparc_kern_features.in
Normal file
1
xlat/sparc_kern_features.in
Normal file
@ -0,0 +1 @@
|
||||
KERN_FEATURE_MIXED_MODE_STACK 1
|
Loading…
x
Reference in New Issue
Block a user