Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp797790pxb; Fri, 22 Apr 2022 11:21:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzK0GEdn5ktmxqB0aa1iZFydK2t5o839tJJcid5irIdccVu7Zx84yKBYOua2o5FdxukWBiu X-Received: by 2002:a17:903:234c:b0:158:f94c:9813 with SMTP id c12-20020a170903234c00b00158f94c9813mr5995756plh.54.1650651680603; Fri, 22 Apr 2022 11:21:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650651680; cv=none; d=google.com; s=arc-20160816; b=WbhZBrUUR29Q66At6YphTgI5udzIE7Sppd9P8h8gxmrSf0MWWlu2uiNH5MwSJC/coV OYlxJNDlmAeNKDaCHjCk/WPU/oyXzhvM/ocAJrm4ruvB/CGHZqTd4HkaakZ3ISRKb4ho VX6kiv0ATOkYMz6sVOgLeWKKMjR8MC82VQS8G5336XgiZJ4+1vCTvtTGPkPju/zZkr1g N8DgBcOstJjA1A/6tjwrtNkwUb2vwE+CLuBumXLRxI5qYYqv733K2g+ym3OdOzfGe3uF F8IUzF0U8oRb/SxiubrC6Xvi8iIeEWMnKbXx+9GQbheZcRtdxRM3GStS+qzWiLzyah5P pahw== 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:subject:cc:to:from:date; bh=cWVMctqFgMbOYXeaXsHbBVpRHZn5h8NgqsUftRXhCoI=; b=GLceJBMugjPnNR5ES+qa/0OqLg0vqbPMg2gdU0CyQ31v9M+GBTr779SutlztqzsaVo z9xmSjA3s9OJn9K2uAJI9p3H0gg//9DXialFDM6XnaiKCWjpUqTLGpmh3TZtpQq1J4zm kNqb7YwJJD+m/lyX87Zm/WjsNCJzHa+b7uFUOsD6SFmp1HTfZsr7sHzynXebKc/DUSLd JiDx1sQDOXgMs4WeG34uZv8bXNPPWgtWdsvMI0XAIHwdAIP0Bg9A7VVOGpaIKimv3IRU NyygkT3ttMVrITIrBgA5oBzjhSq25+k8L0FJw3Djv50oOn8uRZpIVU67HEnl5tMDk9Et Rz0Q== ARC-Authentication-Results: i=1; mx.google.com; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id h70-20020a638349000000b003aa817ccdf1si6283613pge.807.2022.04.22.11.21.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Apr 2022 11:21:20 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 3101013F272; Fri, 22 Apr 2022 10:52:10 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1449412AbiDVPsm (ORCPT + 99 others); Fri, 22 Apr 2022 11:48:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53066 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1449378AbiDVPsk (ORCPT ); Fri, 22 Apr 2022 11:48:40 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 449DE5D64B for ; Fri, 22 Apr 2022 08:45:47 -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 00F94B830D6 for ; Fri, 22 Apr 2022 15:45:46 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 608ABC385A8; Fri, 22 Apr 2022 15:45:43 +0000 (UTC) Date: Fri, 22 Apr 2022 11:45:41 -0400 From: Steven Rostedt To: Mark Rutland Cc: Wang ShaoBo , cj.chengjian@huawei.com, huawei.libin@huawei.com, xiexiuqi@huawei.com, liwei391@huawei.com, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, catalin.marinas@arm.com, will@kernel.org, zengshun.wu@outlook.com, Masami Hiramatsu Subject: Re: [RFC PATCH -next v2 3/4] arm64/ftrace: support dynamically allocated trampolines Message-ID: <20220422114541.34d71ad9@gandalf.local.home> In-Reply-To: References: <20220316100132.244849-1-bobo.shaobowang@huawei.com> <20220316100132.244849-4-bobo.shaobowang@huawei.com> <20220421100639.03c0d123@gandalf.local.home> <20220421114201.21228eeb@gandalf.local.home> <20220421130648.56b21951@gandalf.local.home> X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE autolearn=no 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 On Fri, 22 Apr 2022 11:12:39 +0100 Mark Rutland wrote: > As an aside, I'd also love to remove the REGS/!REGs distinction, and always > save a minimum amount of state (like ARGS, but never saving a full pt_regs), > since on arm64 the extra state stored for the REGS case isn't useful (and we > can't reliably capture all of the pt_regs state anyway, so bits of it are made > up or not filled in). Note, the reason for the addition of REGS was a requirement of kprobes. Because before ftrace, kprobes would be triggered at the start of a function by a breakpoint that would load in all the regs. And for backward compatibility, Masami wanted to make sure that kprobes coming from ftrace had all the regs just like it had when coming from a breakpoint. IIUC, kprobes is the only reason we have the "regs" variant (all other use cases could get by with the ARGS version). -- Steve