mirror of
https://github.com/nxp-imx/linux-imx.git
synced 2025-07-12 20:35:23 +02:00
ANDROID: GKI: net: add vendor hook for network quality estimation
Add vendor hook to support network quality estimation. 1.android_vh_tcp_connect To save the device name when TCP connect request is sent. Bug: 345643775 Change-Id: I9e2472565ee1b5653e2bc6c541e0d61e0c89d3ab Signed-off-by: Dezhi Huang <huangdezhi@hihonor.com>
This commit is contained in:
parent
df9e426fab
commit
9842b4145b
|
@ -340,6 +340,7 @@ EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_logbuf_pr_cont);
|
||||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_alloc_pages_slowpath);
|
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_alloc_pages_slowpath);
|
||||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_mmap_region);
|
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_mmap_region);
|
||||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_tcp_write_timeout_estab_retrans);
|
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_tcp_write_timeout_estab_retrans);
|
||||||
|
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_tcp_connect);
|
||||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_try_to_unmap_one);
|
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_try_to_unmap_one);
|
||||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_record_rwsem_reader_owned);
|
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_record_rwsem_reader_owned);
|
||||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_clear_rwsem_reader_owned);
|
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_clear_rwsem_reader_owned);
|
||||||
|
|
|
@ -62,6 +62,8 @@ DECLARE_HOOK(android_vh_build_skb_around,
|
||||||
TP_PROTO(struct sk_buff *skb), TP_ARGS(skb));
|
TP_PROTO(struct sk_buff *skb), TP_ARGS(skb));
|
||||||
DECLARE_HOOK(android_vh_tcp_write_timeout_estab_retrans,
|
DECLARE_HOOK(android_vh_tcp_write_timeout_estab_retrans,
|
||||||
TP_PROTO(struct sock *sk), TP_ARGS(sk));
|
TP_PROTO(struct sock *sk), TP_ARGS(sk));
|
||||||
|
DECLARE_HOOK(android_vh_tcp_connect,
|
||||||
|
TP_PROTO(struct sk_buff *skb), TP_ARGS(skb));
|
||||||
/* macro versions of hooks are no longer required */
|
/* macro versions of hooks are no longer required */
|
||||||
|
|
||||||
#endif /* _TRACE_HOOK_NET_VH_H */
|
#endif /* _TRACE_HOOK_NET_VH_H */
|
||||||
|
|
|
@ -3993,6 +3993,9 @@ int tcp_connect(struct sock *sk)
|
||||||
*/
|
*/
|
||||||
WRITE_ONCE(tp->snd_nxt, tp->write_seq);
|
WRITE_ONCE(tp->snd_nxt, tp->write_seq);
|
||||||
tp->pushed_seq = tp->write_seq;
|
tp->pushed_seq = tp->write_seq;
|
||||||
|
|
||||||
|
trace_android_vh_tcp_connect(buff);
|
||||||
|
|
||||||
buff = tcp_send_head(sk);
|
buff = tcp_send_head(sk);
|
||||||
if (unlikely(buff)) {
|
if (unlikely(buff)) {
|
||||||
WRITE_ONCE(tp->snd_nxt, TCP_SKB_CB(buff)->seq);
|
WRITE_ONCE(tp->snd_nxt, TCP_SKB_CB(buff)->seq);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user