From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.4 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 16854C43461 for ; Mon, 7 Sep 2020 06:15:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 735B621582 for ; Mon, 7 Sep 2020 06:15:45 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=intenta.de header.i=@intenta.de header.b="ofaFQ0IG" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726384AbgIGGPo (ORCPT ); Mon, 7 Sep 2020 02:15:44 -0400 Received: from mail.intenta.de ([178.249.25.132]:28544 "EHLO mail.intenta.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725823AbgIGGPn (ORCPT ); Mon, 7 Sep 2020 02:15:43 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=intenta.de; s=dkim1; h=In-Reply-To:Content-Type:MIME-Version:References:Message-ID:Subject:CC:To:From:Date; bh=DbMZrPNiSZyV/MGrBTAsouTip2qG5zxNYYBptBohLcI=; b=ofaFQ0IGc3oT7MFp6707aqNPqhcxPZQo8FzwLBLxGFVPGTV/pCqJL5BXedj4Dv1QpWkux9EwcviR9PpO0dj6DQhvarZOBA33Xs0WcNJSBMDa/JTS7QvKKC+Z24PY+xYCOzxlEIqFe/Xh8kKlqExSqtgGCRjqh5SZ1HU7zErwAgCMms6hdH/MEBtzpGsvmiLfwmQR0x0XfrHGlgDdXk3YiIAl75lovCrrMGwut+8cU9crDR/PHIxJ3N/rFAzlbYHrQQsH2OoqFPAB6i5hl0h/Fk4OxTFThCQxf9mpU8IXjN6XhZ0Gw6PRogxYKmsKNdTGVEAWixXtwS5wxu2jy7u6/A==; Date: Mon, 7 Sep 2020 08:15:33 +0200 From: Helmut Grohne To: Andrew Lunn CC: Nicolas Ferre , Alexandre Belloni , Ludovic Desroches , Woojung Huh , Microchip Linux Driver Support , Vivien Didelot , Florian Fainelli , "David S. Miller" , Jakub Kicinski , "Rob Herring" , , Subject: Re: [PATCH v2] net: dsa: microchip: look for phy-mode in port nodes Message-ID: <20200907061533.GA2727@laureti-dev> References: <20200824.153738.1423061044322742575.davem@davemloft.net> <20200904081438.GA14387@laureti-dev> <20200904135255.GM3112546@lunn.ch> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <20200904135255.GM3112546@lunn.ch> User-Agent: Mutt/1.10.1 (2018-07-13) X-ClientProxiedBy: ICSMA002.intenta.de (10.10.16.48) To ICSMA002.intenta.de (10.10.16.48) Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Hi Andrew, On Fri, Sep 04, 2020 at 03:52:55PM +0200, Andrew Lunn wrote: > > + dev_warn(dev->dev, > > + "Using legacy switch \"phy-mode\" missing on port %d node. Please update your device tree.\n", This is inside ksz8795_port_setup. > That message seems mangled. I'm not sure that I understand what you are objecting to here. > > + if (!p->interface) { > > + if (dev->compat_interface) { > > + dev_warn(dev->dev, > > + "Using legacy switch \"phy-mode\" missing on port %d node. Please update your device tree.\n", > > + i); This is inside ksz9477_config_cpu_port. > Same warning again. I guess that you believe the warning should only be issued in one place. The locations affect different chips driven by the same driver. I considered moving them to a common function, but figured that it was not worth tearing the code apart. In case a third chip would be supported by the driver, it would not need the compatibility code. It would start out using only the correct phy-mode property. Does that address your concern? Helmut