Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.3 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 26437C4361B for ; Wed, 9 Dec 2020 11:08:25 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 B804F2336F for ; Wed, 9 Dec 2020 11:08:24 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org B804F2336F Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.intel.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date:Message-ID:From: References:To:Subject:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=k+oX1zi+uup5Ha9kc1KFCRUrCFoU0BBAHvEGHxnoLVE=; b=d/ulWrqPP6D/WfznAJPboeiKT zXObwyG6vioHv49xSdvWwfHvKRU8tXLuYJdxUZsxUcsucYp0s92cJ/b8KfYJ628RhD87QqLUZMjk2 UNgIEydvQ5zqg7PRaecSnwgQZnHMICYFvoVAhvr9r2C5oWOQmTg96YfHJfp/6ZEd26dJ0Dbi41xR7 DQN2leiCj++O5k7YKDHFksaX5aQjQjzWbVn4x0G3Du/M5LsmzumII4Lw8QdL01I0A+naWZAql8iCI zqg0C5gWKNrKcdjL32pVXlURG9OIs3/yPjYhrvJ/l3EQy+6N70IvYR6+wAObE/v+VFn1WQ1Ty6iqB Rh3KzU6eA==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kmxJX-0005Sm-6p; Wed, 09 Dec 2020 11:07:19 +0000 Received: from mga03.intel.com ([134.134.136.65]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kmxJT-0005RC-RY for linux-arm-kernel@lists.infradead.org; Wed, 09 Dec 2020 11:07:17 +0000 IronPort-SDR: zMfWg/effGrjik7GdM4WvkNEc0U7Bp5pFITFovvx8VvPhSIC8EkivsfVBxEBe+UoVvT99LxXYS IR8DKS+CSDhw== X-IronPort-AV: E=McAfee;i="6000,8403,9829"; a="174177924" X-IronPort-AV: E=Sophos;i="5.78,405,1599548400"; d="scan'208";a="174177924" Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Dec 2020 03:07:14 -0800 IronPort-SDR: yZa7ZtHtUe6//RozZZ56tglrZmSEcywDG+CV72UCg22NMhAhNUbteiTiJ8aaK3Dy0oNI6oXlw9 WOtCH0LUz+Dg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.78,405,1599548400"; d="scan'208";a="368145092" Received: from cli6-desk1.ccr.corp.intel.com (HELO [10.239.161.125]) ([10.239.161.125]) by fmsmga004.fm.intel.com with ESMTP; 09 Dec 2020 03:07:11 -0800 Subject: Re: [PATCH 2/4] sched/fair: Move avg_scan_cost calculations under SIS_PROP To: Mel Gorman References: <20201208153501.1467-1-mgorman@techsingularity.net> <20201208153501.1467-3-mgorman@techsingularity.net> <3255625e-fa92-dc09-9fab-5621122f4af0@linux.intel.com> <20201209090507.GM3371@techsingularity.net> From: "Li, Aubrey" Message-ID: <14963d1e-02ea-c298-d6b4-2db637913ee3@linux.intel.com> Date: Wed, 9 Dec 2020 19:07:11 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.9.0 MIME-Version: 1.0 In-Reply-To: <20201209090507.GM3371@techsingularity.net> Content-Language: en-US X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201209_060716_077907_151B2E14 X-CRM114-Status: GOOD ( 12.38 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Barry Song , Juri Lelli , Vincent Guittot , Peter Ziljstra , LKML , Ingo Molnar , Valentin Schneider , Linux-ARM 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 2020/12/9 17:05, Mel Gorman wrote: > On Wed, Dec 09, 2020 at 01:28:11PM +0800, Li, Aubrey wrote: >>>> nr = div_u64(span_avg, avg_cost); >>>> else >>>> nr = 4; >>>> - } >>>> - >>>> - time = cpu_clock(this); >>>> >>>> - cpumask_and(cpus, sched_domain_span(sd), p->cpus_ptr); >>>> + time = cpu_clock(this); >>>> + } >>>> >>>> for_each_cpu_wrap(cpu, cpus, target) { >>>> if (!--nr) >> >> nr is the key of this throttling mechanism, need to be placed under sched_feat(SIS_PROP) as well. >> > > It isn't necessary as nr in initialised to INT_MAX if !SIS_PROP. >If !SIS_PROP, nr need to -1 then tested in the loop, instead of testing directly. But with SIS_PROP, need adding a test in the loop. Since SIS_PROP is default true, I think it's okay to keep the current way. Thanks, -Aubrey _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel