Received: by 2002:a05:6358:bb9e:b0:b9:5105:a5b4 with SMTP id df30csp3877742rwb; Mon, 5 Sep 2022 21:32:21 -0700 (PDT) X-Google-Smtp-Source: AA6agR5ZhfiJntXjTiWaOgcWQ4PdjsYe2XooEL7tXb2GLjerW0ShN/N7sIuCgs+SFPZcM++FtYD5 X-Received: by 2002:a17:907:9484:b0:73c:37bb:c4d7 with SMTP id dm4-20020a170907948400b0073c37bbc4d7mr39172699ejc.748.1662438741770; Mon, 05 Sep 2022 21:32:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1662438741; cv=none; d=google.com; s=arc-20160816; b=ZnCWVhDIf1mWcr2mYltmz7/dgFmVXfKlA2kkUr9ZQcOOEFaM10qMjM7aHvxco5dTBG i5OHWtqDZdK5CTJtZxnBdM6xIOFSDJLx0OypqQ/Yj2A78rvUawgwUmu6ib+/wLp62AZU zpIy/asSo3bJIO4BNWEAwZkbjtqtMMo4kiNxl8sjWqpb04DBeGvw4jsyv0LUK9sT2tkA XCjKJ5ZZRGl+GcMRepZvtYx5HHPhTX/Yn4hb/Nno1cduUKCt1GVtrsDa8Ikt0mqsEV1U or7N5n/SoHIPaqQIj2lBRnZeipGQhAnV5//cOxJAzCkE+6UDlwRiKGC2xmJ3JARbKQkj Ubog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=KE1HaCW8/vTK3M7A5UdQL4voTRfIscy1WBRLT2QrV1k=; b=ylEG/8J9NaSCQd4qzgHTJUxSoCYNsNMrXr3gOT/+IVhixQJOz4paAstLo+zI+E7q6B +ETnsHcutbVUqEA/+8t6dTBOG5T4892Yj433rM3CLoGTAO3gBQ9YuutW8uFeZmvGAvaf viO2VyGT0LIcaCqOF5tnPvtjJaxAn+H+f4eSQzX/yCwOO3+9KDTS7kL6RzyLCYW72rui SiapXEhYnNuhxAbb2Ey0srMhmi9413wmGHvOcdAgcUdanRVF5apxc2roZCt9G2gv/8np 12S2VJXHyxEZ69H2bHdrjyiFTfkCbd0U/A9Hd7D0zB3ZuwEFWnlrQF/weM8hkISoNsN/ ibIA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=i8udwuBU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c9-20020a170906528900b0073ddd0732c8si8127591ejm.867.2022.09.05.21.31.55; Mon, 05 Sep 2022 21:32:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=i8udwuBU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232930AbiIFDzl (ORCPT + 99 others); Mon, 5 Sep 2022 23:55:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56544 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236562AbiIFDzK (ORCPT ); Mon, 5 Sep 2022 23:55:10 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 332C31571F; Mon, 5 Sep 2022 20:54:59 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id DD87DB815FB; Tue, 6 Sep 2022 03:54:57 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 3F8EDC433C1; Tue, 6 Sep 2022 03:54:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1662436496; bh=thj4lp5B0J2/kj7Zi1BMTTtT9fAnJMteMKwuLQ0ArOk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=i8udwuBU0lCnGSWfJh+zVWQdY9k87VxtIPz2WRyDipdMPDhdwQ1DuQxUSz2f3E+IH MNCaeoiS5gTYY6mkddHFDWOwOHbatCHkZ42WpJEc5HlfQrIutiswW7SnZzA7gt3MeH 4R8AtD7oKwAwcyJ0G9DIx/BBitTTC+Iwph8He9iYVi12jxE9O1POde7d4gr58bHd1O sd2Y3hu7st2f5XzM+CZ+XOfGA2eYsHWhmnHhvkssFtwyBSW8C3cBYyEYAsKpxgEkuj gxjESVMju9ttMp0oIFP8+nVIaL6Dn/MwbzpKcTajmH5ICYlRPkgwO9gdBqo3E2JZpl bWnR+ekig5w9w== From: guoren@kernel.org To: arnd@arndb.de, guoren@kernel.org, palmer@rivosinc.com, tglx@linutronix.de, peterz@infradead.org, luto@kernel.org, conor.dooley@microchip.com, heiko@sntech.de, jszhang@kernel.org, lazyparser@gmail.com, falcon@tinylab.org, chenhuacai@kernel.org, apatel@ventanamicro.com, atishp@atishpatra.org, palmer@dabbelt.com, paul.walmsley@sifive.com, bigeasy@linutronix.de Cc: linux-arch@vger.kernel.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org, Guo Ren , Oleg Nesterov Subject: [PATCH V3 3/7] riscv: ptrace: Remove duplicate operation Date: Mon, 5 Sep 2022 23:54:19 -0400 Message-Id: <20220906035423.634617-4-guoren@kernel.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220906035423.634617-1-guoren@kernel.org> References: <20220906035423.634617-1-guoren@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Guo Ren The TIF_SYSCALL_TRACE is controlled by a common code, see kernel/ptrace.c and include/linux/thread.h. clear_task_syscall_work(child, SYSCALL_TRACE); Signed-off-by: Guo Ren Signed-off-by: Guo Ren Reviewed-by: Oleg Nesterov --- arch/riscv/kernel/ptrace.c | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/riscv/kernel/ptrace.c b/arch/riscv/kernel/ptrace.c index 2ae8280ae475..44f4b1ca315d 100644 --- a/arch/riscv/kernel/ptrace.c +++ b/arch/riscv/kernel/ptrace.c @@ -212,7 +212,6 @@ unsigned long regs_get_kernel_stack_nth(struct pt_regs *regs, unsigned int n) void ptrace_disable(struct task_struct *child) { - clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE); } long arch_ptrace(struct task_struct *child, long request, -- 2.36.1