Re: [PATCH net] net: ena: clean up XDP TX queues when regular TX setup fails
From: Arthur Kiyanovski <akiyano@amazon.com>
Date: 2026-06-17 20:41:49
Also in:
bpf, lkml, stable
From: Arthur Kiyanovski <akiyano@amazon.com>
Date: 2026-06-17 20:41:49
Also in:
bpf, lkml, stable
On Tue, 16 Jun 2026 22:24:24 +0800, Dawei Feng [off-list ref] wrote:
diff --git a/drivers/net/ethernet/amazon/ena/ena_netdev.c b/drivers/net/ethernet/amazon/ena/ena_netdev.c index 92d149d4f091..5d05020a6d05 100644 --- a/drivers/net/ethernet/amazon/ena/ena_netdev.c +++ b/drivers/net/ethernet/amazon/ena/ena_netdev.c@@ -2078,14 +2090,21 @@ static int create_queues_with_size_backoff(struct ena_adapter *adapter)[ ... skip 17 lines ... ] + ena_destroy_xdp_tx_queues(adapter); goto err_create_tx_queues; + } rc = ena_setup_all_rx_resources(adapter); if (rc)
Thank you for submitting the fix. I verified it on AWS. The inline cleanup before goto is slightly non-idiomatic — kernel style typically prefers label-based unwinding. Splitting ena_destroy_all_tx_queues() into regular-only and XDP-only variants would allow a clean label chain without special-case code at each call site. But that's a larger refactor better suited for net-next; for a targeted bug fix this is fine. Reviewed-by: Arthur Kiyanovski <akiyano@amazon.com> Tested-by: Arthur Kiyanovski <akiyano@amazon.com> -- Arthur Kiyanovski [off-list ref]