diff options
Diffstat (limited to 'net/core/sock.c')
-rw-r--r-- | net/core/sock.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/net/core/sock.c b/net/core/sock.c index 76ff58d43e26..e1f6f225f012 100644 --- a/net/core/sock.c +++ b/net/core/sock.c | |||
@@ -1205,6 +1205,10 @@ struct sock *sk_clone(const struct sock *sk, const gfp_t priority) | |||
1205 | 1205 | ||
1206 | if (newsk->sk_prot->sockets_allocated) | 1206 | if (newsk->sk_prot->sockets_allocated) |
1207 | percpu_counter_inc(newsk->sk_prot->sockets_allocated); | 1207 | percpu_counter_inc(newsk->sk_prot->sockets_allocated); |
1208 | |||
1209 | if (sock_flag(newsk, SOCK_TIMESTAMP) || | ||
1210 | sock_flag(newsk, SOCK_TIMESTAMPING_RX_SOFTWARE)) | ||
1211 | net_enable_timestamp(); | ||
1208 | } | 1212 | } |
1209 | out: | 1213 | out: |
1210 | return newsk; | 1214 | return newsk; |