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, 9 Sep 2019 10:22:54 +0200
From:   David Hildenbrand <david@...hat.com>
To:     Daniel Vetter <daniel.vetter@...ll.ch>,
        LKML <linux-kernel@...r.kernel.org>
Cc:     DRI Development <dri-devel@...ts.freedesktop.org>,
        syzbot+aaedc50d99a03250fe1f@...kaller.appspotmail.com,
        Jason Gunthorpe <jgg@...lanox.com>,
        Daniel Vetter <daniel.vetter@...el.com>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Jérôme Glisse <jglisse@...hat.com>,
        Ralph Campbell <rcampbell@...dia.com>,
        Jason Gunthorpe <jgg@...pe.ca>,
        Ira Weiny <ira.weiny@...el.com>,
        Michal Hocko <mhocko@...e.com>,
        Sean Christopherson <sean.j.christopherson@...el.com>,
        Jean-Philippe Brucker <jean-philippe@...aro.org>,
        linux-mm@...ck.org
Subject: Re: [PATCH] mm, notifier: Fix early return case for new lockdep
 annotations

On 06.09.19 19:47, Daniel Vetter wrote:
> I missed that when extending the lockdep annotations to the
> nonblocking case.
> 
> I missed this while testing since in the i915 mmu notifiers is hitting
> a nice lockdep splat already before the point of going into oom killer
> mode :-/
> 
> Reported-by: syzbot+aaedc50d99a03250fe1f@...kaller.appspotmail.com
> Fixes: d2b219ed03d4 ("mm/mmu_notifiers: add a lockdep map for invalidate_range_start/end")
> Cc: Jason Gunthorpe <jgg@...lanox.com>
> Cc: Daniel Vetter <daniel.vetter@...el.com>
> Cc: Andrew Morton <akpm@...ux-foundation.org>
> Cc: "Jérôme Glisse" <jglisse@...hat.com>
> Cc: Ralph Campbell <rcampbell@...dia.com>
> Cc: Jason Gunthorpe <jgg@...pe.ca>
> Cc: Ira Weiny <ira.weiny@...el.com>
> Cc: Michal Hocko <mhocko@...e.com>
> Cc: Daniel Vetter <daniel.vetter@...ll.ch>
> Cc: Sean Christopherson <sean.j.christopherson@...el.com>
> Cc: Jean-Philippe Brucker <jean-philippe@...aro.org>
> Cc: linux-mm@...ck.org
> Signed-off-by: Daniel Vetter <daniel.vetter@...el.com>
> ---
>  include/linux/mmu_notifier.h | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/include/linux/mmu_notifier.h b/include/linux/mmu_notifier.h
> index 5a03417e5bf7..4edd98b06834 100644
> --- a/include/linux/mmu_notifier.h
> +++ b/include/linux/mmu_notifier.h
> @@ -356,13 +356,14 @@ mmu_notifier_invalidate_range_start(struct mmu_notifier_range *range)
>  static inline int
>  mmu_notifier_invalidate_range_start_nonblock(struct mmu_notifier_range *range)
>  {
> +	int ret = 0;
>  	lock_map_acquire(&__mmu_notifier_invalidate_range_start_map);
>  	if (mm_has_notifiers(range->mm)) {
>  		range->flags &= ~MMU_NOTIFIER_RANGE_BLOCKABLE;
> -		return __mmu_notifier_invalidate_range_start(range);
> +		ret = __mmu_notifier_invalidate_range_start(range);
>  	}
>  	lock_map_release(&__mmu_notifier_invalidate_range_start_map);
> -	return 0;
> +	return ret;
>  }
>  
>  static inline void
> 

Reviewed-by: David Hildenbrand <david@...hat.com>

-- 

Thanks,

David / dhildenb

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ