From patchwork Wed Mar 29 15:50:15 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Bristot de Oliveira X-Patchwork-Id: 76681 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp516194vqo; Wed, 29 Mar 2023 08:59:11 -0700 (PDT) X-Google-Smtp-Source: AKy350apSqY3sQTLgoaHC32BVHapWyR8EuV5PcOAMii/JIJxZcTccJD0uQk86gowdlAEz5e6mkKx X-Received: by 2002:a17:906:5850:b0:935:3028:ff58 with SMTP id h16-20020a170906585000b009353028ff58mr20446508ejs.55.1680105551629; Wed, 29 Mar 2023 08:59:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680105551; cv=none; d=google.com; s=arc-20160816; b=ZguRJXrWp2MAPD8cQH4HBB3NWD/NBjVGvaoJMA14kNtAIIrY0YjHuvogJC46tnk8j9 Ahr7Nu0J36FOBEVEu9HH6YScQN8yxoMaNhJ2toQ2x/yVsjkpCEz6DYEz6+j17V4ojGw7 P06XKLRZ0EzEKMeogz9sg3gNeyxLDXvBqBEXPUvtI2CLYMy3/8iD5BHsPxDckY4PVQ3n dm2Hq9iE2L02+T4Mky+aFGc4JxjvzLNBBt/6UlbE46Ln5JGnBTyILX18xo/juVVILUJD VIksopGcWHHGg6iXJIBc4SeC+UTVvUll0iQdpoC1CyBMhA+328iB+et6J9bCSLETGOn3 fzdw== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=o4xwFT6dEmJ6GjfbVdjF1+aBSzyKtU+YFVyzB/3uuAI=; b=sd609wWnzt1L7f9EiHSWPM1YCo7OIl2TLHmiKhTBqAgltwZfgX+QktJfAOhwQH9A8p +pxE1BU2W3rppIcgLkjKfdRtLZDqnWk/xlsn3DBI9zrL/j6KTKo4s2qKpM1a5Gt3HUej BSGJzLabTL3JXKdeROhr64xTxyfvCn6myrXAxnLqJTPOL42XC5U70Vsmze0WlrstJDgl rZIvNgqKvvqpy9b7tQUPNbYvJKX8Oti3JmvB7ilcrXHZthC1pOsPRrNmrxpLIi0hlVhr NP2R5t6ID28cEnKs3dUSwryVOpwhFtR0LyQRs+IciOQZ9TTvh7eMLc/qNCWnihcDusoi /HVA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="p1d/75k2"; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id n15-20020aa7c78f000000b00501c32ce664si27866267eds.325.2023.03.29.08.58.46; Wed, 29 Mar 2023 08:59:11 -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="p1d/75k2"; 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 S229849AbjC2Pum (ORCPT + 99 others); Wed, 29 Mar 2023 11:50:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37476 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230272AbjC2Pub (ORCPT ); Wed, 29 Mar 2023 11:50:31 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 71455469C; Wed, 29 Mar 2023 08:50:30 -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 dfw.source.kernel.org (Postfix) with ESMTPS id E287C61D84; Wed, 29 Mar 2023 15:50:29 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E98C3C433EF; Wed, 29 Mar 2023 15:50:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1680105029; bh=2tVl9UGX52wuunDco8JD3qwtKdEDsXFZ5A6RPBCNMuM=; h=From:To:Cc:Subject:Date:From; b=p1d/75k2P1b9x5VEEKcCUXBAF+mJF/l25lthonFZXcGlnBqDARpn491qzTs4UJp7+ gc0x4tMB22H0K1cOnqFTZUDQWukKo/EQAz4PJ6JNMOM5wq5vIwd5PuIjT+dmesn4QL VtUM05QWvhHbEQqKYH9VjzC86mrcf+DeGuh3n0x1EY2cDuxY8I22xZHv5JnklufUgr uvKQzh9NyXdLZ0VQM+nBDrA+OB/+3bPk4nbDwpjUcQzue9Mi/RSk3nyIh5Z5i47Vjh wPJByOH9KEXDhaTw0IClQK8iMB2QcCTlKGb6cl4D9OcUSEEcwbirDB1yErG3FhFlnE c99EhNEjf2+Ng== From: Daniel Bristot de Oliveira To: Steven Rostedt Cc: Daniel Bristot de Oliveira , linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org, Masami Hiramatsu Subject: [PATCH V2 1/2] tracing/timerlat: Notify new max thread latency Date: Wed, 29 Mar 2023 17:50:15 +0200 Message-Id: <16e18d61d69073d0192ace07bf61e405cca96e9c.1680104184.git.bristot@kernel.org> X-Mailer: git-send-email 2.38.1 MIME-Version: 1.0 X-Spam-Status: No, score=-2.5 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS autolearn=unavailable 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1761718359129429455?= X-GMAIL-MSGID: =?utf-8?q?1761718359129429455?= timerlat is not reporting a new tracing_max_latency for the thread latency. The reason is that it is not calling notify_new_max_latency() function after the new thread latency is sampled. Call notify_new_max_latency after computing the thread latency. Changes from V1: Split the patch into two patches (Steve) Fixes: dae181349f1e ("tracing/osnoise: Support a list of trace_array *tr") Cc: Daniel Bristot de Oliveira Cc: Steven Rostedt Cc: Masami Hiramatsu Signed-off-by: Daniel Bristot de Oliveira --- kernel/trace/trace_osnoise.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/kernel/trace/trace_osnoise.c b/kernel/trace/trace_osnoise.c index 9176bb7a9bb4..e8116094bed8 100644 --- a/kernel/trace/trace_osnoise.c +++ b/kernel/trace/trace_osnoise.c @@ -1738,6 +1738,8 @@ static int timerlat_main(void *data) trace_timerlat_sample(&s); + notify_new_max_latency(diff); + timerlat_dump_stack(time_to_us(diff)); tlat->tracing_thread = false;