Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp3661100imm; Wed, 5 Sep 2018 04:02:38 -0700 (PDT) X-Google-Smtp-Source: ANB0VdbMxsR9c90obnbWiIyaPOB2YnixSXoZouaCRVheFVgoYDtGn0npfF9Y3LajfV6vded8MDRn X-Received: by 2002:a63:788b:: with SMTP id t133-v6mr35791038pgc.329.1536145358510; Wed, 05 Sep 2018 04:02:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536145358; cv=none; d=google.com; s=arc-20160816; b=YIgjiSEJys8Ex2p3NDg+YiLEc5xJWIU5PYeCqKHrMvhXmYjymZvb45cfN49owFkTej ZeCqRUZnhdSvEbiJdOpWIY9skV6h7ZMEcyc85TYKL+irG5P1/NVMJYgl/YQrSzFAJ8GY GjKJ3BsbfUdDXtJD1y7IyIkVuDMwN4BtyGqcIefXyg5A9JtpXEpkUr42yh/zCzf+zhxw 7GgFavcQ0FZ7QvW88ZtMQUnNNDpaVr2yTGtQCohOAnUdKt6tzd2rDTu/PqX1elRAFxKK JXb58fj/F1Tcs7DowYzNlM7kRIRNtEg8XwC9/4eWfqba1vmzDfNu6c5ABbhCEn9xC2MR CA1w== 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; bh=XXNlJCeF/EldLo3kgGYc96ZmK+t7BvsB++fKrFyH2ks=; b=mdsUUx+aPGspF2a7hqJ3q+ES/PWgs04w6/t3ZFS0XI5+kMNxBVqcJ4eWxN5aK0kMLH WGow14LzQHg9VQBgH7ORDpv9V2/yFsReaEPBs4jwemVPebw04ydOjqUGVLEbKYwCYThk mrrnEipoZaad6h/hCtz4mqJAH+plCyuqBGGiZjqUuPzlvm9TP8XvYGOnttDj4ZQNA2q1 iJoXoyUYniTpKLK4RrFDVlhtgxIDGoUapHjBVkbIBKkY2FD+TWHtwRZvgvf71gwJhaFV OA6wBciZ0LqxTuowRkFogM1lqpqCjgKH7YxQMXhoV1nrh+5aQI5NYA5A6ooYGdJ2A+mu TwNA== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h27-v6si1537492pgh.245.2018.09.05.04.02.21; Wed, 05 Sep 2018 04:02:38 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726528AbeIEPaz (ORCPT + 99 others); Wed, 5 Sep 2018 11:30:55 -0400 Received: from mail-wm0-f66.google.com ([74.125.82.66]:55349 "EHLO mail-wm0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726309AbeIEPaz (ORCPT ); Wed, 5 Sep 2018 11:30:55 -0400 Received: by mail-wm0-f66.google.com with SMTP id f21-v6so7497410wmc.5 for ; Wed, 05 Sep 2018 04:01:12 -0700 (PDT) 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=XXNlJCeF/EldLo3kgGYc96ZmK+t7BvsB++fKrFyH2ks=; b=ZX6CjlJMfrMwM1Eah12QzqTy9uGVHJKjVYbLmbObf9TQ80gMTToOY9h2kBnGwArZm1 l5bGMWkYycbtoQBjYGW3JIxbPyRWKdTc+Armz1g3Ngep0Xs9S41c+U2wNMpU50tJ/NKv 4g+0BmhAX8RtP469oHcUulO5tMUFGMTm56n5VVHf4ZvMHst4f/3H5XEW1Rhn4zlJRlgI KVWMC4CDLdMFjCQoT7N2YNPZIn7ZN9MuN2QXxI4/dkstUJjW6nqEhr3KDxRm82GzgMpM XMa6Mu/hJAP7isPhLTzSvhEgEo/mOxQgI1UNNtSo0m0JKlj+c2AuTmc6fmHvv877+jjn TZ9Q== X-Gm-Message-State: APzg51DAFTqB8tfQtOS893JuuoRint7Y32AYrRTM5Xe2qaLMYHhe+wP0 0jQcxcAzpX+nAYYaUEwAT55D1A== X-Received: by 2002:a1c:e289:: with SMTP id z131-v6mr5319453wmg.32.1536145271636; Wed, 05 Sep 2018 04:01:11 -0700 (PDT) Received: from localhost.localdomain ([151.15.227.30]) by smtp.gmail.com with ESMTPSA id 132-v6sm1838599wmd.13.2018.09.05.04.01.10 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 05 Sep 2018 04:01:10 -0700 (PDT) Date: Wed, 5 Sep 2018 13:01:08 +0200 From: Juri Lelli To: Patrick Bellasi Cc: linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, Ingo Molnar , Peter Zijlstra , Tejun Heo , "Rafael J . Wysocki" , Viresh Kumar , Vincent Guittot , Paul Turner , Quentin Perret , Dietmar Eggemann , Morten Rasmussen , Todd Kjos , Joel Fernandes , Steve Muckle , Suren Baghdasaryan , Randy Dunlap , linux-api@vger.kernel.org Subject: Re: [PATCH v4 01/16] sched/core: uclamp: extend sched_setattr to support utilization clamping Message-ID: <20180905110108.GC20267@localhost.localdomain> References: <20180828135324.21976-1-patrick.bellasi@arm.com> <20180828135324.21976-2-patrick.bellasi@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180828135324.21976-2-patrick.bellasi@arm.com> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On 28/08/18 14:53, Patrick Bellasi wrote: [...] > Let's introduce a new API to set utilization clamping values for a > specified task by extending sched_setattr, a syscall which already > allows to define task specific properties for different scheduling > classes. > Specifically, a new pair of attributes allows to specify a minimum and > maximum utilization which the scheduler should consider for a task. AFAIK sched_setattr currently mandates that a policy is always specified [1]. I was wondering if relaxing such requirement might be handy. Being util clamp a cross-class feature it might be cumbersome to always have to get current policy/params and use those with new umin/umax just to change the latter. sched_setparam already uses the in-kernel SETPARAM_POLICY thing, maybe we could extend that to sched_setattr? Not sure exposing this to userspace is a good idea though. :-/ Best, - Juri 1 - https://elixir.bootlin.com/linux/v4.19-rc2/source/kernel/sched/core.c#L4564