All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] ptrace: do some cleanup
@ 2022-04-06 10:29 Tiezhu Yang
  2022-04-06 10:29 ` [PATCH 1/3] ptrace: Remove redudant check of #ifdef PTRACE_SINGLESTEP Tiezhu Yang
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Tiezhu Yang @ 2022-04-06 10:29 UTC (permalink / raw)
  To: Oleg Nesterov, Andrew Morton; +Cc: linux-kernel

Tiezhu Yang (3):
  ptrace: Remove redudant check of #ifdef PTRACE_SINGLESTEP
  ptrace: Fix wrong comment of PT_DTRACE
  MAINTAINERS: Remove redundant file of PTRACE SUPPORT entry

 MAINTAINERS            | 1 -
 include/linux/ptrace.h | 2 +-
 kernel/ptrace.c        | 6 ------
 3 files changed, 1 insertion(+), 8 deletions(-)

-- 
2.1.0


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH 1/3] ptrace: Remove redudant check of #ifdef PTRACE_SINGLESTEP
  2022-04-06 10:29 [PATCH 0/3] ptrace: do some cleanup Tiezhu Yang
@ 2022-04-06 10:29 ` Tiezhu Yang
  2022-04-06 10:29 ` [PATCH 2/3] ptrace: Fix wrong comment of PT_DTRACE Tiezhu Yang
  2022-04-06 10:29 ` [PATCH 3/3] MAINTAINERS: Remove redundant file of PTRACE SUPPORT entry Tiezhu Yang
  2 siblings, 0 replies; 4+ messages in thread
From: Tiezhu Yang @ 2022-04-06 10:29 UTC (permalink / raw)
  To: Oleg Nesterov, Andrew Morton; +Cc: linux-kernel

PTRACE_SINGLESTEP is always defined as 9 in include/uapi/linux/ptrace.h,
remove redudant check of #ifdef PTRACE_SINGLESTEP.

Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>
---
 kernel/ptrace.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/kernel/ptrace.c b/kernel/ptrace.c
index ccc4b46..49c29ba 100644
--- a/kernel/ptrace.c
+++ b/kernel/ptrace.c
@@ -829,11 +829,7 @@ static long ptrace_get_rseq_configuration(struct task_struct *task,
 }
 #endif
 
-#ifdef PTRACE_SINGLESTEP
 #define is_singlestep(request)		((request) == PTRACE_SINGLESTEP)
-#else
-#define is_singlestep(request)		0
-#endif
 
 #ifdef PTRACE_SINGLEBLOCK
 #define is_singleblock(request)		((request) == PTRACE_SINGLEBLOCK)
@@ -1221,9 +1217,7 @@ int ptrace_request(struct task_struct *child, long request,
 	}
 #endif
 
-#ifdef PTRACE_SINGLESTEP
 	case PTRACE_SINGLESTEP:
-#endif
 #ifdef PTRACE_SINGLEBLOCK
 	case PTRACE_SINGLEBLOCK:
 #endif
-- 
2.1.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH 2/3] ptrace: Fix wrong comment of PT_DTRACE
  2022-04-06 10:29 [PATCH 0/3] ptrace: do some cleanup Tiezhu Yang
  2022-04-06 10:29 ` [PATCH 1/3] ptrace: Remove redudant check of #ifdef PTRACE_SINGLESTEP Tiezhu Yang
@ 2022-04-06 10:29 ` Tiezhu Yang
  2022-04-06 10:29 ` [PATCH 3/3] MAINTAINERS: Remove redundant file of PTRACE SUPPORT entry Tiezhu Yang
  2 siblings, 0 replies; 4+ messages in thread
From: Tiezhu Yang @ 2022-04-06 10:29 UTC (permalink / raw)
  To: Oleg Nesterov, Andrew Morton; +Cc: linux-kernel

PT_DTRACE is only used on um now, fix the wrong comment.

Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>
---
 include/linux/ptrace.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/linux/ptrace.h b/include/linux/ptrace.h
index 15b3d17..db45095 100644
--- a/include/linux/ptrace.h
+++ b/include/linux/ptrace.h
@@ -30,7 +30,7 @@ extern int ptrace_access_vm(struct task_struct *tsk, unsigned long addr,
 
 #define PT_SEIZED	0x00010000	/* SEIZE used, enable new behavior */
 #define PT_PTRACED	0x00000001
-#define PT_DTRACE	0x00000002	/* delayed trace (used on m68k, i386) */
+#define PT_DTRACE	0x00000002	/* delayed trace (used on um) */
 
 #define PT_OPT_FLAG_SHIFT	3
 /* PT_TRACE_* event enable flags */
-- 
2.1.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH 3/3] MAINTAINERS: Remove redundant file of PTRACE SUPPORT entry
  2022-04-06 10:29 [PATCH 0/3] ptrace: do some cleanup Tiezhu Yang
  2022-04-06 10:29 ` [PATCH 1/3] ptrace: Remove redudant check of #ifdef PTRACE_SINGLESTEP Tiezhu Yang
  2022-04-06 10:29 ` [PATCH 2/3] ptrace: Fix wrong comment of PT_DTRACE Tiezhu Yang
@ 2022-04-06 10:29 ` Tiezhu Yang
  2 siblings, 0 replies; 4+ messages in thread
From: Tiezhu Yang @ 2022-04-06 10:29 UTC (permalink / raw)
  To: Oleg Nesterov, Andrew Morton; +Cc: linux-kernel

In MAINTAINERS PTRACE SUPPORT entry, the file include/uapi/linux/ptrace.h
is redundant, remove it.

Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>
---
 MAINTAINERS | 1 -
 1 file changed, 1 deletion(-)

diff --git a/MAINTAINERS b/MAINTAINERS
index fd768d4..881e3ea 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -15959,7 +15959,6 @@ F:	include/asm-generic/syscall.h
 F:	include/linux/ptrace.h
 F:	include/linux/regset.h
 F:	include/uapi/linux/ptrace.h
-F:	include/uapi/linux/ptrace.h
 F:	kernel/ptrace.c
 
 PULSE8-CEC DRIVER
-- 
2.1.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-04-06 14:28 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-06 10:29 [PATCH 0/3] ptrace: do some cleanup Tiezhu Yang
2022-04-06 10:29 ` [PATCH 1/3] ptrace: Remove redudant check of #ifdef PTRACE_SINGLESTEP Tiezhu Yang
2022-04-06 10:29 ` [PATCH 2/3] ptrace: Fix wrong comment of PT_DTRACE Tiezhu Yang
2022-04-06 10:29 ` [PATCH 3/3] MAINTAINERS: Remove redundant file of PTRACE SUPPORT entry Tiezhu Yang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.