Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp703918ybi; Wed, 17 Jul 2019 03:35:29 -0700 (PDT) X-Google-Smtp-Source: APXvYqzI97t+UzxxeinukLG873lR+FMKHOwgWC1cs7CFlXlI5s7fVExnKlWv1O1Sn/iPUgat0xsf X-Received: by 2002:a17:902:2889:: with SMTP id f9mr40160803plb.230.1563359729374; Wed, 17 Jul 2019 03:35:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1563359729; cv=none; d=google.com; s=arc-20160816; b=zV2v0XXT5b9iRc8KIyM/Alq+PcfCCpL0+Qn+ZMHNCjitxUJ4euQhTMKiZBHvqnkQ8K 1ZCpX9Xt8JTi5Zs/fteR3BQBSBR7K/4QpaK5IA9tqzGCFeT5pEvIG28DrbBjbmpG/tp3 ftV6x8dSuwRdfeecR6zwbck0X4juj5qeSr0Nj9k+prK0PO6zD8EL0akA3CmtdSgj1BI+ hLGAECuFqNND0okBdG6QtNRSyo/QYGxgUCvnK85O1Tk/PVUtU8YQM0/W+SQOCvrhT7Iy A3LnUx0A09QJHsy3iNb5eVWNot7A4Wq9fd0sC/+gowHh/YhUgmIoQgPCPSnFtTOpi2NI AqcA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=S2McoLzKqqkDIb1rRDE8NxKvbm2tGRquQgQvuYsQVBs=; b=eAavCGHFUSUUcyhlnwEe8Zqbh9ls20y0YfVkqKrWRP7LFQjUHraMuxcAVRImvPncQI DFSBkRW6V3teMm3PUnvWX7y7/kQjeHFdX/R6vu+8btepUbYEjBBaYaZ9seOiBLc8EKl4 sQqNPyHzuwwalSbcFY8mLT1/omj6pE6334ZMGTLapCelnSOU0PFHp/CFTXGq6O1DnbY8 Qm5HRw/GREX+OwkaD0NhUkCQHmairX24UNu9T5UIvHZi2IS/hDwDWwm6ldDLvz4qBteO kfE3jKQpSdekqsZ5+fGRfzrqWP1gO4INEUZlArL5fdX7HmnT69GZ66GsFHfExsQ7V1xV vl0Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=kDjuKli8; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c11si22556359pgk.383.2019.07.17.03.35.13; Wed, 17 Jul 2019 03:35:29 -0700 (PDT) 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=@linaro.org header.s=google header.b=kDjuKli8; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730971AbfGQKeA (ORCPT + 99 others); Wed, 17 Jul 2019 06:34:00 -0400 Received: from mail-pg1-f196.google.com ([209.85.215.196]:32960 "EHLO mail-pg1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726284AbfGQKeA (ORCPT ); Wed, 17 Jul 2019 06:34:00 -0400 Received: by mail-pg1-f196.google.com with SMTP id f20so1721780pgj.0 for ; Wed, 17 Jul 2019 03:34:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=S2McoLzKqqkDIb1rRDE8NxKvbm2tGRquQgQvuYsQVBs=; b=kDjuKli8rFJC6Xm1qb2ogZmYQDsbaHOj9roK9i8Yne6XsPmZUdhPoe6GX7h6/B0LU0 YzKTXbDiezDSQarA4K8V/oz6W246ISnaoSYnrBVE/XfVieYzeyM1We1wPWtPc3vSZ8Mi P5YG6I9ad1owLaAKCSiAXHeIYvDLh0v+sA/QNBOCJHPxg7n/3EPFJQdImXEWVYQchrs3 uHFAN1rwDbfMJXyVr9whhfAmSg6oIY8j3bc/HV63n7F/vincPNTHJLcLEWxN4WA8Djc2 3U4JkQ46ZN3k77TorB4iBHA7naEKHiFcsREPtv1iryBiVwvsl7K/J/XKYVDMqHtPVMdy VolQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=S2McoLzKqqkDIb1rRDE8NxKvbm2tGRquQgQvuYsQVBs=; b=KuXKmqD5rQ76rksjQB0aliJd1qmaXfI05tC0Y5P5Ag2p1tLfvIVdIGST2w6Knd9sLF o8dfFgIp9MysaNsWBo9cNYaiPKweutN0E7OiRgmh/XLGnP5tfvSjKDxXMXMfD3dKyShe 3LUDzyzGJblI+JYe6PYAYNRFx2c+rzUY2ChgtaIsHVMyURudPO86unR/jswS6FiiyZ4I rKRu38VphzAkBAQhz99Tk3fR0tRkXjJ64nujjh8TbAJJUQSKpNQ9rrZQjzqkilk1jsxZ Ck1hbpkI/x2Xf9/0w9e/2UBZetMOM/osTogCFbPRc701HV6r9UPOrjC2tBnfJP9r43wu bxRg== X-Gm-Message-State: APjAAAU5itO/pmdKOX7mbrPcCz4ZiTtSq2Zu3bm4uX8qmZXjbRqPG072 VZpBy8zHkq0fZIPanuRGTHumjIEb8D0= X-Received: by 2002:a17:90a:77c5:: with SMTP id e5mr40862060pjs.109.1563359639783; Wed, 17 Jul 2019 03:33:59 -0700 (PDT) Received: from localhost ([122.172.28.117]) by smtp.gmail.com with ESMTPSA id p68sm33370269pfb.80.2019.07.17.03.33.58 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 17 Jul 2019 03:33:59 -0700 (PDT) Date: Wed, 17 Jul 2019 16:03:56 +0530 From: Viresh Kumar To: Ingo Molnar , Peter Zijlstra Cc: linux-kernel@vger.kernel.org, Vincent Guittot Subject: Re: [PATCH] sched/fair: Introduce fits_capacity() Message-ID: <20190717103356.gb2guwxy5joko53e@vireshk-i7> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20180716-391-311a52 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04-06-19, 12:31, Viresh Kumar wrote: > The same formula to check utilization against capacity (after > considering capacity_margin) is already used at 5 different locations. > > This patch creates a new macro, fits_capacity(), which can be used from > all these locations without exposing the details of it and hence > simplify code. > > All the 5 code locations are updated as well to use it.. > > Signed-off-by: Viresh Kumar > --- > kernel/sched/fair.c | 14 +++++++------- > 1 file changed, 7 insertions(+), 7 deletions(-) @Peter: Do you suggest any modifications to this patch? Do I need to resend it ? -- viresh