From: Matteo Croce <mcroce@linux•microsoft.com>
To: netdev@vger•kernel.org
Cc: linux-kernel@vger•kernel.org,
Jonathan Lemon <jonathan.lemon@gmail•com>,
"David S. Miller" <davem@davemloft•net>,
Ilias Apalodimas <ilias.apalodimas@linaro•org>,
Jesper Dangaard Brouer <hawk@kernel•org>,
Lorenzo Bianconi <lorenzo@kernel•org>,
Saeed Mahameed <saeedm@nvidia•com>,
David Ahern <dsahern@gmail•com>,
Saeed Mahameed <saeed@kernel•org>, Andrew Lunn <andrew@lunn•ch>
Subject: [PATCH net-next 4/6] net: change users of __skb_frag_unref() and add an extra argument
Date: Mon, 22 Mar 2021 18:02:59 +0100 [thread overview]
Message-ID: <20210322170301.26017-5-mcroce@linux.microsoft.com> (raw)
In-Reply-To: <20210322170301.26017-1-mcroce@linux.microsoft.com>
From: Ilias Apalodimas <ilias.apalodimas@linaro•org>
On a previous patch we added an extra argument on __skb_frag_unref() to
handle recycling. Update the current users of the function with that.
Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro•org>
Signed-off-by: Matteo Croce <mcroce@microsoft•com>
---
drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c | 2 +-
drivers/net/ethernet/marvell/sky2.c | 2 +-
drivers/net/ethernet/mellanox/mlx4/en_rx.c | 2 +-
net/tls/tls_device.c | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c b/drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c
index 169e10c91378..cbcff5518965 100644
--- a/drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c
+++ b/drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c
@@ -2125,7 +2125,7 @@ static int chcr_ktls_xmit(struct sk_buff *skb, struct net_device *dev)
/* clear the frag ref count which increased locally before */
for (i = 0; i < record->num_frags; i++) {
/* clear the frag ref count */
- __skb_frag_unref(&record->frags[i]);
+ __skb_frag_unref(&record->frags[i], false);
}
/* if any failure, come out from the loop. */
if (ret) {
diff --git a/drivers/net/ethernet/marvell/sky2.c b/drivers/net/ethernet/marvell/sky2.c
index 2a752fb6b758..1cc646fb4fe4 100644
--- a/drivers/net/ethernet/marvell/sky2.c
+++ b/drivers/net/ethernet/marvell/sky2.c
@@ -2501,7 +2501,7 @@ static void skb_put_frags(struct sk_buff *skb, unsigned int hdr_space,
if (length == 0) {
/* don't need this page */
- __skb_frag_unref(frag);
+ __skb_frag_unref(frag, false);
--skb_shinfo(skb)->nr_frags;
} else {
size = min(length, (unsigned) PAGE_SIZE);
diff --git a/drivers/net/ethernet/mellanox/mlx4/en_rx.c b/drivers/net/ethernet/mellanox/mlx4/en_rx.c
index e35e4d7ef4d1..cea62b8f554c 100644
--- a/drivers/net/ethernet/mellanox/mlx4/en_rx.c
+++ b/drivers/net/ethernet/mellanox/mlx4/en_rx.c
@@ -526,7 +526,7 @@ static int mlx4_en_complete_rx_desc(struct mlx4_en_priv *priv,
fail:
while (nr > 0) {
nr--;
- __skb_frag_unref(skb_shinfo(skb)->frags + nr);
+ __skb_frag_unref(skb_shinfo(skb)->frags + nr, false);
}
return 0;
}
diff --git a/net/tls/tls_device.c b/net/tls/tls_device.c
index d9cd229aa111..2a32a547e51a 100644
--- a/net/tls/tls_device.c
+++ b/net/tls/tls_device.c
@@ -127,7 +127,7 @@ static void destroy_record(struct tls_record_info *record)
int i;
for (i = 0; i < record->num_frags; i++)
- __skb_frag_unref(&record->frags[i]);
+ __skb_frag_unref(&record->frags[i], false);
kfree(record);
}
--
2.30.2
next prev parent reply other threads:[~2021-03-22 17:05 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-22 17:02 [PATCH net-next 0/6] page_pool: recycle buffers Matteo Croce
2021-03-22 17:02 ` [PATCH net-next 1/6] xdp: reduce size of struct xdp_mem_info Matteo Croce
2021-03-22 17:02 ` [PATCH net-next 2/6] mm: add a signature in struct page Matteo Croce
2021-03-22 17:02 ` [PATCH net-next 3/6] page_pool: DMA handling and allow to recycles frames via SKB Matteo Croce
2021-03-22 19:38 ` Matteo Croce
2021-03-22 17:02 ` Matteo Croce [this message]
2021-03-22 17:03 ` [PATCH net-next 5/6] mvpp2: recycle buffers Matteo Croce
2021-03-22 17:03 ` [PATCH net-next 6/6] mvneta: " Matteo Croce
2021-03-23 15:06 ` Jesper Dangaard Brouer
2021-03-24 9:28 ` Lorenzo Bianconi
2021-03-24 21:48 ` Ilias Apalodimas
2021-03-23 14:57 ` [PATCH net-next 0/6] page_pool: " David Ahern
2021-03-23 15:03 ` Ilias Apalodimas
2021-03-23 15:41 ` Alexander Lobakin
2021-03-23 15:47 ` Ilias Apalodimas
2021-03-23 16:04 ` Jesper Dangaard Brouer
2021-03-23 16:10 ` Ilias Apalodimas
2021-03-23 16:28 ` Matteo Croce
2021-03-23 16:55 ` Alexander Lobakin
2021-03-23 17:01 ` Ilias Apalodimas
2021-03-23 20:03 ` Alexander Lobakin
2021-03-24 7:50 ` Ilias Apalodimas
2021-03-24 11:42 ` Alexander Lobakin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210322170301.26017-5-mcroce@linux.microsoft.com \
--to=mcroce@linux$(echo .)microsoft.com \
--cc=andrew@lunn$(echo .)ch \
--cc=davem@davemloft$(echo .)net \
--cc=dsahern@gmail$(echo .)com \
--cc=hawk@kernel$(echo .)org \
--cc=ilias.apalodimas@linaro$(echo .)org \
--cc=jonathan.lemon@gmail$(echo .)com \
--cc=linux-kernel@vger$(echo .)kernel.org \
--cc=lorenzo@kernel$(echo .)org \
--cc=netdev@vger$(echo .)kernel.org \
--cc=saeed@kernel$(echo .)org \
--cc=saeedm@nvidia$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox