Thread (5 messages) 5 messages, 3 authors, 2023-02-21

Re: [PATCH 2/2] ptrace,syscall_user_dispatch: checkpoint/restore support for SUD

From: Oleg Nesterov <oleg@redhat.com>
Date: 2023-02-16 13:58:36
Also in: lkml

On 02/14, Gregory Price wrote:
+struct compat_ptrace_sud_config {
+        compat_ulong_t mode;
+        compat_uptr_t selector;
+        compat_ulong_t offset;
+        compat_ulong_t len;
+};
...
+int syscall_user_dispatch_get_config(struct task_struct *task, unsigned long size,
+		                     void __user *data)
+{
+	struct syscall_user_dispatch *sd = &task->syscall_dispatch;
+#ifdef CONFIG_COMPAT
+	if (unlikely(in_compat_syscall())) {
+		struct compat_ptrace_sud_config cfg32;
+
+		if (size != sizeof(struct compat_ptrace_sud_config))
+			return -EINVAL;
+
Horror ;) why?

See my reply to v9, just make

	struct ptrace_sud_config {
		__u8  mode;
		__u64 selector;
		__u64 offset;
		__u64 len;
	};

Oleg.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help