Re: [PATCH v2 net-next] r8169: Add values missing in @get_stats64 from HW counters

2015-08-25 Thread Francois Romieu
Corinna Vinschen : [...] > Ok. I hope v4 of the patch is ok? The whole map...unmap sequence - memcpy included - could be in a single function and the comments in the code are imho a bit verbose but it's good enough as is. -- Ueimor -- To unsubscribe from this list: send the line "unsubscribe n

Re: [PATCH v2 net-next] r8169: Add values missing in @get_stats64 from HW counters

2015-08-25 Thread Corinna Vinschen
On Aug 25 01:33, Francois Romieu wrote: > Corinna Vinschen : > > On Aug 22 13:23, Francois Romieu wrote: > [...] > > > Sorry, my english was really bad: > > > > > > the code should propagate failure when rtl8169_reset_counters and > > > rtl8169_update_counters *simultaneously* fail. > > > > Uhm.

Re: [PATCH v2 net-next] r8169: Add values missing in @get_stats64 from HW counters

2015-08-24 Thread Francois Romieu
Corinna Vinschen : > On Aug 22 13:23, Francois Romieu wrote: [...] > > Sorry, my english was really bad: > > > > the code should propagate failure when rtl8169_reset_counters and > > rtl8169_update_counters *simultaneously* fail. > > Uhm... sorry, but that still doesn't answer the question. As

Re: [PATCH v2 net-next] r8169: Add values missing in @get_stats64 from HW counters

2015-08-24 Thread Corinna Vinschen
On Aug 24 09:33, Corinna Vinschen wrote: > On Aug 22 13:23, Francois Romieu wrote: > > Corinna Vinschen : > > [...] > > > That won't happen with the current patch because only > > > rtl8169_reset_counters would print a log message, it's only called from > > > open, and open occurs rather seldom.

Re: [PATCH v2 net-next] r8169: Add values missing in @get_stats64 from HW counters

2015-08-24 Thread Corinna Vinschen
On Aug 22 13:23, Francois Romieu wrote: > Corinna Vinschen : > [...] > > That won't happen with the current patch because only > > rtl8169_reset_counters would print a log message, it's only called from > > open, and open occurs rather seldom. Atop of that the code only tries > > to reset counter

Re: [PATCH v2 net-next] r8169: Add values missing in @get_stats64 from HW counters

2015-08-22 Thread Francois Romieu
Corinna Vinschen : [...] > That won't happen with the current patch because only > rtl8169_reset_counters would print a log message, it's only called from > open, and open occurs rather seldom. Atop of that the code only tries > to reset counters on HW supporting it, and only if resetting on the

Re: [PATCH v2 net-next] r8169: Add values missing in @get_stats64 from HW counters

2015-08-22 Thread Corinna Vinschen
On Aug 22 01:59, Francois Romieu wrote: > Corinna Vinschen : > > On Aug 21 21:39, Francois Romieu wrote: > [...] > > > The code should propagate failure when both rtl8169_reset_counters and > > > rtl8169_update_counters fail. > > > > This one I don't understand. Neither failing to reset the coun

Re: [PATCH v2 net-next] r8169: Add values missing in @get_stats64 from HW counters

2015-08-21 Thread Francois Romieu
Corinna Vinschen : > On Aug 21 21:39, Francois Romieu wrote: [...] > > The code should propagate failure when both rtl8169_reset_counters and > > rtl8169_update_counters fail. > > This one I don't understand. Neither failing to reset the counters nor > failing to update the counters is fatal for

Re: [PATCH v2 net-next] r8169: Add values missing in @get_stats64 from HW counters

2015-08-21 Thread Corinna Vinschen
On Aug 21 21:39, Francois Romieu wrote: > Corinna Vinschen : > [...] > > diff --git a/drivers/net/ethernet/realtek/r8169.c > > b/drivers/net/ethernet/realtek/r8169.c > > index f790f61..f26a48d 100644 > > --- a/drivers/net/ethernet/realtek/r8169.c > > +++ b/drivers/net/ethernet/realtek/r8169.c > [

Re: [PATCH v2 net-next] r8169: Add values missing in @get_stats64 from HW counters

2015-08-21 Thread Francois Romieu
Corinna Vinschen : [...] > diff --git a/drivers/net/ethernet/realtek/r8169.c > b/drivers/net/ethernet/realtek/r8169.c > index f790f61..f26a48d 100644 > --- a/drivers/net/ethernet/realtek/r8169.c > +++ b/drivers/net/ethernet/realtek/r8169.c [...] > @@ -2179,6 +2191,47 @@ static int rtl8169_get_sse

Re: [PATCH v2 net-next] r8169: Add values missing in @get_stats64 from HW counters

2015-08-21 Thread Corinna Vinschen
Sorry, I forgot to mention that I tested this patch on three different chip versions, RTL_GIGA_MAC_VER_23, RTL_GIGA_MAC_VER_33 and RTL_GIGA_MAC_VER_35. I couldn't test on pre-RTL_GIGA_MAC_VER_19, but the offset handling without counter reset already worked as expected on later chip versions, so I'