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]
Message-ID: <20250905185606.42328008@kernel.org>
Date: Fri, 5 Sep 2025 18:56:06 -0700
From: Jakub Kicinski <kuba@...nel.org>
To: Shenwei Wang <shenwei.wang@....com>
Cc: Wei Fang <wei.fang@....com>, Andrew Lunn <andrew+netdev@...n.ch>, "David
 S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>, Paolo
 Abeni <pabeni@...hat.com>, Alexei Starovoitov <ast@...nel.org>, Daniel
 Borkmann <daniel@...earbox.net>, Jesper Dangaard Brouer <hawk@...nel.org>,
 John Fastabend <john.fastabend@...il.com>, Clark Wang
 <xiaoning.wang@....com>, Stanislav Fomichev <sdf@...ichev.me>,
 imx@...ts.linux.dev, netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
 linux-imx@....com
Subject: Re: [PATCH v5 net-next 4/5] net: fec: add change_mtu to support
 dynamic buffer allocation

On Thu,  4 Sep 2025 15:35:01 -0500 Shenwei Wang wrote:
> +		if (fec_enet_alloc_buffers(ndev) < 0) {
> +			fep->pagepool_order = old_order;
> +			fep->rx_frame_size = old_size;
> +			WRITE_ONCE(ndev->mtu, old_mtu);
> +			fec_enet_alloc_buffers(ndev);

And how do you know that it will succeed now?
You can't leave the device in-operational due to reconfig request when
system is under memory pressure. You need to save the previous buffers
so that you can restore them without having to allocate.

> +			ret = -ENOMEM;
> +		}

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ