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:   Wed, 20 Jun 2018 08:52:17 +0200
From:   Juergen Gross <jgross@...e.com>
To:     Jia-Ju Bai <baijiaju1990@...il.com>, boris.ostrovsky@...cle.com
Cc:     xen-devel@...ts.xenproject.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] xen: Fix two possible sleep-in-atomic-context bugs in
 create_active()

On 20/06/18 04:38, Jia-Ju Bai wrote:
> The driver may sleep with holding a spinlock.
> The function call paths (from bottom to top) in Linux-4.16.7 are:
> 
> [FUNC] __get_free_pages(GFP_KERNEL)
> drivers/xen/pvcalls-front.c, 351: __get_free_pages in create_active
> drivers/xen/pvcalls-front.c, 800: create_active in pvcalls_front_accept
> drivers/xen/pvcalls-front.c, 783: spin_lock in pvcalls_front_accept
> 
> [FUNC] __get_free_pages(GFP_KERNEL)
> drivers/xen/pvcalls-front.c, 347: __get_free_pages in create_active
> drivers/xen/pvcalls-front.c, 800: create_active in pvcalls_front_accept
> drivers/xen/pvcalls-front.c, 783: spin_lock in pvcalls_front_accept
> 
> To fix these bugs, GFP_KERNEL is replaced with GFP_ATOMIC.
> 
> These bugs are found by my static analysis tool (DSAC-2) and checked by my
> code review.
> 
> Signed-off-by: Jia-Ju Bai <baijiaju1990@...il.com>

Reviewed-by: Juergen Gross <jgross@...e.com>


Juergen

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ