Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp235311rwb; Thu, 18 Aug 2022 02:58:09 -0700 (PDT) X-Google-Smtp-Source: AA6agR4PKkuJnsBotiiFiqKipMDHIo7ZhJAxMWjbDGWbEex8DWZVeRl8gUjnPRl1cPvBHNdjDGX+ X-Received: by 2002:a17:907:7619:b0:730:d709:a2f0 with SMTP id jx25-20020a170907761900b00730d709a2f0mr1418214ejc.673.1660816689624; Thu, 18 Aug 2022 02:58:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660816689; cv=none; d=google.com; s=arc-20160816; b=NORsgso5vNA32jRJwt6wMK1b+wqceZY9taU0QefUn1p/FsFDTHeubrNvm2Cjaj2+CV ZXvM3tetZTaYdPmLyY0ob9ZnLY3gUrShZ05iLVZuD+g92UwKODhtxLB6QgMQfQkOYPqM Y7kVIrVRreCPyrsqELEX3Kpbm2rjDQ3OLsaDusHU/MMrLdTAy8rkbM15D9KueZmSdAra vym5Yv1XRWEC9v37fbVayDIASMADA6KScxU/iJUotPN3nVrgu15OHodeNIuHkLHQAPn5 nRDYJH0gQYd9wnNJrdmQb/iVUjAYKxrouS2JAbY/Yg3xBf2796hUWEyRg7kmfLoFpOYh Ec8w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=MFmEDhXxgZF7KULdzona+7TtwCBEXCBX6WNuKW7to/k=; b=XJ9znvCxPdodp8IsFX9R7pylhOWJ+gbdWgp8hcUSuCHLhCGHifR8oN2lXsOAg/lbZe sKAXX7PfX9eRNHzpwYv1X0A23jJlf+1ZWteNZOb1oCQkw7/6Sd9lrCUPsdWvP60IAORq cOP/NJIwQEQ0EBRD4r//iHogLR+TwaI7lNT5Bvh7hnJgsziTuhVx76N8p4yDRHLyAShy C31/nngPXL0t2cUOEy9EVvoIRuOvGKevPEahoKlvfxyQ3btMLn6wW2i382LjI+EYZoxl wphJpuvEhA9+bxlY4ok9WsWZ9ys6QRO9Nq/RFNIyyprK1EZ+bEyenuNT8i3Xvp6zIO/B LawQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="o/H8DL4G"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z21-20020aa7cf95000000b0043ba23f56a6si842945edx.200.2022.08.18.02.57.42; Thu, 18 Aug 2022 02:58:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="o/H8DL4G"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243617AbiHRJql (ORCPT + 99 others); Thu, 18 Aug 2022 05:46:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49794 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243538AbiHRJqj (ORCPT ); Thu, 18 Aug 2022 05:46:39 -0400 Received: from mail-lf1-x132.google.com (mail-lf1-x132.google.com [IPv6:2a00:1450:4864:20::132]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9879BB0B25 for ; Thu, 18 Aug 2022 02:46:37 -0700 (PDT) Received: by mail-lf1-x132.google.com with SMTP id z6so1421186lfu.9 for ; Thu, 18 Aug 2022 02:46:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc; bh=MFmEDhXxgZF7KULdzona+7TtwCBEXCBX6WNuKW7to/k=; b=o/H8DL4GCtp0fpBXwBnHt5oN/hZyiyzj799GcdO01ig5EyiRWN0swEVeq6HE/3v0nH xzXSB9nR2VfYvc6KaZYdR6389lhlOoS/gh6+l68vRvVpDQJWKQM/tk7vFHaxIRG7dsTU lEp85ri6wwQeqsB0pZFS2IHrFOyQxHC2C5iNQ82EsU+V2luHYnOBve933fbYDmfZew3r 96seiWYyn285tf6agIdAA4MUXu5DoL4JXguuYJ89sf7JNCYSfzM4GkW90nJZIplLoU9Q u+UmSgJnmbxyYBCgdKWHlJwcWvMsMNzqRMnVwFJAawBrjGV9vS0BJ0VLJLjfjeV4XtiV E7pQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc; bh=MFmEDhXxgZF7KULdzona+7TtwCBEXCBX6WNuKW7to/k=; b=O+Ru/CzjInMVvCMnejXdIRNu+w6B10BSHQnyE+T9L8MHeX7cqEtPr4s+CHxs+VF8wr YleF0jdDLTK1uBrMhmitP+andiFtoW1mPm/nsEHU7KEI2WLNV+n0K6z/F9x670C5Dkni CzePSZ75HGbiwoVFyTYCYS2MnVF2A92e8F1b0D0pAlFOFsXgpUBdRICfIxJiGQaKyhTL q2jGWKDG8F2XJNKuYf1zovzW6yAVlmEReSIr1UEJnaIebrBM17L9NFCCbu8wQhgEACl3 SjHs5wuW8ilz7NlIgVRU+4IQFuyp/NmqjOJwoakZ2QUSUaWJygr5aVfh9/VMfYQw4CMO YsDA== X-Gm-Message-State: ACgBeo0GVoiEuACb4bKE3yVEgKy7IrLql87MbghzdugSrVYa+IcpXDll O+g8HNKBSDru4QYWu7YJrBU09w== X-Received: by 2002:a05:6512:39ce:b0:48c:f4d8:d418 with SMTP id k14-20020a05651239ce00b0048cf4d8d418mr724314lfu.635.1660815995938; Thu, 18 Aug 2022 02:46:35 -0700 (PDT) Received: from ?IPV6:2001:14bb:ae:539c:53ab:2635:d4f2:d6d5? (d15l54z9nf469l8226z-4.rev.dnainternet.fi. [2001:14bb:ae:539c:53ab:2635:d4f2:d6d5]) by smtp.gmail.com with ESMTPSA id p4-20020a056512234400b00492adcfefc1sm155757lfu.198.2022.08.18.02.46.34 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 18 Aug 2022 02:46:35 -0700 (PDT) Message-ID: Date: Thu, 18 Aug 2022 12:46:33 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.12.0 Subject: Re: [PATCH 1/3] dt-bings: net: fsl,fec: update compatible item Content-Language: en-US To: Shawn Guo Cc: Wei Fang , davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, s.hauer@pengutronix.de, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, peng.fan@nxp.com, ping.bai@nxp.com, sudeep.holla@arm.com, linux-arm-kernel@lists.infradead.org, aisheng.dong@nxp.com References: <20220704101056.24821-1-wei.fang@nxp.com> <20220704101056.24821-2-wei.fang@nxp.com> <20220818013344.GE149610@dragon> <20220818092257.GF149610@dragon> From: Krzysztof Kozlowski In-Reply-To: <20220818092257.GF149610@dragon> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 18/08/2022 12:22, Shawn Guo wrote: > On Thu, Aug 18, 2022 at 10:51:02AM +0300, Krzysztof Kozlowski wrote: >> On 18/08/2022 04:33, Shawn Guo wrote: >>> On Mon, Jul 04, 2022 at 11:12:09AM +0200, Krzysztof Kozlowski wrote: >>>>> diff --git a/Documentation/devicetree/bindings/net/fsl,fec.yaml b/Documentation/devicetree/bindings/net/fsl,fec.yaml >>>>> index daa2f79a294f..6642c246951b 100644 >>>>> --- a/Documentation/devicetree/bindings/net/fsl,fec.yaml >>>>> +++ b/Documentation/devicetree/bindings/net/fsl,fec.yaml >>>>> @@ -40,6 +40,10 @@ properties: >>>>> - enum: >>>>> - fsl,imx7d-fec >>>>> - const: fsl,imx6sx-fec >>>>> + - items: >>>>> + - enum: >>>>> + - fsl,imx8ulp-fec >>>>> + - const: fsl,imx6ul-fec >>>> >>>> This is wrong. fsl,imx6ul-fec has to be followed by fsl,imx6q-fec. I >>>> think someone made similar mistakes earlier so this is a mess. >>> >>> Hmm, not sure I follow this. Supposing we want to have the following >>> compatible for i.MX8ULP FEC, why do we have to have "fsl,imx6q-fec" >>> here? >>> >>> fec: ethernet@29950000 { >>> compatible = "fsl,imx8ulp-fec", "fsl,imx6ul-fec"; >>> ... >>> }; >> >> Because a bit earlier this bindings is saying that fsl,imx6ul-fec must >> be followed by fsl,imx6q-fec. > > The FEC driver OF match table suggests that fsl,imx6ul-fec and fsl,imx6q-fec > are not really compatible. > > static const struct of_device_id fec_dt_ids[] = { > { .compatible = "fsl,imx25-fec", .data = &fec_devtype[IMX25_FEC], }, > { .compatible = "fsl,imx27-fec", .data = &fec_devtype[IMX27_FEC], }, > { .compatible = "fsl,imx28-fec", .data = &fec_devtype[IMX28_FEC], }, > { .compatible = "fsl,imx6q-fec", .data = &fec_devtype[IMX6Q_FEC], }, > { .compatible = "fsl,mvf600-fec", .data = &fec_devtype[MVF600_FEC], }, > { .compatible = "fsl,imx6sx-fec", .data = &fec_devtype[IMX6SX_FEC], }, > { .compatible = "fsl,imx6ul-fec", .data = &fec_devtype[IMX6UL_FEC], }, I don't see here any incompatibility. Binding driver with different driver data is not a proof of incompatible devices. Additionally, the binding describes the hardware, not the driver. > { .compatible = "fsl,imx8mq-fec", .data = &fec_devtype[IMX8MQ_FEC], }, > { .compatible = "fsl,imx8qm-fec", .data = &fec_devtype[IMX8QM_FEC], }, > { /* sentinel */ } > }; > MODULE_DEVICE_TABLE(of, fec_dt_ids); > > Should we fix the binding doc? Maybe, I don't know. The binding describes the hardware, so based on it the devices are compatible. Changing this, except ABI impact, would be possible with proper reason, but not based on Linux driver code. Best regards, Krzysztof