Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751645AbdISRuA (ORCPT ); Tue, 19 Sep 2017 13:50:00 -0400 Received: from mail-wm0-f67.google.com ([74.125.82.67]:36572 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751353AbdISRt6 (ORCPT ); Tue, 19 Sep 2017 13:49:58 -0400 X-Google-Smtp-Source: AOwi7QDk5CtMyxx8xVyZBjr5RGhidHI+EQrtWlX4b1xe7msqY46molBy4kJGToaPxDggivrrYIxyQQ== Subject: Re: [PATCH net-next 3/4] net: dsa: setup master ethtool after dsa_ptr To: Vivien Didelot , netdev@vger.kernel.org Cc: linux-kernel@vger.kernel.org, kernel@savoirfairelinux.com, "David S. Miller" , Andrew Lunn References: <20170919155700.14474-1-vivien.didelot@savoirfairelinux.com> <20170919155700.14474-4-vivien.didelot@savoirfairelinux.com> From: Florian Fainelli Message-ID: <85ebc3f7-b8b1-a2e4-f0e4-32c309857730@gmail.com> Date: Tue, 19 Sep 2017 10:49:52 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <20170919155700.14474-4-vivien.didelot@savoirfairelinux.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 711 Lines: 18 On 09/19/2017 08:56 AM, Vivien Didelot wrote: > DSA overrides the master's ethtool ops so that we can inject its CPU > port's statistics. Because of that, we need to setup the ethtool ops > after the master's dsa_ptr pointer has been assigned, not before. Yes, good point, technically this is a bugfix, but since we have changed this quite often and the race is tiny, I am not positive we could a) trigger this in real life, and b) provide a proper Fixes tag. > > This patch setups the ethtool ops after dsa_ptr is assigned, and > restores them before it gets cleared. > > Signed-off-by: Vivien Didelot Reviewed-by: Florian Fainelli -- Florian