Received: by 2002:a05:6a10:d5a5:0:0:0:0 with SMTP id gn37csp2729604pxb; Fri, 8 Oct 2021 14:05:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxHyYzU5x/hBIbE1IxtqoEvJIV++nVDjMFiOeG9zQx/W+sM3R6TafUBXKdsYsQp4AnvTJhk X-Received: by 2002:a17:90a:6401:: with SMTP id g1mr14844073pjj.228.1633727120149; Fri, 08 Oct 2021 14:05:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1633727120; cv=none; d=google.com; s=arc-20160816; b=OQafZnadYv/FJxoJe5Aqt8gT1+cs/4nU2K0nd+vbdEIZf7es5LX0K3dzbr2kjCVpCh ICw95CNfyKqPFm23NtbNlZ+2doH8dNkFJ+bvB/L4Zu37IaskxA2l+8s6bc6vNa7el8pv ILY0QPJn9bG5xtIBAZFO7TZNMnHBU7d4NrLI4hD5SQJXKZ10Q0YM9zf7yB7EbAjMKT/6 g00S9eeVqbNLh38vkOJ9fGEl0un74ZNm2bpLmSIZUz9PTOMetsKC1NGRQ59ux0jIN0pP 3Ui0WdvKXKavhAojPpsQjdOacHZoyOwMwTLh/nAeF8yXmPdyYSFa6QzdyGUXmudxag+G vTAw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=XJCyob/naNFIp66v1NuubO0ZrjxTyjmM346cE0DYb4k=; b=bhBiXs3HV/vRZ92Tia4FSQsRHqMd3K1QM5nyr83TkUNEdm58Fty7dxBKsfcKu7p2ox Yf4AMmGgwMXGRczBcBodjHzv4KUogtzQ5pYoRiABcmo1GLMwB90f8GfLZAgIMrZye7Hv s+fIKXf/cDVB0w7JOSogQVlEiRYBEAUqBKTYYMHVY68RzNRxGFLlAMOs/v8Q+NpEWKE6 rmNeSLGsx9qsQGg/6z7x9eT0/7YG1gJ9RXxTuzV+yNAT3Ae325fazAQxCk16+V7tW6lj xVCeywy8UZOxvO1oQ4saIUc7OneLpdfRILiVNj+w1Gs8fDNPNBhcrbmrnmCwz0orc0hk cHwQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=DMbN5ABQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f12si480151pjq.115.2021.10.08.14.05.06; Fri, 08 Oct 2021 14:05:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=DMbN5ABQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243244AbhJHVGN (ORCPT + 99 others); Fri, 8 Oct 2021 17:06:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54072 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231506AbhJHVGH (ORCPT ); Fri, 8 Oct 2021 17:06:07 -0400 Received: from mail-yb1-xb29.google.com (mail-yb1-xb29.google.com [IPv6:2607:f8b0:4864:20::b29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 40C4EC061570 for ; Fri, 8 Oct 2021 14:04:12 -0700 (PDT) Received: by mail-yb1-xb29.google.com with SMTP id g6so23838411ybb.3 for ; Fri, 08 Oct 2021 14:04:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=XJCyob/naNFIp66v1NuubO0ZrjxTyjmM346cE0DYb4k=; b=DMbN5ABQdgA8hTg3sZAeY9/flqtV6HZEXexCScbjhg6wkqZ8May85BF2yJvJ8eIpjt 3mULY0ITrwjFZHUj+TsHbYbf/VTh8CI1xDP89VyHXlpT3AywQFdrPLbTPGVVrcM7Qtxp T3bfq52r7P6xYbzBNvNxE/zSyvz5NdG0VGgyfK23LtHNqUkm3cjW4aLjkrCG46H7X1C+ qEczrGD+sgHmUty76/Pjy+ET0d32qyihe7QP4iH6WTnjK0+60TokmRANyMUCy+4U+LO1 L1HuJ4Nj2LBDgtBWJoeWwybAFZYgjicxntniNcrSKLllMlJKZuGLWxtcm36TxvNjmjrh 61lQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=XJCyob/naNFIp66v1NuubO0ZrjxTyjmM346cE0DYb4k=; b=UoNdNpJqKoVSUFTFbidw7i+DMllrP9J6nWQicVJCHWBXQV9nNfezHpLYEwBu3L2FaO kXlQ+afMf4YEp9TJ2P4ZhiCf/MwCKLYwuxEH2p15GCTRRjG4WuONnjwlbzhS/+fi+JaB xGWv/qSf6gg5opbwjlbvY5nMHAdZYNb+QjGAU0PZD8IJMmz3zIUZNxf54uXhhbdlByYH Cof4ZgYeDEfwr68A8UzKuPiUj8De9oiz9kbLBK0o1r0rVuCWJ5MkKDkoMXSP2QuYTr0/ MKdprNY5EBp8mDbsViW7E1naAWZJytK8w3y6XQiB6x4T3YrCbm89jfuXb7Rq5EJ1YLx5 1smQ== X-Gm-Message-State: AOAM532OVuMSLCAQcIZNIMimR/47uwDnYbe0WWLb4uciXI1YRzlDF07E 9UbKYRg8CvzoUq7WLU5G/BGQRaFDcu5AKhepg32qcA== X-Received: by 2002:a25:b7d3:: with SMTP id u19mr5644868ybj.158.1633727051142; Fri, 08 Oct 2021 14:04:11 -0700 (PDT) MIME-Version: 1.0 References: <20211008000825.1364224-1-joshdon@google.com> In-Reply-To: <20211008000825.1364224-1-joshdon@google.com> From: Josh Don Date: Fri, 8 Oct 2021 14:04:00 -0700 Message-ID: Subject: Re: [PATCH] sched/core: forced idle accounting To: Ingo Molnar , Peter Zijlstra , Juri Lelli , Vincent Guittot Cc: Dietmar Eggemann , Steven Rostedt , Ben Segall , Mel Gorman , Daniel Bristot de Oliveira , Joel Fernandes , Vineeth Pillai , Hao Luo , linux-kernel Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Oct 7, 2021 at 5:08 PM Josh Don wrote: > > @@ -6051,6 +6071,13 @@ static void sched_core_cpu_deactivate(unsigned int cpu) > core_rq->core_forceidle = rq->core_forceidle; > core_rq->core_forceidle_seq = rq->core_forceidle_seq; > > + /* > + * Accounting edge for forced idle is handled in pick_next_task(). > + * Don't need another one here, since the hotplug thread shouldn't > + * have a cookie. > + */ > + core_rq->core_forceidle_start = 0; > + > /* install new leader */ > for_each_cpu(t, smt_mask) { > rq = cpu_rq(t); Realized there needs to be a similar edge in sched_core_flip(). I'll include that in a v2, after seeing if there are any other comments on this patch.