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:   Thu, 29 Nov 2018 18:01:46 +0100
From:   Juergen Gross <jgross@...e.com>
To:     Wen Yang <wen.yang99@....com.cn>, boris.ostrovsky@...cle.com,
        sstabellini@...nel.org
Cc:     xen-devel@...ts.xenproject.org, linux-kernel@...r.kernel.org,
        zhong.weidong@....com.cn, Julia Lawall <julia.lawall@...6.fr>
Subject: Re: [PATCH] pvcalls-front: Use GFP_ATOMIC under spin_lock

On 29/11/2018 13:01, Wen Yang wrote:
> The problem is that we call this with a spin lock held.
> The call tree is:
> pvcalls_front_accept() holds bedata->socket_lock.
>     -> create_active()
>         -> __get_free_pages() uses GFP_KERNEL
> 
> The create_active() function is only called from pvcalls_front_accept()
> with a spin_lock held, The allocation is not allowed to sleep and
> GFP_KERNEL is not sufficient, it has to be ATOMIC.

I'd rather have a function doing the allocations which is called
outside the lock and either passing the allocated data to
create_active() or hook it into map in the allocation function.


Juergen

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ