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: <2b75a26f-6c8b-40b3-8ea7-d2cf275b58fe@I-love.SAKURA.ne.jp>
Date: Wed, 20 Mar 2024 18:42:52 +0900
From: Tetsuo Handa <penguin-kernel@...ove.SAKURA.ne.jp>
To: Oscar Salvador <osalvador@...e.de>
Cc: Andrew Morton <akpm@...ux-foundation.org>, linux-kernel@...r.kernel.org,
        linux-mm@...ck.org, Michal Hocko <mhocko@...e.com>,
        Vlastimil Babka <vbabka@...e.cz>, Marco Elver <elver@...gle.com>,
        Andrey Konovalov <andreyknvl@...il.com>,
        Alexander Potapenko <glider@...gle.com>,
        syzbot+41bbfdb8d41003d12c0f@...kaller.appspotmail.com
Subject: Re: [PATCH v2 1/2] mm,page_owner: Fix refcount imbalance

On 2024/03/20 14:49, Oscar Salvador wrote:
> This should have the follwing on top:
> 
>  diff --git a/mm/page_owner.c b/mm/page_owner.c
>  index 2613805cb665..e477a71d6adc 100644
>  --- a/mm/page_owner.c
>  +++ b/mm/page_owner.c
>  @@ -222,8 +222,11 @@ static void dec_stack_record_count(depot_stack_handle_t handle,
>   {
>          struct stack_record *stack_record = __stack_depot_get_stack_record(handle);
>   
>  -       if (stack_record)
>  -               refcount_sub_and_test(nr_base_pages, &stack_record->count);
>  +       if (!stack_record)
>  +               return;
>  +
>  +       if (refcount_sub_and_test(nr_base_pages, &stack_record->count))
>  +               WARN(1, "%s refcount went to 0 for %u handle\n", __func__, handle);
>   }
> 
> 

That fixed this problem. Thank you.

-------- Forwarded Message --------
Date: Wed, 20 Mar 2024 01:31:03 -0700
In-Reply-To: <4362246e-d804-43de-800b-a7840b70919a@...ove.SAKURA.ne.jp>
Message-ID: <000000000000410e3b061413692b@...gle.com>
Subject: Re: [syzbot] [mm?] WARNING: refcount bug in __reset_page_owner
From: syzbot <syzbot+98c1a1753a0731df2dd4@...kaller.appspotmail.com>
To: linux-kernel@...r.kernel.org, penguin-kernel@...ove.sakura.ne.jp, syzkaller-bugs@...glegroups.com

Hello,

syzbot has tested the proposed patch and the reproducer did not trigger any issue:

Reported-and-tested-by: syzbot+98c1a1753a0731df2dd4@...kaller.appspotmail.com

Tested on:

commit:         a4145ce1 Merge tag 'bcachefs-2024-03-19' of https://ev..
git tree:       upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=131b1d66180000
kernel config:  https://syzkaller.appspot.com/x/.config?x=9f47e8dfa53b0b11
dashboard link: https://syzkaller.appspot.com/bug?extid=98c1a1753a0731df2dd4
compiler:       gcc (Debian 12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40
patch:          https://syzkaller.appspot.com/x/patch.diff?x=13972985180000

Note: testing is done by a robot and is best-effort only.


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ