Received: by 2002:a05:7412:d024:b0:f9:90c9:de9f with SMTP id bd36csp104493rdb; Wed, 20 Dec 2023 07:23:46 -0800 (PST) X-Google-Smtp-Source: AGHT+IF3hRrMmMTf9Yk2RGLOd3wMbn73Javs5T6yc6Pl97xS4noOaHXprHb1GljnFcrutEmbqSDX X-Received: by 2002:a17:903:18e:b0:1d3:e7a4:a423 with SMTP id z14-20020a170903018e00b001d3e7a4a423mr1873393plg.96.1703085825922; Wed, 20 Dec 2023 07:23:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703085825; cv=none; d=google.com; s=arc-20160816; b=U14dMxQqEgcm6Ym7rxrKKmvYHRL3fJUrTpGkoa1iXivIgrvJM/tCJWcTXq2gnU5IFW UXQpHul0hhbi14ymmNKfGVzl1oMP3n+CuN8S26Q1z/e6sMu009dLfoYsUkac8zX2ACLJ yviF3SAkil8AxdL7UkWUunwccXjiEC0brY/wdVlGGjrBtFnvTvtG17+eMIu7ovLF3cSI cjlusoKLImcv7EBY5ZFdOtVVWikF+qu8UGeftwi55Acp3vZPWkT+/h/Z4bUNP1EI8FoD +v6VtI7CXm5VgUFNSbywAykb+qEpXY3HdNsyAozGLWTXWmYTdLf++frLLsgtlOtuUeIH FLQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=yoXHOZhoklkeSWNJlzLRFgk2cePKxMMAtNjLJkIi/A8=; fh=cyOSwSkj+iJBVGbt7eJLCz15URs0PAUR1Bwubf+t8Gk=; b=w9uQLIwRQJtapxJcsYM89G9GkHCkpvDejhok884UUkY6+jsZqm3sj+6QPLhe55jRdD u9nJsIPk/VE/UHwuHELqsieEwB5x7g84TXl7FuVREFS/NCCbE2rjuoxabEGClYL6DYmO cc1CAsjYUC04Aj9RAE9D9pHEnmgxYO7vwKPstZrqe6ywpcYG6pSfKCti3af3bEok0+cJ P7W/MuPu6xrVcYKKWQBz05iIgnIG+CsMtU2MmEjToof52wV6Bs1uVpR8HgPMBbgmlsAD 57AT9ckVeViIwJzfkd0lLJ8uHdAB7VoSNgZWA23epLrl20IzCMPOJRXQgL0TkDucKe6z 0hVQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=QJCfN46G; spf=pass (google.com: domain of linux-kernel+bounces-7145-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-7145-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id j12-20020a170903024c00b001d0c1281f07si21911754plh.205.2023.12.20.07.23.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Dec 2023 07:23:45 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-7145-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=QJCfN46G; spf=pass (google.com: domain of linux-kernel+bounces-7145-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-7145-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 91E3728884C for ; Wed, 20 Dec 2023 15:23:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 36F0A3FE47; Wed, 20 Dec 2023 15:18:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="QJCfN46G" X-Original-To: linux-kernel@vger.kernel.org Received: from mail-qk1-f169.google.com (mail-qk1-f169.google.com [209.85.222.169]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1EB893FB33 for ; Wed, 20 Dec 2023 15:18:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-qk1-f169.google.com with SMTP id af79cd13be357-77f5b3fa323so369987485a.0 for ; Wed, 20 Dec 2023 07:18:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1703085518; x=1703690318; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=yoXHOZhoklkeSWNJlzLRFgk2cePKxMMAtNjLJkIi/A8=; b=QJCfN46GqHaUH/Rgpx/fzqCXPvGGnbS20x7yhgi4KCy5jiJb62isGqJCj5zviEbNlN T2iIRQ8uooNHqG484SBbk60qmZmbnSoiNoGU3bcYtLWocPdUSA9OVH9Br5zY2QHhz0jI P7fJp9QNx5/qdJ+jUcTybUDfiSWomtTQ6p4fi+lvlyvyNt+BXYT0tvPFcrrLQHRoARz/ NRmJ2bUtDJhswzcMLGtUA88jBN7WZCsAKk6GshDxhgZ/e6o8+jZ2UGc4YPRj22wKi8lm gNjqOSzAznfhDNy6Zb22W3fYUyPGgHaJ33bik+lhb1BS1m2E/mh5lsUAffgY0LsHM9Km 5T7w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703085518; x=1703690318; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=yoXHOZhoklkeSWNJlzLRFgk2cePKxMMAtNjLJkIi/A8=; b=Muv9G8rOqEg51jbPKfPvueWdZ7tDaC8z+IBCaIZSMoBDZ5Sf837fqY27+qxFyHEUyy 4VcWeRzyVtDRdN0lDjvkr3wq24z7c4DseE485RcrYSZdiLnMXkyxmI/IiDTFj1BV9BiA /6ptzQQszEYfhfrG8upZZgSRzCMKkBQyGX74XlGJsDlNlM6igoaVKZ5GbObvrZWTuie9 dLkuKXT/I0mp76I+0XMfcARWecpUM7DpQUXssBeFQaFWRfh3FaTajn7fG5VG1GqSq48A h7sNXWxo35GzmU70zp+JTzKrkufM4OHfmJJuCxdepUKa359TaLtCr2dRUqFqi4/GnoKF oV1g== X-Gm-Message-State: AOJu0YxlmP7ooa4ZgS5VyP/0mSw2b9fg3lJt+oecwpPtEN1zNsIbX7t6 aND6mNnxMJ+C+wSKAweBYNoFr2INS1HarSiSREs= X-Received: by 2002:a05:6214:2426:b0:67f:61ff:c7a1 with SMTP id gy6-20020a056214242600b0067f61ffc7a1mr3118125qvb.9.1703085517708; Wed, 20 Dec 2023 07:18:37 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20231220140112.821992-1-wudaemon@163.com> <20231220143249.833273-1-wudaemon@163.com> In-Reply-To: <20231220143249.833273-1-wudaemon@163.com> From: Yafang Shao Date: Wed, 20 Dec 2023 23:18:01 +0800 Message-ID: Subject: Re: [PATCH v1] sched/rt: Fix rt task's sched latency statistics error in sched_stat_wait trace_point To: Junwen Wu Cc: bristot@redhat.com, bsegall@google.com, dietmar.eggemann@arm.com, juri.lelli@redhat.com, linux-kernel@vger.kernel.org, mgorman@suse.de, mingo@redhat.com, peterz@infradead.org, rostedt@goodmis.org, vincent.guittot@linaro.org, vschneid@redhat.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, Dec 20, 2023 at 10:33=E2=80=AFPM Junwen Wu wrote= : > > >>I think we'd better use if (!on_rt_rq(rt_se)) > >> > >> + update_stats_wait_end_rt(rt_rq, rt_se); > >> > hi, Yafang.when execute update_stats_dequeue_rt, rt_se->on_rq is still 0,= util dequeue_rt_stack, > the method is not effect. Ah, you are right. > I this we can use if (p && p !=3D rq->curr) /*Mark the end of the wait pe= riod if dequeueing task*/ Agreed. > because schedstats is not supported for rt group,we only need to update r= t_se that is realy task. > -- > Best regards > --=20 Regards Yafang