From: Yidong Ren
This patch implements following ethtool stats fields for netvsc:
cpu_tx/rx_packets/bytes
cpu_vf_tx/rx_packets/bytes
Corresponding per-cpu counters already exist in current code. Exposing
these counters will help troubleshooting performance issues.
Signed-off-by: Yidong Ren
> From: Yidong Ren
> Sent: Monday, July 23, 2018 6:26 PM
> + pcpu_sum = kvmalloc(sizeof(struct netvsc_ethtool_pcpu_stats) *
> + num_present_cpus(), GFP_KERNEL);
Since there is no plan for CPU hotplug in Hyper-V in short term, it is fine
to use num_present_
> From: Vitaly Kuznetsov
> While you do for_each_present_cpu() in netvsc_get_ethtool_stats(),
> netvsc_get_pcpu_stats() does for_each_possible_cpu(). This looks
> inconsistent.
I made a mistake there. Thanks for catch me.
> The allocation you're doing here is short-lived so I would suggest you
From: Yidong Ren
This patch implements following ethtool stats fields for netvsc:
cpu_tx/rx_packets/bytes
cpu_vf_tx/rx_packets/bytes
Corresponding per-cpu counters already exist in current code. Exposing
these counters will help troubleshooting performance issues.
for_each_present_cpu() was
This patch implements following ethtool stats fields for netvsc:
cpu_rx_packets
cpu_tx_packets
cpu_rx_bytes
cpu_tx_bytes
cpu_vf_rx_packets
cpu_vf_tx_packets
cpu_vf_rx_bytes
cpu_vf_tx_bytes
---
drivers/net/hyperv/hyperv_net.h | 11 +
drivers/net/hyperv/netvsc_drv.c | 95
Thank you, Greg. I'm sorry for didn't read the guidelines on kernel newbies.
Please ignore this patch.
Thanks,
Yidong
-Original Message-
From: Greg KH
Sent: Wednesday, June 6, 2018 1:34 AM
To: Yidong Ren
Cc: driverdev-devel@linuxdriverproject.org; Haiyang Zhang
; Stephen
From: Yidong Ren
This patch implements following ethtool stats fields for netvsc:
cpu_tx/rx_packets/bytes
cpu_vf_tx/rx_packets/bytes
Corresponding per-cpu counters exist in current code. Exposing these
counters will help troubleshooting performance issues.
Signed-off-by: Yidong Ren
From: Yidong Ren
This patch implements following ethtool stats fields for netvsc:
cpu_tx/rx_packets/bytes
cpu_vf_tx/rx_packets/bytes
Corresponding per-cpu counters exist in current code. Exposing these
counters will help troubleshooting performance issues.
Signed-off-by: Yidong Ren
> From: Eric Dumazet
> You actually want to allocate memory local to this cpu, possibly in one chunk,
> not spread all over the places.
>
> kvmalloc(nr_cpu_ids * sizeof(struct netvsc_ethtool_pcpu_stats)) should be
> really better, since it would most of the time be satisfied by a single
> kmall
> From: devel On Behalf
> Of Stephen Hemminger
> > +/* statistics per queue (rx/tx packets/bytes) */ #define
> > +NETVSC_PCPU_STATS_LEN (num_present_cpus() *
> ARRAY_SIZE(pcpu_stats))
>
> Even though Hyper-V/Azure does not support hot plug cpu's it might be
> better to num_cpu_possible to avoid a
10 matches
Mail list logo