Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp1053015yba; Tue, 2 Apr 2019 01:01:32 -0700 (PDT) X-Google-Smtp-Source: APXvYqyjsltR/tWfN+f87ZgBZiV52qCXzXbk3wOfzxaQbypM5ccPhhL6T8Sv/XDyITIcbC81XRmu X-Received: by 2002:a17:902:266:: with SMTP id 93mr69970454plc.161.1554192092722; Tue, 02 Apr 2019 01:01:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554192092; cv=none; d=google.com; s=arc-20160816; b=Tw4QhEhLqOK96pMOYgapeWbwhRZL4i3Yvay8b6JTqsaq3U/1kMBo1Sdjabglo2c1EQ HME+spdgUSSPoEtri6KpH+siJ2pz0RZ+fguvXCSGsL8vwAK93K3j6x92Y1YGbvop5RwF tO9JxDb+HLy0Wwnqw9ocmgre+qdFsvZHusI3ze9Xd6QzRuZ6AULSQgPFxxAvo5Wt3Dby LDNkSl5FujJYFTOvP//GHqbrCV3YNN6Ghb7BunPLUS5sUQboK5heUgssSXhI2mPZAUKT UpEGqwaN5a1qg1OJ8SVTgh4mv9X/y7VjxAUJSg9Bnnw/KPKk2wsMwCPs7FOa9lY8s6yx peEQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version; bh=YxZt69luV57N76FSX+J4AEY/lLKOcrkiu5B1vhb9OD8=; b=Z1xuXPTVNw03tSTp/y+bZZ/oV3agZ3mz0wP3+sBDQJmkbZxCIrvUN2hWN3sERn288A 2UQV2jyeAezwBQqBeWifiwP/yqphax33+hEpxAH8heumlYTgJZp3UwNK6Mjvx2WdKnxZ jX/rlZ2pfVdYvx1FonyyC8FPNArg1m2v+RdG9luvvq9EnW2jcfQ0eTpYgQwHNlujDUoA Cqf61jp9XZpHb0ZYpCpEvDIn58H1ZwwbdCP2aThNwhzsLW+3Wz6p69dvFMY0SZFCr2Qj cN952kzNoFZBhx10tEaJohj5r2PoqHt9Wu7iEEXS3IlCOV1AADZow6cwzkhLaxiniKUm ikfA== 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e6si10886662pgb.435.2019.04.02.01.01.16; Tue, 02 Apr 2019 01:01:32 -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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728896AbfDBH4U (ORCPT + 99 others); Tue, 2 Apr 2019 03:56:20 -0400 Received: from mail-oi1-f195.google.com ([209.85.167.195]:42497 "EHLO mail-oi1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725884AbfDBH4T (ORCPT ); Tue, 2 Apr 2019 03:56:19 -0400 Received: by mail-oi1-f195.google.com with SMTP id w139so9665345oie.9 for ; Tue, 02 Apr 2019 00:56:18 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=YxZt69luV57N76FSX+J4AEY/lLKOcrkiu5B1vhb9OD8=; b=IUuyAN9a+FCVH3gn3/qetmTiwcTRV1qDQmFuyJ40KXvMkSMeVeQsdeV9hPR5Kcck86 PEwrmlv+JAN/hkCpTxxmOD+BZzxjX0nBWaH8zBdbOtlkvrsh17soETbrXdJ3kP0KJmZf b701XyqFlPpdnndJ1YcTevRLE9WgkyxStuGbfYSYAiQwAUXEzSTkH6Kw6fQZaCyEKKhN MnkhGRw0miuYKCW5WtpowueltuGT6+T5qb+IUzs3W2+Pqbkjs+JZs2Y/r6HCgrUc4q+S Q5GTF863/73SO/JOLivoFjAypSg9CL2q8QRV41KhIlbXOIsoqR4BNQ1bmt6mcZEre0B+ m6tw== X-Gm-Message-State: APjAAAUYqbI4JfBtKzYxaBMINTuR4EvgrMTtJzpOQCKLfGzYEcQpMsPD BtXO/YDZY7jCi0niBDVKkWZwcgITeOe3Yc/55v0= X-Received: by 2002:aca:8d3:: with SMTP id 202mr16027040oii.76.1554191778427; Tue, 02 Apr 2019 00:56:18 -0700 (PDT) MIME-Version: 1.0 References: <20190322201440.GA30814@ubu-Virtual-Machine> <18a50bab72e6bd326250b2bd5b5a4b414351815d.1554151487.git.kimbrownkd@gmail.com> In-Reply-To: <18a50bab72e6bd326250b2bd5b5a4b414351815d.1554151487.git.kimbrownkd@gmail.com> From: "Rafael J. Wysocki" Date: Tue, 2 Apr 2019 09:56:05 +0200 Message-ID: Subject: Re: [PATCH v2 7/8] cpufreq: schedutil: Replace default_attrs field with groups To: Kimberly Brown Cc: Greg Kroah-Hartman , "Rafael J. Wysocki" , Ingo Molnar , Peter Zijlstra , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Apr 2, 2019 at 4:51 AM Kimberly Brown wrote: > > The kobj_type default_attrs field is being replaced by the > default_groups field. Replace sugov_tunables_ktype's default_attrs field > with default groups. Change "sugov_attributes" to "sugov_attrs" and use > the ATTRIBUTE_GROUPS macro to create sugov_groups. > > This patch was tested by setting the scaling governor to schedutil and > verifying that the sysfs files for the attributes in the default groups > were created. > > Signed-off-by: Kimberly Brown Ackedy-by: Rafael J. Wysocki > --- > kernel/sched/cpufreq_schedutil.c | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) > > diff --git a/kernel/sched/cpufreq_schedutil.c b/kernel/sched/cpufreq_schedutil.c > index 5c41ea367422..148b60c8993d 100644 > --- a/kernel/sched/cpufreq_schedutil.c > +++ b/kernel/sched/cpufreq_schedutil.c > @@ -598,13 +598,14 @@ rate_limit_us_store(struct gov_attr_set *attr_set, const char *buf, size_t count > > static struct governor_attr rate_limit_us = __ATTR_RW(rate_limit_us); > > -static struct attribute *sugov_attributes[] = { > +static struct attribute *sugov_attrs[] = { > &rate_limit_us.attr, > NULL > }; > +ATTRIBUTE_GROUPS(sugov); > > static struct kobj_type sugov_tunables_ktype = { > - .default_attrs = sugov_attributes, > + .default_groups = sugov_groups, > .sysfs_ops = &governor_sysfs_ops, > }; > > -- > 2.17.1 >