From: Sasha Levin Date: Mon, 30 Oct 2023 23:14:27 +0000 (-0400) Subject: Fixes for 5.15 X-Git-Tag: v6.1.61~38 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=5f8abb907e6b0b52d27a8a6be1ed7e8640efd1f9;p=thirdparty%2Fkernel%2Fstable-queue.git Fixes for 5.15 Signed-off-by: Sasha Levin --- diff --git a/queue-5.15/gve-fix-gfp-flags-when-allocing-pages.patch b/queue-5.15/gve-fix-gfp-flags-when-allocing-pages.patch new file mode 100644 index 00000000000..fd50b539ed8 --- /dev/null +++ b/queue-5.15/gve-fix-gfp-flags-when-allocing-pages.patch @@ -0,0 +1,42 @@ +From e574800651a3b95575cba228eb4791d59df637ea Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 12 Sep 2022 17:09:01 -0700 +Subject: gve: Fix GFP flags when allocing pages + +From: Shailend Chand + +[ Upstream commit a92f7a6feeb3884c69c1c7c1f13bccecb2228ad0 ] + +Use GFP_ATOMIC when allocating pages out of the hotpath, +continue to use GFP_KERNEL when allocating pages during setup. + +GFP_KERNEL will allow blocking which allows it to succeed +more often in a low memory enviornment but in the hotpath we do +not want to allow the allocation to block. + +Fixes: f5cedc84a30d2 ("gve: Add transmit and receive support") +Signed-off-by: Catherine Sullivan +Signed-off-by: David Awogbemila +Link: https://lore.kernel.org/r/20220126003843.3584521-1-awogbemila@google.com +Signed-off-by: Jakub Kicinski +Signed-off-by: Sasha Levin +--- + drivers/net/ethernet/google/gve/gve_rx_dqo.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/drivers/net/ethernet/google/gve/gve_rx_dqo.c b/drivers/net/ethernet/google/gve/gve_rx_dqo.c +index 7b18b4fd9e548..d947c2c334128 100644 +--- a/drivers/net/ethernet/google/gve/gve_rx_dqo.c ++++ b/drivers/net/ethernet/google/gve/gve_rx_dqo.c +@@ -157,7 +157,7 @@ static int gve_alloc_page_dqo(struct gve_priv *priv, + int err; + + err = gve_alloc_page(priv, &priv->pdev->dev, &buf_state->page_info.page, +- &buf_state->addr, DMA_FROM_DEVICE, GFP_KERNEL); ++ &buf_state->addr, DMA_FROM_DEVICE, GFP_ATOMIC); + if (err) + return err; + +-- +2.42.0 + diff --git a/queue-5.15/series b/queue-5.15/series index b50ca601256..133895a4205 100644 --- a/queue-5.15/series +++ b/queue-5.15/series @@ -77,3 +77,4 @@ acpica-add-support-for-madt-online-enabled-bit.patch x86-acpi-don-t-add-cpus-that-are-not-online-capable.patch x86-acpi-boot-use-fadt-version-to-check-support-for-.patch x86-i8259-skip-probing-when-acpi-madt-advertises-pca.patch +gve-fix-gfp-flags-when-allocing-pages.patch