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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAAhV-H6VX5Bbmv4r8O=LbnZVWvVRr1GNUDs=6uHx337AdD52Fw@mail.gmail.com>
Date:   Tue, 24 May 2022 11:04:20 +0800
From:   Huacai Chen <chenhuacai@...nel.org>
To:     Haowen Bai <baihaowen@...zu.com>
Cc:     Ard Biesheuvel <ardb@...nel.org>,
        linux-efi <linux-efi@...r.kernel.org>,
        LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] LoongArch: Fix unsigned function returning negative constant

Hi, Haowen,

On Tue, May 24, 2022 at 10:47 AM Haowen Bai <baihaowen@...zu.com> wrote:
>
> The function set_virtual_map has an unsigned return type, but returns a
> negative constant to indicate an error condition. So we change unsigned
> to int.
Your patch is correct, but original hasn't been upstream, I don't
know how to handle it.

Huacai
>
> Signed-off-by: Haowen Bai <baihaowen@...zu.com>
> ---
>  arch/loongarch/kernel/efi.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/loongarch/kernel/efi.c b/arch/loongarch/kernel/efi.c
> index 69ebdd4220ec..f9fdeb1ae358 100644
> --- a/arch/loongarch/kernel/efi.c
> +++ b/arch/loongarch/kernel/efi.c
> @@ -102,7 +102,7 @@ static void __init fix_efi_mapping(void)
>   * in @memory_map whose EFI_MEMORY_RUNTIME attribute is set. Those descriptors
>   * are also copied to @runtime_map, and their total count is returned in @count.
>   */
> -static unsigned int __init set_virtual_map(void)
> +static int __init set_virtual_map(void)
>  {
>         int count = 0;
>         unsigned int size;
> --
> 2.7.4
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ