Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp17930234ybl; Thu, 2 Jan 2020 15:02:33 -0800 (PST) X-Google-Smtp-Source: APXvYqwRXAMSEHTPOXkd2Ho2dhKykyKYqSgb5zMAI1TNB9YpMYWTmpMoQuB0XRoOxAEf43swDQgW X-Received: by 2002:a05:6830:1f95:: with SMTP id v21mr88205295otr.325.1578006152810; Thu, 02 Jan 2020 15:02:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1578006152; cv=none; d=google.com; s=arc-20160816; b=PqSNKWOHjpNzhZptdkKJatn4NLJ8apEikjLCZ6rGPy486qPe5wYrG0hKQoqbVN/Hop D13J847qOUpdFTCysPtJGRnMfqk0++f9mcYDux+Rle7lbPwmlpP46Cwc/qtV48wAh4j9 ufJEqFT4IsrS13OBOX6GarzGqpV7ipaq+L0HzPrn+G9DsIBQMsbrjPwTZKU92QzzaRy+ usilRkVrS6XHhw2h+GITuAnfR5HPVliOXm8o58ca3YCbFtz1qH1rkT8p+17Dg0XT1+8x p/VJ1ttkEO7We6B6UcHY2v048xP0sMm/09CFAmFslWip8GEiazrPpLD22yR1G9E7HvS8 pBcw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=Se+1HaAYnpbnyfzUUQoWcCSb39hdyqouUqnWnVIwdBY=; b=WBaa/auflXrXheV+NhrAkVwp8RjYee4B3MtD993/wVXu9gv+oWtVIjMe5CaEwkncbs jiggKgtvyc6ggK3kP/+wO7AA3YTpkE2nppL+lgtjvYF3X7l7heC19vkzw9jLDoNty5ni RK+qbq+7i5bWUi+z5M/YHVyTn0tF1VUie/lmitIt/9TmathY4BwQlL4idUMH+IdD1a6P C15nY7KZEn7G4Rw6iyaLVfdjb6/fFHhpPVisvQMdQ+EVBQKCzZLoZmYjW1iyeVxX0x66 QxNxTs3dL45UHxOqcXwqfaPC6RfE6XxojVOu2jKgFfHU1nr59kh5I9/m0ROC6XZinftJ n0bg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=sh0S7Ar2; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u12si29459565otq.51.2020.01.02.15.02.20; Thu, 02 Jan 2020 15:02:32 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=sh0S7Ar2; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727349AbgABWMB (ORCPT + 99 others); Thu, 2 Jan 2020 17:12:01 -0500 Received: from mail.kernel.org ([198.145.29.99]:50526 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727304AbgABWLw (ORCPT ); Thu, 2 Jan 2020 17:11:52 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id D149F21D7D; Thu, 2 Jan 2020 22:11:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1578003112; bh=/+Z1rY2uHzFKiy1RITFdLrA1sEw2jtbce0wauhrJJPI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=sh0S7Ar2VtH7cTFlkVuDk6wZ6kFBy/xwcExfl5Yw5sdy3zeYCDwC3Qm8rdps5HeKo +Bea2JejGiQVt9e2u/5S8pZTkg5d/tVrbqhBihDoT4cKXbEIIB3nMqqOg5QPQPG0ZN uQgeXCPJXF9BfEJUuWTZhrfAtf9x1kmeNwzI8bgw= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Michael Ellerman , Sasha Levin Subject: [PATCH 5.4 024/191] powerpc/pseries: Mark accumulate_stolen_time() as notrace Date: Thu, 2 Jan 2020 23:05:06 +0100 Message-Id: <20200102215832.532953721@linuxfoundation.org> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20200102215829.911231638@linuxfoundation.org> References: <20200102215829.911231638@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Michael Ellerman [ Upstream commit eb8e20f89093b64f48975c74ccb114e6775cee22 ] accumulate_stolen_time() is called prior to interrupt state being reconciled, which can trip the warning in arch_local_irq_restore(): WARNING: CPU: 5 PID: 1017 at arch/powerpc/kernel/irq.c:258 .arch_local_irq_restore+0x9c/0x130 ... NIP .arch_local_irq_restore+0x9c/0x130 LR .rb_start_commit+0x38/0x80 Call Trace: .ring_buffer_lock_reserve+0xe4/0x620 .trace_function+0x44/0x210 .function_trace_call+0x148/0x170 .ftrace_ops_no_ops+0x180/0x1d0 ftrace_call+0x4/0x8 .accumulate_stolen_time+0x1c/0xb0 decrementer_common+0x124/0x160 For now just mark it as notrace. We may change the ordering to call it after interrupt state has been reconciled, but that is a larger change. Signed-off-by: Michael Ellerman Link: https://lore.kernel.org/r/20191024055932.27940-1-mpe@ellerman.id.au Signed-off-by: Sasha Levin --- arch/powerpc/kernel/time.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/kernel/time.c b/arch/powerpc/kernel/time.c index 619447b1b797..11301a1187f3 100644 --- a/arch/powerpc/kernel/time.c +++ b/arch/powerpc/kernel/time.c @@ -232,7 +232,7 @@ static u64 scan_dispatch_log(u64 stop_tb) * Accumulate stolen time by scanning the dispatch trace log. * Called on entry from user mode. */ -void accumulate_stolen_time(void) +void notrace accumulate_stolen_time(void) { u64 sst, ust; unsigned long save_irq_soft_mask = irq_soft_mask_return(); -- 2.20.1