From: Ben Pfaff Date: Sat, 9 Jan 2010 00:45:14 +0000 (-0800) Subject: datapath: Improve comments on struct dp_stats_percpu. X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=67a78abeeae1a726d46ae475c5834513c7fe291e;p=openvswitch datapath: Improve comments on struct dp_stats_percpu. Suggested by Justin Pettit. --- diff --git a/datapath/datapath.h b/datapath/datapath.h index 929b9d88..c610312b 100644 --- a/datapath/datapath.h +++ b/datapath/datapath.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009 Nicira Networks. + * Copyright (c) 2009, 2010 Nicira Networks. * Distributed under the terms of the GNU GPL version 2. * * Significant portions of this file may be copied from parts of the Linux @@ -82,12 +82,27 @@ struct dp_bucket { #define DP_N_QUEUES 3 #define DP_MAX_QUEUE_LEN 100 +/** + * struct dp_stats_percpu - per-cpu packet processing statistics for a given + * datapath. + * @n_frags: Number of IP fragments processed by datapath. + * @n_hit: Number of received packets for which a matching flow was found in + * the flow table. + * @n_miss: Number of received packets that had no matching flow in the flow + * table. The sum of @n_hit and @n_miss is the number of packets that have + * been received by the datapath. + * @n_lost: Number of received packets that had no matching flow in the flow + * table that could not be sent to userspace (normally due to an overflow in + * one of the datapath's queues). + * @sflow_pool: Number of packets that were candidates for sFlow sampling, + * regardless of whether they were actually chosen and sent down to userspace. + */ struct dp_stats_percpu { u64 n_frags; u64 n_hit; u64 n_missed; u64 n_lost; - u64 sflow_pool; /* Packets that could have been sampled. */ + u64 sflow_pool; }; struct dp_port_group {