From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3D9D2C433F5 for ; Thu, 21 Oct 2021 12:30:10 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 036C3610EA for ; Thu, 21 Oct 2021 12:30:09 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 036C3610EA Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.microsoft.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date: Message-ID:From:References:Cc:To:Subject:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=r5fWL15tGhgJRWhnxq1rvEmdhI3jT3kBoIWZwVjh31I=; b=Q/rzNULQKvqtzWRL5i3UgBH9kB WUdSD25sl4wMfEc9mWikCUAQYmDuvSHTJSl7py1ef+w0koT7w3/RxH5nrBXognNSpsyO/C9Fv8X1x P+RwIvFTlEeYd9LL8gei40KxgUVl+ErdO5yQcRQDEVARGDO3MYRS/jvooVXo0d8o5pyHCR39ejCXt iNIQZjJ4aegjsEKXjGpRpRo7PETINqVBIj0atvOoYIOGs8w0AzBYDyNGbOU3GqLTq1Frb1Wnuz2tj qvWtZKio+eUysuLIUoXa17PAjRQtzZdTN6egjgPj7IdveFh0n/W32hktbSve3L8bw9BAcxA/hhy/H ij7xHsxA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mdXBl-007UGu-TM; Thu, 21 Oct 2021 12:28:54 +0000 Received: from linux.microsoft.com ([13.77.154.182]) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mdXBg-007UGI-UF for linux-arm-kernel@lists.infradead.org; Thu, 21 Oct 2021 12:28:50 +0000 Received: from [192.168.254.32] (unknown [47.187.212.181]) by linux.microsoft.com (Postfix) with ESMTPSA id CFC5B20B7179; Thu, 21 Oct 2021 05:28:47 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com CFC5B20B7179 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1634819328; bh=DvHvI1eWTe/g+Ehqlznt9wtXs8WUeiscbm6lpSkMErM=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=YSvX7YSp4lwVxBlBM7o1zYZkCVrYuVhEO5iffMK7XhMMsFOtArvrvEjKUh+5fESNo ptiYAPdNHWleVi3nZ6fKVNDOMrm7hIzZHgZUfmnp4e6z1DTA407wINSW0a+ie7Ap9N UQU5dlSnzi/eWefqupMNyY/ubH+Ob5KgJbdV/K0Y= Subject: Re: [PATCH v10 02/11] arm64: Make perf_callchain_kernel() use arch_stack_walk() To: Mark Brown Cc: mark.rutland@arm.com, jpoimboe@redhat.com, ardb@kernel.org, nobuta.keiya@fujitsu.com, sjitindarsingh@gmail.com, catalin.marinas@arm.com, will@kernel.org, jmorris@namei.org, linux-arm-kernel@lists.infradead.org, live-patching@vger.kernel.org, linux-kernel@vger.kernel.org References: <20211015025847.17694-1-madvenka@linux.microsoft.com> <20211015025847.17694-3-madvenka@linux.microsoft.com> From: "Madhavan T. Venkataraman" Message-ID: Date: Thu, 21 Oct 2021 07:28:46 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 MIME-Version: 1.0 In-Reply-To: Content-Language: en-US X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211021_052849_034532_D62DE350 X-CRM114-Status: GOOD ( 14.88 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 10/20/21 9:59 AM, Mark Brown wrote: > On Thu, Oct 14, 2021 at 09:58:38PM -0500, madvenka@linux.microsoft.com wrote: >> From: "Madhavan T. Venkataraman" >> >> Currently, perf_callchain_kernel() in ARM64 code walks the stack using >> start_backtrace() and walk_stackframe(). Make it use arch_stack_walk() >> instead. This makes maintenance easier. > >> static bool callchain_trace(void *data, unsigned long pc) >> { >> struct perf_callchain_entry_ctx *entry = data; >> - perf_callchain_store(entry, pc); >> - return true; >> + return perf_callchain_store(entry, pc) == 0; >> } > > This changes us from unconditionally doing the whole walk to returning > an error if perf_callchain_store() returns an error so it's not quite a > straight transform, though since that seems like a useful improvement > which most likely on't have any practical impact that's fine. > > Reviewed-by: Mark Brown > > > _______________________________________________ > linux-arm-kernel mailing list > linux-arm-kernel@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel > Thanks. Madhavan _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel