diff mbox series

[2/3] net-zerocopy: remove static for tcp_zerocopy_receive()

Message ID 20220124094320.900713-3-haoxu@linux.alibaba.com (mailing list archive)
State Not Applicable
Delegated to: Netdev Maintainers
Headers show
Series io_uring zerocopy receive | expand

Checks

Context Check Description
netdev/fixes_present success Fixes tag not required for -next series
netdev/subject_prefix success Link
netdev/cover_letter success Series has a cover letter
netdev/patch_count success Link
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 1098 this patch: 1098
netdev/cc_maintainers success CCed 6 of 6 maintainers
netdev/build_clang success Errors and warnings before: 152 this patch: 152
netdev/module_param success Was 0 now: 0
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/verify_fixes success No Fixes tag
netdev/build_allmodconfig_warn success Errors and warnings before: 1108 this patch: 1108
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 21 lines checked
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0
netdev/tree_selection success Guessing tree name failed - patch did not apply, async

Commit Message

Hao Xu Jan. 24, 2022, 9:43 a.m. UTC
Remove static for tcp_zerocopy_receive() since we are going to
reference it in io_uring.

Signed-off-by: Hao Xu <haoxu@linux.alibaba.com>
---
 include/net/tcp.h | 3 +++
 net/ipv4/tcp.c    | 6 +++---
 2 files changed, 6 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/include/net/tcp.h b/include/net/tcp.h
index ba0e7957bdfb..f4108dea6a82 100644
--- a/include/net/tcp.h
+++ b/include/net/tcp.h
@@ -424,6 +424,9 @@  int zc_receive_check(struct tcp_zerocopy_receive *zc, int *lenp,
 int zc_receive_update(struct sock *sk, struct tcp_zerocopy_receive *zc, int len,
 		      char __user *optval, struct scm_timestamping_internal *tss,
 		      int err);
+int tcp_zerocopy_receive(struct sock *sk,
+			 struct tcp_zerocopy_receive *zc,
+			 struct scm_timestamping_internal *tss);
 #endif
 void tcp_parse_options(const struct net *net, const struct sk_buff *skb,
 		       struct tcp_options_received *opt_rx,
diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c
index d47e3ccf7cdb..b08a04f58b42 100644
--- a/net/ipv4/tcp.c
+++ b/net/ipv4/tcp.c
@@ -2066,9 +2066,9 @@  static void tcp_zc_finalize_rx_tstamp(struct sock *sk,
 }
 
 #define TCP_ZEROCOPY_PAGE_BATCH_SIZE 32
-static int tcp_zerocopy_receive(struct sock *sk,
-				struct tcp_zerocopy_receive *zc,
-				struct scm_timestamping_internal *tss)
+int tcp_zerocopy_receive(struct sock *sk,
+			 struct tcp_zerocopy_receive *zc,
+			 struct scm_timestamping_internal *tss)
 {
 	u32 length = 0, offset, vma_len, avail_len, copylen = 0;
 	unsigned long address = (unsigned long)zc->address;