Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp8941636ybl; Fri, 17 Jan 2020 03:49:10 -0800 (PST) X-Google-Smtp-Source: APXvYqx2Bj5Xw6izMKrSCQ1IGofXV/bVlCanoezOaTPKYnUNXzDn/OKMTAJHH0GMAArj94bsiTKk X-Received: by 2002:a9d:750b:: with SMTP id r11mr5883681otk.209.1579261750603; Fri, 17 Jan 2020 03:49:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1579261750; cv=none; d=google.com; s=arc-20160816; b=0w0//TkVI/7w+AG24Ii009ppUhtr75IziwFTqWe4uGMxvlSy7kmLjp+lLoUDhPQY1H t46f4WQbmYf0vi7pX0PwwsOdhe8UR5qodj121LYo/YYvTwSQk0SMudEzFX4wCURrdHeD sIHFtW9qNmAZrNASEvDtLsETjCSovba9vepT4lHX503Tx5TT+4rA55zJdidJ0IHcLiLP nGyzH5mX7fOc2lutf2sWYXSauuglPjaWBBxdiKMk4moKpVpAjb6C2KSxDQCxB9QOVWU9 F8+pNQgGEkyhzQRr/RSNsGT6dyQXGwGbMd1gF1KLVD5VpQDEpSCSnmE2JxnB7+5kK7af O+ZQ== 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=qqkxnrx3HzuDPmPjQfwC1GI4loEmDbDbTR3bN9P7ZZ0=; b=xhM+Cto74HfoIIeHcYs0yYhCDArGyuHHEzME3TdVcR2IGBdrc3L8E+yNTzxKSh4yzE jV1dSTfhjhTiQki5qTT/r400AWWwhPPBBNuH9FzfPkoAsPiBv27xVwdykVYu0+BeRICp fPzTsEIqTkpTMUVHGec7S6gPUeMq+On6+ofUgLvX5l8N/m2Htb2YQ9Oa2dWTu9djNypP SvIaRCCSMjkPP4R9p4tqbrvGdpTKmB1oVftM/9cY98LEdImYgtLNTrJu80UaJxYYseas dOn5nLZfYjZQVv0h7nVTcMyuIevuDbRv54BSoYEs7ntjfuT/lsT/59ExtYKgAbvfz1TD s1lg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=GkYwQUYO; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e3si15585989otp.286.2020.01.17.03.48.58; Fri, 17 Jan 2020 03:49:10 -0800 (PST) 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=@google.com header.s=20161025 header.b=GkYwQUYO; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727008AbgAQLsF (ORCPT + 99 others); Fri, 17 Jan 2020 06:48:05 -0500 Received: from mail-wr1-f48.google.com ([209.85.221.48]:40491 "EHLO mail-wr1-f48.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726689AbgAQLsF (ORCPT ); Fri, 17 Jan 2020 06:48:05 -0500 Received: by mail-wr1-f48.google.com with SMTP id c14so22397352wrn.7 for ; Fri, 17 Jan 2020 03:48:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=qqkxnrx3HzuDPmPjQfwC1GI4loEmDbDbTR3bN9P7ZZ0=; b=GkYwQUYOrsUVmzU0u/ktmDP996TPqL3/mEQu22A/PAwN9HhXEWUDTpXEcDYzyMKX+o 2hj3xTydd1rjb3EOG9TI5P2lsgvo9gagL4MtLZaG/wEX3TVqflON8Nqy4oBqBoF4Xovc ddgItAXXurbywiUYt2Tai9Na/7RpRYTqlOmPOfQ2R7ptnDA4rEK0TSnYdECjqjSPh4PF 8djpOoJwynZv/Il6EJ6gCybwMD96BADwXo346xhmAUfkHepemK1YLBbYNEieSVgNJb4W Wc02Z0NopIpLD+7ydzlddUy2fdC86uAud1w6Ueel1zRYxbjJWT5Jw7pfT18HK0JlPDCt Hi4g== 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=qqkxnrx3HzuDPmPjQfwC1GI4loEmDbDbTR3bN9P7ZZ0=; b=hHaWQJ2S4iCcHBNQ4k8UhM9myN38Q2gfRgx5ZP8N0+soLPXKXZeFJ1YpoqAMJL8v+M imCHkgPkhDkLNhMsHlDMEOL1G0OvLVoT/H1i40hHGwUgHrvw7bFAfDy1KtaJPjtFmgr5 N5+/2P19NCNlGVNam+WGKlo51vkUdHymtgCWirKcVszZHJQJW4hTvk60biv5P582yRfd f8ZykHaKuDehz+YhyA4/CRYsc49RxC7AZZ78vq8u84kJJbJ+8IG1ACZRFak6XBaksP1R d0/vYZbik0IHYw25c419YCNX5areAwRJonwXukVVmguXD5W+YGgQd7pX0Tl1LMMT5VFH SBbA== X-Gm-Message-State: APjAAAVZEstnwBsPlazXZnQaQsjqArjpw97Foupzt61jT+0fVWVw6Z4a ewqYD3z7Pe/pslK6jVcbtswU3A== X-Received: by 2002:adf:eb8e:: with SMTP id t14mr2603060wrn.384.1579261682747; Fri, 17 Jan 2020 03:48:02 -0800 (PST) Received: from google.com ([2a00:79e0:d:110:d6cc:2030:37c1:9964]) by smtp.gmail.com with ESMTPSA id i16sm9709716wmb.36.2020.01.17.03.48.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 Jan 2020 03:48:02 -0800 (PST) Date: Fri, 17 Jan 2020 11:47:58 +0000 From: Quentin Perret To: Thara Gopinath Cc: mingo@redhat.com, peterz@infradead.org, ionela.voinescu@arm.com, vincent.guittot@linaro.org, dietmar.eggemann@arm.com, rui.zhang@intel.com, daniel.lezcano@linaro.org, viresh.kumar@linaro.org, linux-kernel@vger.kernel.org, amit.kachhap@gmail.com, javi.merino@kernel.org, kernel-team@android.com Subject: Re: [Patch v8 7/7] sched/fair: Enable tuning of decay period Message-ID: <20200117114758.GB219309@google.com> References: <1579031859-18692-1-git-send-email-thara.gopinath@linaro.org> <1579031859-18692-8-git-send-email-thara.gopinath@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1579031859-18692-8-git-send-email-thara.gopinath@linaro.org> 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 On Tuesday 14 Jan 2020 at 14:57:39 (-0500), Thara Gopinath wrote: > +static int __init setup_sched_thermal_decay_shift(char *str) > +{ > + int _shift; > + > + if (kstrtoint(str, 0, &_shift)) > + pr_warn("Unable to set scheduler thermal pressure decay shift parameter\n"); Nit: looking at kstrtoint() it seems that _shift will be left unmodified upon failure. To avoid feeding a random value to clamp() below, perhaps initialize _shift to 0 ? > + sched_thermal_decay_shift = clamp(_shift, 0, 10); > + return 1; > +} Thanks, Quentin