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: <CAH-L+nMoaCynX+3yzVVsrj-4T_nhVXRAgp=BB-nEzPRdr-9qoA@mail.gmail.com>
Date: Tue, 22 Aug 2023 13:26:58 +0530
From: Kalesh Anakkur Purayil <kalesh-anakkur.purayil@...adcom.com>
To: Ido Schimmel <idosch@...dia.com>
Cc: netdev@...r.kernel.org, davem@...emloft.net, kuba@...nel.org, 
	pabeni@...hat.com, edumazet@...gle.com, razor@...ckwall.org, mlxsw@...dia.com
Subject: Re: [PATCH net-next] vxlan: vnifilter: Use GFP_KERNEL instead of GFP_ATOMIC

On Mon, Aug 21, 2023 at 7:51 PM Ido Schimmel <idosch@...dia.com> wrote:

> The function is not called from an atomic context so use GFP_KERNEL
> instead of GFP_ATOMIC. The allocation of the per-CPU stats is already
> performed with GFP_KERNEL.
>
> Tested using test_vxlan_vnifiltering.sh with CONFIG_DEBUG_ATOMIC_SLEEP.
>
> Signed-off-by: Ido Schimmel <idosch@...dia.com>
>

Reviewed-by: Kalesh AP <kalesh-anakkur.purayil@...adcom.com>

> ---
>  drivers/net/vxlan/vxlan_vnifilter.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/vxlan/vxlan_vnifilter.c
> b/drivers/net/vxlan/vxlan_vnifilter.c
> index c3ff30ab782e..9c59d0bf8c3d 100644
> --- a/drivers/net/vxlan/vxlan_vnifilter.c
> +++ b/drivers/net/vxlan/vxlan_vnifilter.c
> @@ -696,7 +696,7 @@ static struct vxlan_vni_node *vxlan_vni_alloc(struct
> vxlan_dev *vxlan,
>  {
>         struct vxlan_vni_node *vninode;
>
> -       vninode = kzalloc(sizeof(*vninode), GFP_ATOMIC);
> +       vninode = kzalloc(sizeof(*vninode), GFP_KERNEL);
>         if (!vninode)
>                 return NULL;
>         vninode->stats = netdev_alloc_pcpu_stats(struct
> vxlan_vni_stats_pcpu);
> --
> 2.40.1
>
>
>

-- 
Regards,
Kalesh A P

Content of type "text/html" skipped

Download attachment "smime.p7s" of type "application/pkcs7-signature" (4239 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ