在 2022/2/10 上午12:02, Karsten Graul 写道:
On 09/02/2022 15:11, D. Wythe wrote:
+static struct sock *smc_tcp_syn_recv_sock(const struct sock *sk, struct sk_buff *skb,
+ struct request_sock *req,
+ struct dst_entry *dst,
+ struct request_sock *req_unhash,
+ bool *own_req)
+{
+ struct smc_sock *smc;
+
+ smc = (struct smc_sock *)((uintptr_t)sk->sk_user_data & ~SK_USER_DATA_NOCOPY);
Did you run checkpatch.pl for these patches, for me this and other lines look longer
than 80 characters.
The latest checkpacth removes this restriction, so I didn't find this
problem, I'll fix it right away.
diff --git a/net/smc/smc.h b/net/smc/smc.h
index 37b2001..5e5e38d 100644
--- a/net/smc/smc.h
+++ b/net/smc/smc.h
@@ -252,6 +252,10 @@ struct smc_sock { /* smc sock container */
bool use_fallback; /* fallback to tcp */
int fallback_rsn; /* reason for fallback */
u32 peer_diagnosis; /* decline reason from peer */
+ atomic_t smc_pendings; /* pending smc connections */
I don't like the name smc_pendings, its not very specific.
What about queued_smc_hs?
And for the comment: queued smc handshakes
+ struct inet_connection_sock_af_ops af_ops;
+ const struct inet_connection_sock_af_ops *ori_af_ops;
+ /* origin af ops */
origin -> original
int sockopt_defer_accept;
/* sockopt TCP_DEFER_ACCEPT
* value
Copy that. I'll rename it all.