From nobody Sat Feb 7 08:28:18 2026 Received: from out0-206.mail.aliyun.com (out0-206.mail.aliyun.com [140.205.0.206]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 62F9416F27C for ; Fri, 16 Aug 2024 10:00:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.205.0.206 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723802410; cv=none; b=Lq5kG8saiP6oVK7F8tQ9zKlK2N9321joPWkU8bDpxJl+CTHE06N74q3JGOo/gEP4Xx4pL4MHj3lZe3CkhwoHtIlMBeqcwckWsjhfPqtDaAloQr5G3IkdlwyAU0DVlb3IfWsBNmDLnw00R8MRzicGmarp0nIZ/oqkK5F9F7buNrc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723802410; c=relaxed/simple; bh=xUHAMMt5CPV43RQEHQURLk5SuPKB5Ii2393sz9l5A1s=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=V/0Gw19iF9vlHLhU92OSlKhxiyJLh6zpx7b+vPUxhKUwBdYuTfNNw7+1TaGpYSvSq/HATn6HIBrOeels5EPY80P/OvJx+PxQxtrkmdVmCCdTXmWX9E0Uut9EnvJS6uuBVj6dggyGXovbtWz7+IxBj5C6Rt24nYHbKHXGAjShRQY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com; spf=pass smtp.mailfrom=antgroup.com; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b=adjnjQ68; arc=none smtp.client-ip=140.205.0.206 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=antgroup.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b="adjnjQ68" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=antgroup.com; s=default; t=1723802404; h=From:To:Subject:Date:Message-Id:MIME-Version; bh=Z/OyflIhDj1OPlK2j8cfY/ptojYdSEITrCVMmB0cw4o=; b=adjnjQ68S4z7BtDLveJKwG0T6BpaEDnpobmx9AqsYXfBJLfpUO6/Kf8BHfuyPXCpqPWbtjEa7DPy/bVEogp9KaKFnHVcBFCO3O4FpYTcMr+pW9/I5xYo+EIaJ2JNdC5CeablQNmjAo1CouoagD+SYbuFO7NO9t5S1Tlbjyjk2bY= Received: from ubuntu..(mailfrom:tiwei.btw@antgroup.com fp:SMTPD_---.YtmFE3v_1723802403) by smtp.aliyun-inc.com; Fri, 16 Aug 2024 18:00:03 +0800 From: "Tiwei Bie" To: richard@nod.at, anton.ivanov@cambridgegreys.com, johannes@sipsolutions.net Cc: , , "Tiwei Bie" Subject: [PATCH v2 1/6] um: Remove unused kpte_clear_flush macro Date: Fri, 16 Aug 2024 17:59:48 +0800 Message-Id: <20240816095953.638401-2-tiwei.btw@antgroup.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240816095953.638401-1-tiwei.btw@antgroup.com> References: <20240816095953.638401-1-tiwei.btw@antgroup.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" This macro has no users, and __flush_tlb_one doesn't exist either. Signed-off-by: Tiwei Bie --- arch/um/include/asm/pgtable.h | 7 ------- 1 file changed, 7 deletions(-) diff --git a/arch/um/include/asm/pgtable.h b/arch/um/include/asm/pgtable.h index 5bb397b65efb..83373c9963e7 100644 --- a/arch/um/include/asm/pgtable.h +++ b/arch/um/include/asm/pgtable.h @@ -359,11 +359,4 @@ static inline pte_t pte_swp_clear_exclusive(pte_t pte) return pte; } =20 -/* Clear a kernel PTE and flush it from the TLB */ -#define kpte_clear_flush(ptep, vaddr) \ -do { \ - pte_clear(&init_mm, (vaddr), (ptep)); \ - __flush_tlb_one((vaddr)); \ -} while (0) - #endif --=20 2.34.1 From nobody Sat Feb 7 08:28:18 2026 Received: from out187-18.us.a.mail.aliyun.com (out187-18.us.a.mail.aliyun.com [47.90.187.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3B08C16F85B for ; Fri, 16 Aug 2024 10:00:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=47.90.187.18 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723802418; cv=none; b=rda/OGybUWcKzIxZdsOLOl9ikTR4cCxLss/XHUTFOXZn79yhDj69OHVjBtHvOxpSPerOpjm/tHdUtxTdyRBBLPrXfg+WmAeluMkBYGQQvuHgiJ6jsB6/3qrBvwm3hLJqTLLtQQtzkcQznghnIIy0FvjQ1wLKdxsK3It0SDRcbmE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723802418; c=relaxed/simple; bh=vrr0pFgKlFH8zr7+GGp+kmqkEdG880bRycdUnGqf6EE=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=S8cw3E2Xq0Vbjg462WW5hrsyn1mA+P42hwob0niygBaSUQJFrBxum4bNFgWXDWnrev84pCeQRE6AdPnF6wjd4ozUABK6FODm0Yr0eEWG47Qq9UMgykq00M0hI4xqDumfklFFk+zTUUwYn/OvrBg9Uhkyc6LTeIsFGEc8QXJ3PkY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com; spf=pass smtp.mailfrom=antgroup.com; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b=xPi7Vj3j; arc=none smtp.client-ip=47.90.187.18 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=antgroup.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b="xPi7Vj3j" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=antgroup.com; s=default; t=1723802404; h=From:To:Subject:Date:Message-Id:MIME-Version; bh=jo0r7PE2P21mYE53WxHNzNjxHnLxdNhP0Cu28IOO4aU=; b=xPi7Vj3jFV1eOeindJKlymWpzZI37w83WwzgR3pLdce5jDJfkIVu7ggVyjhKa6SQ73yn2wO+kld85ZQcIPlHPmHZ7KJlZ4Edck+JUfb6T47Go1cbhLHvRMGODiZwujbsEaUWc7F9mdV+6YoH5h8uUcxdanMgimLNuvPaGswBxA8= Received: from ubuntu..(mailfrom:tiwei.btw@antgroup.com fp:SMTPD_---.YtmFE5W_1723802403) by smtp.aliyun-inc.com; Fri, 16 Aug 2024 18:00:03 +0800 From: "Tiwei Bie" To: richard@nod.at, anton.ivanov@cambridgegreys.com, johannes@sipsolutions.net Cc: , , "Tiwei Bie" Subject: [PATCH v2 2/6] um: Remove the redundant newpage check in update_pte_range Date: Fri, 16 Aug 2024 17:59:49 +0800 Message-Id: <20240816095953.638401-3-tiwei.btw@antgroup.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240816095953.638401-1-tiwei.btw@antgroup.com> References: <20240816095953.638401-1-tiwei.btw@antgroup.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The two checks have been identical since commit ef714f15027c ("um: remove force_flush_all from fork_handler"). And the inner one isn't necessary anymore. Signed-off-by: Tiwei Bie --- arch/um/kernel/tlb.c | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/arch/um/kernel/tlb.c b/arch/um/kernel/tlb.c index 44c6fc697f3a..548af31d4111 100644 --- a/arch/um/kernel/tlb.c +++ b/arch/um/kernel/tlb.c @@ -82,16 +82,12 @@ static inline int update_pte_range(pmd_t *pmd, unsigned= long addr, (x ? UM_PROT_EXEC : 0)); if (pte_newpage(*pte)) { if (pte_present(*pte)) { - if (pte_newpage(*pte)) { - __u64 offset; - unsigned long phys =3D - pte_val(*pte) & PAGE_MASK; - int fd =3D phys_mapping(phys, &offset); - - ret =3D ops->mmap(ops->mm_idp, addr, - PAGE_SIZE, prot, fd, - offset); - } + __u64 offset; + unsigned long phys =3D pte_val(*pte) & PAGE_MASK; + int fd =3D phys_mapping(phys, &offset); + + ret =3D ops->mmap(ops->mm_idp, addr, PAGE_SIZE, + prot, fd, offset); } else ret =3D ops->unmap(ops->mm_idp, addr, PAGE_SIZE); } else if (pte_newprot(*pte)) --=20 2.34.1 From nobody Sat Feb 7 08:28:18 2026 Received: from out187-6.us.a.mail.aliyun.com (out187-6.us.a.mail.aliyun.com [47.90.187.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4895685270 for ; Fri, 16 Aug 2024 10:00:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=47.90.187.6 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723802419; cv=none; b=p8/YdT8stvfmsBMTyGeMRbK1mamd+H6J9paDGfXPlY3kwsMmDVIyaX890EwXiSVqA3eOXeR0Aipc5LIfa0UAuzNJBfYOUCESd8C7Pecc2l19RsMBkP7iyGdAEnYm3PFlKHFLripNy6e8EVBsF6HoEaUDNPIQam/ErUSuXc3xK/E= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723802419; c=relaxed/simple; bh=jstzTDlVaFc14MBs6+5CAn8bhr/f8VdzKJOixZsHUjk=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=nSSAOGp671hm3NH9xkjcaR7tK6JMwpe04g6h+r8LKCEnXC8hG51Y/SuLlEgZn7gT8g0mo/xxjCqz+OmLoJJLspCbFiDOuBaUjcsvFISzlze1Q471D3+FXX5njF5xqysSLInEQ9gDc5Jl7XqfOn1pFpskxGquQ30uGcq+Qg6s5nc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com; spf=pass smtp.mailfrom=antgroup.com; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b=hNA7I8vK; arc=none smtp.client-ip=47.90.187.6 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=antgroup.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b="hNA7I8vK" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=antgroup.com; s=default; t=1723802404; h=From:To:Subject:Date:Message-Id:MIME-Version; bh=EEFoEIJSD/Xa9nH/fAD+A50RNInexen/VIJS9zUQYhU=; b=hNA7I8vK5vzaWQXnqeoFkuScnm48iGc8xMyBB0gfSpks7fPkyMxrgaQK8KVRhblXirA2gArEgYRt3c1aK0CLezMCPfA7HvHiNUdHfp4MShlcNK19RiPyi14kdQEvMHNF3hd6EpmdhevwcxNetarSiUb+3jdWON9Mn47F7pYUAiw= Received: from ubuntu..(mailfrom:tiwei.btw@antgroup.com fp:SMTPD_---.YtmFE7M_1723802403) by smtp.aliyun-inc.com; Fri, 16 Aug 2024 18:00:04 +0800 From: "Tiwei Bie" To: richard@nod.at, anton.ivanov@cambridgegreys.com, johannes@sipsolutions.net Cc: , , "Tiwei Bie" Subject: [PATCH v2 3/6] um: Remove unused fields from thread_struct Date: Fri, 16 Aug 2024 17:59:50 +0800 Message-Id: <20240816095953.638401-4-tiwei.btw@antgroup.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240816095953.638401-1-tiwei.btw@antgroup.com> References: <20240816095953.638401-1-tiwei.btw@antgroup.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" These fields are no longer used since the removal of tt mode. Signed-off-by: Tiwei Bie --- arch/um/include/asm/processor-generic.h | 20 +++++--------------- arch/um/kernel/process.c | 8 ++++---- arch/um/kernel/skas/process.c | 4 ++-- 3 files changed, 11 insertions(+), 21 deletions(-) diff --git a/arch/um/include/asm/processor-generic.h b/arch/um/include/asm/= processor-generic.h index 5a7c05275aa7..bce4595798da 100644 --- a/arch/um/include/asm/processor-generic.h +++ b/arch/um/include/asm/processor-generic.h @@ -28,20 +28,10 @@ struct thread_struct { struct arch_thread arch; jmp_buf switch_buf; struct { - int op; - union { - struct { - int pid; - } fork, exec; - struct { - int (*proc)(void *); - void *arg; - } thread; - struct { - void (*proc)(void *); - void *arg; - } cb; - } u; + struct { + int (*proc)(void *); + void *arg; + } thread; } request; }; =20 @@ -51,7 +41,7 @@ struct thread_struct { .fault_addr =3D NULL, \ .prev_sched =3D NULL, \ .arch =3D INIT_ARCH_THREAD, \ - .request =3D { 0 } \ + .request =3D { } \ } =20 /* diff --git a/arch/um/kernel/process.c b/arch/um/kernel/process.c index f36b63f53bab..be2856af6d4c 100644 --- a/arch/um/kernel/process.c +++ b/arch/um/kernel/process.c @@ -109,8 +109,8 @@ void new_thread_handler(void) schedule_tail(current->thread.prev_sched); current->thread.prev_sched =3D NULL; =20 - fn =3D current->thread.request.u.thread.proc; - arg =3D current->thread.request.u.thread.arg; + fn =3D current->thread.request.thread.proc; + arg =3D current->thread.request.thread.arg; =20 /* * callback returns only if the kernel thread execs a process @@ -158,8 +158,8 @@ int copy_thread(struct task_struct * p, const struct ke= rnel_clone_args *args) arch_copy_thread(¤t->thread.arch, &p->thread.arch); } else { get_safe_registers(p->thread.regs.regs.gp, p->thread.regs.regs.fp); - p->thread.request.u.thread.proc =3D args->fn; - p->thread.request.u.thread.arg =3D args->fn_arg; + p->thread.request.thread.proc =3D args->fn; + p->thread.request.thread.arg =3D args->fn_arg; handler =3D new_thread_handler; } =20 diff --git a/arch/um/kernel/skas/process.c b/arch/um/kernel/skas/process.c index 5f9c1c5f36e2..68657988c8d1 100644 --- a/arch/um/kernel/skas/process.c +++ b/arch/um/kernel/skas/process.c @@ -39,8 +39,8 @@ int __init start_uml(void) =20 init_new_thread_signals(); =20 - init_task.thread.request.u.thread.proc =3D start_kernel_proc; - init_task.thread.request.u.thread.arg =3D NULL; + init_task.thread.request.thread.proc =3D start_kernel_proc; + init_task.thread.request.thread.arg =3D NULL; return start_idle_thread(task_stack_page(&init_task), &init_task.thread.switch_buf); } --=20 2.34.1 From nobody Sat Feb 7 08:28:18 2026 Received: from out0-220.mail.aliyun.com (out0-220.mail.aliyun.com [140.205.0.220]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 81EA416F8FD for ; Fri, 16 Aug 2024 10:00:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.205.0.220 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723802411; cv=none; b=UJ7+1Rtp97iC+nfEw65NsupIPNJdbw6gvIBIZzxQntecpkrWopWNsgZirfVknl1vznzbQfeEoZN5xNXZqcQ2EqEKaw0lQHpHf8K1RqUcuLiOyJpQQEAFXOAlQGfaY4+bVnYDOvgtoDrAXtkkbDAT4rSuqqemzLvFG2OOCpxdtBI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723802411; c=relaxed/simple; bh=4FD+5SkE/cCSHAkmiN5Kw23JtgoYUbJVodhVJ7Su8Bo=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=cpAeBKok+w9/I5Y/64xa1otNcA7OzVbbwQNOruDnX9JkODNhdKThSgJnMszD8eT4KsShZ94rAQ+YdA/coppAr3dVW+yjmgl8RWKWWDZwSIiLZQZSCUUSskLDqEpS7QjoAMr+yNu+2DCX2UBwXAkZ/Yd/9wY/xJS1v1bdoZsc7zY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com; spf=pass smtp.mailfrom=antgroup.com; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b=zl6c25Hp; arc=none smtp.client-ip=140.205.0.220 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=antgroup.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b="zl6c25Hp" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=antgroup.com; s=default; t=1723802405; h=From:To:Subject:Date:Message-Id:MIME-Version; bh=MIeh/tkxVuBeL/Hw9D50Dh+vi6krP1UrWPdznGMpxyA=; b=zl6c25HpNA8zuIv8MBJTy5Y/lppVz6PKHS65q7z8o8x/GhOKaG8eUNqYuixMhjB6T3ar/hS5azPjMa7NHII12OxjM5sJlY5yxZlswNLmWh5Bn+W36q4NYQiYfFbzNK3oeI3XnFJ9OVmwXOyQ0r7R0sDWA0Pdd+qtBkxxUAu6PVo= Received: from ubuntu..(mailfrom:tiwei.btw@antgroup.com fp:SMTPD_---.YtmFE8Z_1723802404) by smtp.aliyun-inc.com; Fri, 16 Aug 2024 18:00:04 +0800 From: "Tiwei Bie" To: richard@nod.at, anton.ivanov@cambridgegreys.com, johannes@sipsolutions.net Cc: , , "Tiwei Bie" Subject: [PATCH v2 4/6] um: Remove unused mm_fd field from mm_id Date: Fri, 16 Aug 2024 17:59:51 +0800 Message-Id: <20240816095953.638401-5-tiwei.btw@antgroup.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240816095953.638401-1-tiwei.btw@antgroup.com> References: <20240816095953.638401-1-tiwei.btw@antgroup.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" It's no longer used since the removal of the SKAS3/4 support. Signed-off-by: Tiwei Bie --- arch/um/include/shared/skas/mm_id.h | 5 +---- arch/um/kernel/reboot.c | 2 +- arch/um/kernel/skas/mmu.c | 12 ++++++------ arch/um/kernel/time.c | 2 +- arch/um/os-Linux/skas/mem.c | 2 +- arch/um/os-Linux/skas/process.c | 2 +- 6 files changed, 11 insertions(+), 14 deletions(-) diff --git a/arch/um/include/shared/skas/mm_id.h b/arch/um/include/shared/s= kas/mm_id.h index 1e76ba40feba..140388c282f6 100644 --- a/arch/um/include/shared/skas/mm_id.h +++ b/arch/um/include/shared/skas/mm_id.h @@ -7,10 +7,7 @@ #define __MM_ID_H =20 struct mm_id { - union { - int mm_fd; - int pid; - } u; + int pid; unsigned long stack; int syscall_data_len; }; diff --git a/arch/um/kernel/reboot.c b/arch/um/kernel/reboot.c index 3736bca626ba..680bce4bd8fa 100644 --- a/arch/um/kernel/reboot.c +++ b/arch/um/kernel/reboot.c @@ -29,7 +29,7 @@ static void kill_off_processes(void) t =3D find_lock_task_mm(p); if (!t) continue; - pid =3D t->mm->context.id.u.pid; + pid =3D t->mm->context.id.pid; task_unlock(t); os_kill_ptraced_process(pid, 1); } diff --git a/arch/um/kernel/skas/mmu.c b/arch/um/kernel/skas/mmu.c index 47f98d87ea3c..886ed5e65674 100644 --- a/arch/um/kernel/skas/mmu.c +++ b/arch/um/kernel/skas/mmu.c @@ -32,11 +32,11 @@ int init_new_context(struct task_struct *task, struct m= m_struct *mm) new_id->stack =3D stack; =20 block_signals_trace(); - new_id->u.pid =3D start_userspace(stack); + new_id->pid =3D start_userspace(stack); unblock_signals_trace(); =20 - if (new_id->u.pid < 0) { - ret =3D new_id->u.pid; + if (new_id->pid < 0) { + ret =3D new_id->pid; goto out_free; } =20 @@ -83,12 +83,12 @@ void destroy_context(struct mm_struct *mm) * whole UML suddenly dying. Also, cover negative and * 1 cases, since they shouldn't happen either. */ - if (mmu->id.u.pid < 2) { + if (mmu->id.pid < 2) { printk(KERN_ERR "corrupt mm_context - pid =3D %d\n", - mmu->id.u.pid); + mmu->id.pid); return; } - os_kill_ptraced_process(mmu->id.u.pid, 1); + os_kill_ptraced_process(mmu->id.pid, 1); =20 free_pages(mmu->id.stack, ilog2(STUB_DATA_PAGES)); } diff --git a/arch/um/kernel/time.c b/arch/um/kernel/time.c index 47b9f5e63566..29b27b90581f 100644 --- a/arch/um/kernel/time.c +++ b/arch/um/kernel/time.c @@ -839,7 +839,7 @@ static irqreturn_t um_timer(int irq, void *dev) if (get_current()->mm !=3D NULL) { /* userspace - relay signal, results in correct userspace timers */ - os_alarm_process(get_current()->mm->context.id.u.pid); + os_alarm_process(get_current()->mm->context.id.pid); } =20 (*timer_clockevent.event_handler)(&timer_clockevent); diff --git a/arch/um/os-Linux/skas/mem.c b/arch/um/os-Linux/skas/mem.c index c55430775efd..9a13ac23c606 100644 --- a/arch/um/os-Linux/skas/mem.c +++ b/arch/um/os-Linux/skas/mem.c @@ -78,7 +78,7 @@ static inline long do_syscall_stub(struct mm_id *mm_idp) { struct stub_data *proc_data =3D (void *)mm_idp->stack; int n, i; - int err, pid =3D mm_idp->u.pid; + int err, pid =3D mm_idp->pid; =20 n =3D ptrace_setregs(pid, syscall_regs); if (n < 0) { diff --git a/arch/um/os-Linux/skas/process.c b/arch/um/os-Linux/skas/proces= s.c index f7088345b3fc..b6f656bcffb1 100644 --- a/arch/um/os-Linux/skas/process.c +++ b/arch/um/os-Linux/skas/process.c @@ -588,5 +588,5 @@ void reboot_skas(void) =20 void __switch_mm(struct mm_id *mm_idp) { - userspace_pid[0] =3D mm_idp->u.pid; + userspace_pid[0] =3D mm_idp->pid; } --=20 2.34.1 From nobody Sat Feb 7 08:28:18 2026 Received: from out0-220.mail.aliyun.com (out0-220.mail.aliyun.com [140.205.0.220]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DD7E812DD90 for ; Fri, 16 Aug 2024 10:00:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.205.0.220 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723802411; cv=none; b=rNYfho0/dL4OcE0Zjt9VJAEmYuwSBhkQSm+9bLvKpTtvr0SJxeaBSef1ih/ZhZjXR8b6uINUswlZLdjE5mDFYz0PVXhcwbS2FlVky9FVUAdQNj7G2dK5eM5t4XDYJaJbiuhrsb9mufYOJTHHxAFpUjylDQQK5+0WRnt3woWExqU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723802411; c=relaxed/simple; bh=spZ3LOvkvA7HC0vXfPQJtr2q7pS40m/umBN5GazXmmo=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=Hiu5g0qwHGDxJzujsAvxIzzZvDFQQPEn5McXtrG/rSXx3ZuVsJcfFah/VWJuGs5JGdvlhKjgsv2qPpE89v1dbPGq1atRRXIXbDV8GNUWr1Aj7H6yB6Rs+j0QXFivWMHP1MssNT/EloaHNgcjJ3QZOTlonDxKE1XjUedKZTAE3Yo= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com; spf=pass smtp.mailfrom=antgroup.com; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b=LZz4lA0S; arc=none smtp.client-ip=140.205.0.220 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=antgroup.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b="LZz4lA0S" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=antgroup.com; s=default; t=1723802405; h=From:To:Subject:Date:Message-Id:MIME-Version; bh=xaPbnHCYbWmnOQhAEH3tFBvJcl0Mc7zmh0X86Vcw7mg=; b=LZz4lA0Sa+rqCiyhu+pwRlH+JjFnjML8aYphyxQjZQpuN5pvPdY8VW6a3JU7Qtw77KGBJYSG+ks9FYZ2BT6IfwIx+iLUqxfU/3dtku2xwoVkkbIR7clBYLPKP4M0lcFv2P7a+1jbCxJDUeIJmKVcxPhvN/1c+L5Mjh1TnV7KH3Q= Received: from ubuntu..(mailfrom:tiwei.btw@antgroup.com fp:SMTPD_---.YtmFE9B_1723802404) by smtp.aliyun-inc.com; Fri, 16 Aug 2024 18:00:04 +0800 From: "Tiwei Bie" To: richard@nod.at, anton.ivanov@cambridgegreys.com, johannes@sipsolutions.net Cc: , , "Tiwei Bie" Subject: [PATCH v2 5/6] um: Remove the call to SUBARCH_EXECVE1 macro Date: Fri, 16 Aug 2024 17:59:52 +0800 Message-Id: <20240816095953.638401-6-tiwei.btw@antgroup.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240816095953.638401-1-tiwei.btw@antgroup.com> References: <20240816095953.638401-1-tiwei.btw@antgroup.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" This macro isn't defined by any supported sub-architectures in tree since it was introduced by commit 1d3468a6643a ("[PATCH uml: move _kern.c files"). Signed-off-by: Tiwei Bie --- arch/um/kernel/exec.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/arch/um/kernel/exec.c b/arch/um/kernel/exec.c index 2c15bb2c104c..cb8b5cd9285c 100644 --- a/arch/um/kernel/exec.c +++ b/arch/um/kernel/exec.c @@ -35,8 +35,5 @@ void start_thread(struct pt_regs *regs, unsigned long eip= , unsigned long esp) PT_REGS_IP(regs) =3D eip; PT_REGS_SP(regs) =3D esp; clear_thread_flag(TIF_SINGLESTEP); -#ifdef SUBARCH_EXECVE1 - SUBARCH_EXECVE1(regs->regs); -#endif } EXPORT_SYMBOL(start_thread); --=20 2.34.1 From nobody Sat Feb 7 08:28:18 2026 Received: from out0-196.mail.aliyun.com (out0-196.mail.aliyun.com [140.205.0.196]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 130E916F0D2 for ; Fri, 16 Aug 2024 10:00:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.205.0.196 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723802410; cv=none; b=eXD9pM/kV+PxzbllrMV7ir+wu71kU1OMXlemVuCDCjIqRm513CijhgO+l7D14Et478ijgaUnK9FPeaUOlDtfPwsxUZ/py/FmP4nhjrgy4tbkmMJs29kOdOlzw2UUOVCkbnwG5WZlQj5f6B7PrL+00Am4XMtICoONuVhNLJY7h84= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723802410; c=relaxed/simple; bh=h3ektH89VgKUm1hFQf4tNGITO8lwB8WYpEAS6FRb3Pk=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=Z7YbsNM2doNSR5TTuPuCtnPwj1AhqXkn004E5uwBMuD5qK98mQlBDFju210D85dxua+V81DIu4UgKr0+6z6K2jSucJSEfkBSEbvO+YvGbAhCLjhftAFNocekcZhypOD772+7uId45axN8BhO9K8Mr55bZVMxneI9SGRtMRp2k8Y= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com; spf=pass smtp.mailfrom=antgroup.com; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b=NBttyKJ1; arc=none smtp.client-ip=140.205.0.196 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=antgroup.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b="NBttyKJ1" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=antgroup.com; s=default; t=1723802406; h=From:To:Subject:Date:Message-Id:MIME-Version; bh=LTmj84zcrMSG/7oxdcFgD9iQDmdedlra1IBnqpPooqs=; b=NBttyKJ1BavOjmjIQ1VUsKyz5Jd4UBWGodsMgwNLktP0YLyjmTEeA+eNexQ9YBmvBbat7YGjV7mDolCf5AWSa9CQNWMsRlue6MQYj6aPhNnqF2jNg3RrumzSb4afdOOuPy18OnyVuWTkrYzAbqqkpRerAA8YPNN0DDlSCysSws0= Received: from ubuntu..(mailfrom:tiwei.btw@antgroup.com fp:SMTPD_---.YtmFE9t_1723802405) by smtp.aliyun-inc.com; Fri, 16 Aug 2024 18:00:05 +0800 From: "Tiwei Bie" To: richard@nod.at, anton.ivanov@cambridgegreys.com, johannes@sipsolutions.net Cc: , , "Tiwei Bie" Subject: [PATCH v2 6/6] um: Remove declarations of undefined functions Date: Fri, 16 Aug 2024 17:59:53 +0800 Message-Id: <20240816095953.638401-7-tiwei.btw@antgroup.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240816095953.638401-1-tiwei.btw@antgroup.com> References: <20240816095953.638401-1-tiwei.btw@antgroup.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The definitions of these functions do not exist anymore. Signed-off-by: Tiwei Bie --- arch/um/include/shared/skas/skas.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/arch/um/include/shared/skas/skas.h b/arch/um/include/shared/sk= as/skas.h index ebaa116de30b..85c50122ab98 100644 --- a/arch/um/include/shared/skas/skas.h +++ b/arch/um/include/shared/skas/skas.h @@ -10,10 +10,8 @@ =20 extern int userspace_pid[]; =20 -extern int user_thread(unsigned long stack, int flags); extern void new_thread_handler(void); extern void handle_syscall(struct uml_pt_regs *regs); -extern long execute_syscall_skas(void *r); extern unsigned long current_stub_stack(void); extern struct mm_id *current_mm_id(void); extern void current_mm_sync(void); --=20 2.34.1