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] [day] [month] [year] [list]
Date:   Mon, 7 Jun 2021 15:59:22 +0200
From:   "Rafael J. Wysocki" <rafael@...nel.org>
To:     Jing Xiangfeng <jingxiangfeng@...wei.com>
Cc:     "Rafael J. Wysocki" <rjw@...ysocki.net>,
        Len Brown <lenb@...nel.org>,
        "Zhang, Rui" <rui.zhang@...el.com>,
        Hanjun Guo <guohanjun@...wei.com>,
        ACPI Devel Maling List <linux-acpi@...r.kernel.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2] ACPI: FPDT: Add the missed acpi_put_table() in acpi_init_fpdt()

On Wed, Jun 2, 2021 at 1:44 PM Jing Xiangfeng <jingxiangfeng@...wei.com> wrote:
>
> acpi_init_fpdt() misses to call acpi_put_table() in an error path. Add
> the missed function call to fix it.
>
> Fixes: d1eb86e59be0 ("ACPI: tables: introduce support for FPDT table")
> Signed-off-by: Jing Xiangfeng <jingxiangfeng@...wei.com>
> Acked-by: Zhang Rui <rui.zhang@...el.com>
> ---
> v1 -> v2:
> - Collect Acked-by tag by Zhang Rui.
> - retitle the subject as suggested by Hanjun Guo.
> ---
>  drivers/acpi/acpi_fpdt.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/acpi/acpi_fpdt.c b/drivers/acpi/acpi_fpdt.c
> index a89a806a7a2a..4ee2ad234e3d 100644
> --- a/drivers/acpi/acpi_fpdt.c
> +++ b/drivers/acpi/acpi_fpdt.c
> @@ -240,8 +240,10 @@ static int __init acpi_init_fpdt(void)
>                 return 0;
>
>         fpdt_kobj = kobject_create_and_add("fpdt", acpi_kobj);
> -       if (!fpdt_kobj)
> +       if (!fpdt_kobj) {
> +               acpi_put_table(header);
>                 return -ENOMEM;
> +       }
>
>         while (offset < header->length) {
>                 subtable = (void *)header + offset;
> --

Applied as 5.14 material with some edits in the subject and changelog, thanks!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ