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: <CAJZ5v0jeGgVv8vLZnimJXcRWZNf926Ff61mT4o4kGQ48FzyYCA@mail.gmail.com>
Date:   Tue, 16 Feb 2021 15:34:27 +0100
From:   "Rafael J. Wysocki" <rafael@...nel.org>
To:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc:     Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        "Rafael J. Wysocki" <rafael@...nel.org>
Subject: Re: [PATCH 2/2] driver core: dd: remove deferred_devices variable

On Tue, Feb 16, 2021 at 3:24 PM Greg Kroah-Hartman
<gregkh@...uxfoundation.org> wrote:
>
> No need to save the debugfs dentry for the "devices_deferred" debugfs
> file (gotta love the juxtaposition), if we need to remove it we can look
> it up from debugfs itself.
>
> Cc: "Rafael J. Wysocki" <rafael@...nel.org>
> Cc: linux-kernel@...r.kernel.org
> Signed-off-by: Greg Kroah-Hartman <gregkh@...uxfoundation.org>

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

> ---
>  drivers/base/dd.c | 7 +++----
>  1 file changed, 3 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/base/dd.c b/drivers/base/dd.c
> index 9179825ff646..66c31cda5462 100644
> --- a/drivers/base/dd.c
> +++ b/drivers/base/dd.c
> @@ -55,7 +55,6 @@ static DEFINE_MUTEX(deferred_probe_mutex);
>  static LIST_HEAD(deferred_probe_pending_list);
>  static LIST_HEAD(deferred_probe_active_list);
>  static atomic_t deferred_trigger_count = ATOMIC_INIT(0);
> -static struct dentry *deferred_devices;
>  static bool initcalls_done;
>
>  /* Save the async probe drivers' name from kernel cmdline */
> @@ -310,8 +309,8 @@ static DECLARE_DELAYED_WORK(deferred_probe_timeout_work, deferred_probe_timeout_
>   */
>  static int deferred_probe_initcall(void)
>  {
> -       deferred_devices = debugfs_create_file("devices_deferred", 0444, NULL,
> -                                              NULL, &deferred_devs_fops);
> +       debugfs_create_file("devices_deferred", 0444, NULL, NULL,
> +                           &deferred_devs_fops);
>
>         driver_deferred_probe_enable = true;
>         driver_deferred_probe_trigger();
> @@ -336,7 +335,7 @@ late_initcall(deferred_probe_initcall);
>
>  static void __exit deferred_probe_exit(void)
>  {
> -       debugfs_remove_recursive(deferred_devices);
> +       debugfs_remove_recursive(debugfs_lookup("devices_deferred", NULL));
>  }
>  __exitcall(deferred_probe_exit);
>
> --
> 2.30.1
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ