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: <YoS+FZMvUJcnhJhk@localhost.localdomain>
Date:   Wed, 18 May 2022 11:36:21 +0200
From:   Oscar Salvador <osalvador@...e.de>
To:     Miaohe Lin <linmiaohe@...wei.com>
Cc:     akpm@...ux-foundation.org, willy@...radead.org, vbabka@...e.cz,
        dhowells@...hat.com, neilb@...e.de, apopple@...dia.com,
        david@...hat.com, surenb@...gle.com, peterx@...hat.com,
        naoya.horiguchi@....com, linux-mm@...ck.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH 05/15] mm/swap: print bad swap offset entry in
 get_swap_device

On Mon, May 09, 2022 at 09:14:06PM +0800, Miaohe Lin wrote:
> If offset exceeds the si->max, print bad swap offset entry to help debug
> the unexpected case.
> 
> Signed-off-by: Miaohe Lin <linmiaohe@...wei.com>

Reviewed-by: Oscar Salvador <osalvador@...e.de>

> ---
>  mm/swapfile.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/mm/swapfile.c b/mm/swapfile.c
> index 0aee6286d6a7..d4b81ca887c0 100644
> --- a/mm/swapfile.c
> +++ b/mm/swapfile.c
> @@ -1272,6 +1272,7 @@ struct swap_info_struct *get_swap_device(swp_entry_t entry)
>  out:
>  	return NULL;
>  put_out:
> +	pr_err("%s: %s%08lx\n", __func__, Bad_offset, entry.val);
>  	percpu_ref_put(&si->users);
>  	return NULL;
>  }
> -- 
> 2.23.0
> 
> 

-- 
Oscar Salvador
SUSE Labs

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ