lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAJZ5v0hPZ2q+6aGYtx7oouyUUPVv4wj_5NXkUL_7zL44E1iGmw@mail.gmail.com>
Date:   Tue, 2 Apr 2019 09:56:05 +0200
From:   "Rafael J. Wysocki" <rafael@...nel.org>
To:     Kimberly Brown <kimbrownkd@...il.com>
Cc:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        "Rafael J. Wysocki" <rafael@...nel.org>,
        Ingo Molnar <mingo@...hat.com>,
        Peter Zijlstra <peterz@...radead.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2 7/8] cpufreq: schedutil: Replace default_attrs field
 with groups

On Tue, Apr 2, 2019 at 4:51 AM Kimberly Brown <kimbrownkd@...il.com> 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 <kimbrownkd@...il.com>

Ackedy-by: Rafael J. Wysocki <rafael.j.wysocki@...el.com>

> ---
>  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
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ