diff options
author | Kozlov Dmitry <xeb@mail.ru> | 2012-09-05 23:24:51 +0400 |
---|---|---|
committer | Kozlov Dmitry <xeb@mail.ru> | 2012-09-05 23:24:51 +0400 |
commit | 490f6384f6a54e388587329c0309a6602d5544e8 (patch) | |
tree | 5e70a9e4e7a8f6714a4694826ec68f293d1e55a8 /accel-pppd/include | |
parent | a10ec0f4636cd559209659304709924daad96340 (diff) | |
download | accel-ppp-490f6384f6a54e388587329c0309a6602d5544e8.tar.gz accel-ppp-490f6384f6a54e388587329c0309a6602d5544e8.zip |
generalize interface statistics gathering
Diffstat (limited to 'accel-pppd/include')
-rw-r--r-- | accel-pppd/include/ap_session.h | 13 | ||||
l--------- | accel-pppd/include/iplink.h | 1 | ||||
l--------- | accel-pppd/include/iputils.h | 1 |
3 files changed, 14 insertions, 1 deletions
diff --git a/accel-pppd/include/ap_session.h b/accel-pppd/include/ap_session.h index 95f0ea21..82654f8b 100644 --- a/accel-pppd/include/ap_session.h +++ b/accel-pppd/include/ap_session.h @@ -35,6 +35,7 @@ struct ap_session; struct backup_data; +struct rtnl_link_stats; struct ap_ctrl { @@ -70,6 +71,7 @@ struct ap_session char sessionid[AP_SESSIONID_LEN+1]; time_t start_time; time_t stop_time; + time_t idle_time; char *username; struct ipv4db_item_t *ipv4; struct ipv6db_item_t *ipv6; @@ -87,6 +89,15 @@ struct ap_session int terminate_cause; struct list_head pd_list; + + uint32_t acct_rx_bytes; + uint32_t acct_tx_bytes; + uint32_t acct_input_gigawords; + uint32_t acct_output_gigawords; + uint32_t acct_rx_packets_i; + uint32_t acct_tx_packets_i; + uint32_t acct_rx_bytes_i; + uint32_t acct_tx_bytes_i; }; struct ap_session_stat @@ -114,6 +125,8 @@ void ap_session_activate(struct ap_session *ses); void ap_session_ifup(struct ap_session *ses); void ap_session_ifdown(struct ap_session *ses); +int ap_session_read_stats(struct ap_session *ses, struct rtnl_link_stats *stats); + void ap_shutdown_soft(void (*cb)(void)); #endif diff --git a/accel-pppd/include/iplink.h b/accel-pppd/include/iplink.h deleted file mode 120000 index 7f0f09d4..00000000 --- a/accel-pppd/include/iplink.h +++ /dev/null @@ -1 +0,0 @@ -../libnetlink/iplink.h
\ No newline at end of file diff --git a/accel-pppd/include/iputils.h b/accel-pppd/include/iputils.h new file mode 120000 index 00000000..c91d11c9 --- /dev/null +++ b/accel-pppd/include/iputils.h @@ -0,0 +1 @@ +../libnetlink/iputils.h
\ No newline at end of file |