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 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 03850C433F5 for ; Mon, 28 Mar 2022 11:50:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:From:References:Cc:To: Subject:MIME-Version:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=happ003U7f+XKc/8duEXl/jiIhzeAvUQsMtiNGxueO4=; b=l+XZogkvzAIWWK RhNcIxaxH5EH4BH3GEwIkA4i5em0H2uededvrSj6P86vH61XMj7lgV7P+tzPWApFQ1LCnKBPZALH2 2KY/NqP+8SXNEdS7WsWwSX630RfdPG9u+4Oue5XLswUn6JBaqJmQ3Dn25yigVowDQOAxYSswymYBJ L7JoNmODSk23yr3i3CeI4ixpJFkxL10tMV9m7dJlzewXArhnz9jlRbC4fPNOfd7AIH/hLe8vB1nCr 2a82aOPpOd/DoOtZGtdvJr7Y8YhrtA5r+c+gf/SpnMWYNkBRi7Tf8s63skyBcd53FWXxj9CexYBfV GWJNNhyO1wsf1amZA3Cw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nYnsE-008QiI-Cb; Mon, 28 Mar 2022 11:49:26 +0000 Received: from mail-ed1-f46.google.com ([209.85.208.46]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nYnsA-008Qhy-Il for linux-arm-kernel@lists.infradead.org; Mon, 28 Mar 2022 11:49:23 +0000 Received: by mail-ed1-f46.google.com with SMTP id x34so16560880ede.8 for ; Mon, 28 Mar 2022 04:49:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:from:in-reply-to :content-transfer-encoding; bh=wbmtuFgYk21OVybrhPNThf688k7OlnshZ2rECopA1sQ=; b=8C2hjH7+HmZV8SRJ7srueR7bjmfZ0RDtTxz4p6+NpW2a9ssWmUGj6pPS1K5Eno9t7Y uoYvnWLDtPP5FWVxINchDqBV6lrChYzka/qImZeDIvol2j5n29L7KxYakL0GDZwiOTtG vRnyuz0ahlz27j2l8blneB+fJT46pWYFV/WHkpOvyC6FrX4EVkJ0GsKDvKkIO1l2sB9h 9lYYfs66WOp2f7kct5EmwjdGV5UqnH2IcFeMcrBuYG3jeqUwAOM2zhKGZ+ZiV960UHAl 5Rno19l8xxyF7DulvI9HsJu9Bqpxkg1ui+id9ouuElKubSfMezJ33pnGLcK4k/eae06e 5/mA== X-Gm-Message-State: AOAM533msJ2muop+ZQVCnJkrvJ+rn875kJM6x5fb6wqXXdi8dac6R7EO UkzeHYKim1kzNE3Cubv/cvo= X-Google-Smtp-Source: ABdhPJzWXsy4+GphF1QuoAkcYFlawyiEs4+1gNVRO87F9Ywpbhee44VZa+NoHAfXuvSNPc08MaGPTA== X-Received: by 2002:a05:6402:3488:b0:419:172c:e287 with SMTP id v8-20020a056402348800b00419172ce287mr15585663edc.87.1648468160467; Mon, 28 Mar 2022 04:49:20 -0700 (PDT) Received: from [192.168.0.162] (xdsl-188-155-201-27.adslplus.ch. [188.155.201.27]) by smtp.googlemail.com with ESMTPSA id f3-20020a056402004300b004162aa024c0sm6850041edu.76.2022.03.28.04.49.19 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 28 Mar 2022 04:49:19 -0700 (PDT) Message-ID: <5c24c12b-3a12-1e18-9f03-2c54cad30bf9@kernel.org> Date: Mon, 28 Mar 2022 13:49:18 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.5.0 Subject: Re: [PATCH 3/5] arm64: dts: imx8mp: Enable HS400-ES Content-Language: en-US To: Ahmad Fatoum , Adam Ford , Krzysztof Kozlowski Cc: linux-mmc , devicetree , Ulf Hansson , Fabio Estevam , Shawn Guo , Sascha Hauer , Adam Ford-BE , Haibo Chen , Linux Kernel Mailing List , Rob Herring , NXP Linux Team , Pengutronix Kernel Team , arm-soc References: <20220327123835.28329-1-aford173@gmail.com> <20220327123835.28329-3-aford173@gmail.com> <74e74ea8-1554-bf08-b0ea-36e77259cb18@pengutronix.de> From: Krzysztof Kozlowski In-Reply-To: <74e74ea8-1554-bf08-b0ea-36e77259cb18@pengutronix.de> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220328_044922_674047_921FBAB0 X-CRM114-Status: GOOD ( 28.68 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 28/03/2022 13:09, Ahmad Fatoum wrote: > Hello Adam, > > On 28.03.22 12:47, Adam Ford wrote: >> On Mon, Mar 28, 2022 at 2:20 AM Ahmad Fatoum wrote: >>> >>> Hello Adam, >>> >>> On 27.03.22 14:38, Adam Ford wrote: >>>> The SDHC controller in the imx8mp has the same controller >>>> as the imx8mm which supports HS400-ES. Change the compatible >>>> fallback to imx8mm to enable it. >>> >>> I believe that's a shortcoming of the Linux driver, which should explicitly list >>> fsl,imx8mp-usdhc in its compatibles and enable HS400-ES for it. >>> >>> I find dropping compatibles problematic, because like Linux matching >>> fsl,imx8mm-usdhc, but not fsl,imx8mp-usdhc, other software may match >>> fsl,imx7d-usdhc, but not fsl,imx8[mp]-usdhc. >>> >>> I'd prefer that either the kernel driver gains extra compatibles or that >>> the DTS lists extra compatibles and we refrain from dropping existing >>> (correct) ones. >>> >> >> I would argue that imx7d is not correct since the IP blocks between >> imx7d and imx8mm have different flags/quirks. One of which includes >> HS400-ES, but there are other differences as well. > > The DTS currently says that an fsl,imx7d-usdhc is a subset of an > fsl,imx8mm-usdhc. So a driver could treat both HW the exact same > by focusing on the i.MX7D parts. Linux apparently did exactly > that so far. Is this not accurate? > > >>> What do you think? >> >> From my understanding of the fallback compatibility strings is to >> avoid having to add more and more compatible strings to the drivers >> when they do not serve a functional purpose. Based On a conversation >> with Krzysztof [1], he suggested we update the YAML file based on the >> fallback, but he wanted NXP to give their feedback as to what the >> right fallback strings should be. Haibo from NXP sent me a hierarchy >> [1] which is what I used to update the YAML file. Based on the YAML >> file, the fallback in each DTSI file was updated to ensure the use of >> the proper IP block. > > Myself I am in favor of moving to three compatibles instead of dropping one. > For some theoretical fsl,imx8mf-usdhc that's supposed to be exactly the same > as a fsl,imx8mm-usdhc, I don't mind omitting the fsl,imx7d-usdhc compatible, > but for existing device trees, this may introduce needless potential breakage > for other software that also uses Linux device trees. > Affecting existing users is indeed a concern with this approach, because in-kernel DTS might be used in other projects as well. I still cannot find here the answer whether fsl,imx8mm-usdhc is actually compatible with fsl,imx7d-usdhc. It's not about driver, but about hardware and programming model. imx8mm can support additional features and still be compatible with imx7d. However if any flags of imx7d are actually not valid for imx8mm, then it's different case. Best regards, Krzysztof _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel 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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B7E1EC433F5 for ; Mon, 28 Mar 2022 11:53:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233758AbiC1Ly5 (ORCPT ); Mon, 28 Mar 2022 07:54:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40684 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241514AbiC1Lyq (ORCPT ); Mon, 28 Mar 2022 07:54:46 -0400 Received: from mail-ed1-f52.google.com (mail-ed1-f52.google.com [209.85.208.52]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 16712377D0; Mon, 28 Mar 2022 04:49:22 -0700 (PDT) Received: by mail-ed1-f52.google.com with SMTP id a17so16574175edm.9; Mon, 28 Mar 2022 04:49:22 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:from:in-reply-to :content-transfer-encoding; bh=wbmtuFgYk21OVybrhPNThf688k7OlnshZ2rECopA1sQ=; b=DUus5YkXMkLwPHuMSYWpSbAzEXKGC7Ax8I4gLTBEAU+OOe7y2W8iqUcJvefaKdlUrI cTo/YO6lFVWMCYHS8k3iPDCUO8bSrg1kjG5dIHkXlsRGeClBuJgjmN2agwAlK9XSljKm 2/2wRWSwgojkS5EjDMg6E4PPrQe4Z7chakGYt4qow8Ep4l+VJn7JyO+Ag0S2t+fjwCYL c44IJDiWb9QMSWWamjJFA7ZgY96yZNmd/NQ1SKXSchyOPI1EwOa9CebK+IfF2CN/g4/q SfrXLM41BhL8N1BkC10jatnFv3FTUOkRCOHldzmL50CbUg8QveVEI2Mnzl11ogKOVpeJ x6gA== X-Gm-Message-State: AOAM533/LymGBHtkiU11xyP+BtzLsdrzWp2jVPVZnAr8hNECH7hRtK5h /hoi9Zi9srLYcJmeQeKVLC4= X-Google-Smtp-Source: ABdhPJzWXsy4+GphF1QuoAkcYFlawyiEs4+1gNVRO87F9Ywpbhee44VZa+NoHAfXuvSNPc08MaGPTA== X-Received: by 2002:a05:6402:3488:b0:419:172c:e287 with SMTP id v8-20020a056402348800b00419172ce287mr15585663edc.87.1648468160467; Mon, 28 Mar 2022 04:49:20 -0700 (PDT) Received: from [192.168.0.162] (xdsl-188-155-201-27.adslplus.ch. [188.155.201.27]) by smtp.googlemail.com with ESMTPSA id f3-20020a056402004300b004162aa024c0sm6850041edu.76.2022.03.28.04.49.19 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 28 Mar 2022 04:49:19 -0700 (PDT) Message-ID: <5c24c12b-3a12-1e18-9f03-2c54cad30bf9@kernel.org> Date: Mon, 28 Mar 2022 13:49:18 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.5.0 Subject: Re: [PATCH 3/5] arm64: dts: imx8mp: Enable HS400-ES Content-Language: en-US To: Ahmad Fatoum , Adam Ford , Krzysztof Kozlowski Cc: linux-mmc , devicetree , Ulf Hansson , Fabio Estevam , Shawn Guo , Sascha Hauer , Adam Ford-BE , Haibo Chen , Linux Kernel Mailing List , Rob Herring , NXP Linux Team , Pengutronix Kernel Team , arm-soc References: <20220327123835.28329-1-aford173@gmail.com> <20220327123835.28329-3-aford173@gmail.com> <74e74ea8-1554-bf08-b0ea-36e77259cb18@pengutronix.de> From: Krzysztof Kozlowski In-Reply-To: <74e74ea8-1554-bf08-b0ea-36e77259cb18@pengutronix.de> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 28/03/2022 13:09, Ahmad Fatoum wrote: > Hello Adam, > > On 28.03.22 12:47, Adam Ford wrote: >> On Mon, Mar 28, 2022 at 2:20 AM Ahmad Fatoum wrote: >>> >>> Hello Adam, >>> >>> On 27.03.22 14:38, Adam Ford wrote: >>>> The SDHC controller in the imx8mp has the same controller >>>> as the imx8mm which supports HS400-ES. Change the compatible >>>> fallback to imx8mm to enable it. >>> >>> I believe that's a shortcoming of the Linux driver, which should explicitly list >>> fsl,imx8mp-usdhc in its compatibles and enable HS400-ES for it. >>> >>> I find dropping compatibles problematic, because like Linux matching >>> fsl,imx8mm-usdhc, but not fsl,imx8mp-usdhc, other software may match >>> fsl,imx7d-usdhc, but not fsl,imx8[mp]-usdhc. >>> >>> I'd prefer that either the kernel driver gains extra compatibles or that >>> the DTS lists extra compatibles and we refrain from dropping existing >>> (correct) ones. >>> >> >> I would argue that imx7d is not correct since the IP blocks between >> imx7d and imx8mm have different flags/quirks. One of which includes >> HS400-ES, but there are other differences as well. > > The DTS currently says that an fsl,imx7d-usdhc is a subset of an > fsl,imx8mm-usdhc. So a driver could treat both HW the exact same > by focusing on the i.MX7D parts. Linux apparently did exactly > that so far. Is this not accurate? > > >>> What do you think? >> >> From my understanding of the fallback compatibility strings is to >> avoid having to add more and more compatible strings to the drivers >> when they do not serve a functional purpose. Based On a conversation >> with Krzysztof [1], he suggested we update the YAML file based on the >> fallback, but he wanted NXP to give their feedback as to what the >> right fallback strings should be. Haibo from NXP sent me a hierarchy >> [1] which is what I used to update the YAML file. Based on the YAML >> file, the fallback in each DTSI file was updated to ensure the use of >> the proper IP block. > > Myself I am in favor of moving to three compatibles instead of dropping one. > For some theoretical fsl,imx8mf-usdhc that's supposed to be exactly the same > as a fsl,imx8mm-usdhc, I don't mind omitting the fsl,imx7d-usdhc compatible, > but for existing device trees, this may introduce needless potential breakage > for other software that also uses Linux device trees. > Affecting existing users is indeed a concern with this approach, because in-kernel DTS might be used in other projects as well. I still cannot find here the answer whether fsl,imx8mm-usdhc is actually compatible with fsl,imx7d-usdhc. It's not about driver, but about hardware and programming model. imx8mm can support additional features and still be compatible with imx7d. However if any flags of imx7d are actually not valid for imx8mm, then it's different case. Best regards, Krzysztof