Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1365636

Re: ARC dw-mshc binding compat string

From Rob Herring <robh+dt@kernel.org>
Newsgroups linux.kernel
Subject Re: ARC dw-mshc binding compat string
Date 2016-03-28 21:10 +0200
Message-ID <rhKI2-2UH-3@gated-at.bofh.it> (permalink)
References (8 earlier) <rh30l-5ZQ-11@gated-at.bofh.it> <rhBOp-50t-11@gated-at.bofh.it> <rhCKu-5KP-3@gated-at.bofh.it> <rhEVY-7c7-15@gated-at.bofh.it> <rhI3w-13T-11@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Mon, Mar 28, 2016 at 11:16 AM, Vladimir Zapolskiy
<vladimir_zapolskiy@mentor.com> wrote:
> Hi,
>
> On 28.03.2016 15:50, Marek Vasut wrote:
>> On 03/28/2016 12:34 PM, Jaehoon Chung wrote:
>>> Hi,
>>
>> Hi,
>>
>> [...]
>>
>>>>>>>>>> That said, I would rather prefer to see "snps,dw-mshc" prefix on description
>>>>>>>>>> of an MMC controller found on SoCFPGA series, "altr,socfpga-dw-mshc" seems
>>>>>>>>>> to be redundant.
>>>
>>> Yes..it's redundant..i should be combined to "snps,dw-mshc".
>>
>> Should the compat string be
>>   compatible = "altr,socfpga-dw-mshc", "snps,dw-mshc";
>> or just
>>   compatible = "snps,dw-mshc";
>> ?
>>
>> I am under the impression that a soc-specific identifier in addition to
>> a generic one (used by the driver compat table) is a good idea, because
>> it can help discerning the IP block from a generic one if needed at some
>> future point in time. It will also not break the DT for systems
>> which may depend on the non-generic compat, like *BSDs and such.
>>
>> What do you think ? (btw this is very much my question in this thread)
>
> IMO just 'compatible = "snps,dw-mshc"' is good enough, if it completely
> describes the IP block on SoCFGPA --- and from what I get it is the case.
> You can add a SoC-specific compatible if it is needed later on, and to my
> taste only if SoC specific features can not be covered by properties.

You can add the SoC-specific compatible string to the kernel later on.
You may not be able to update your DTB later on. So the specific
compatible strings need to be in the DT from the start.

There's no set rule on properties vs. implied by a compatible string,
but generally if it is fixed in the SoC, get the information based on
the compatible string. If it is a board level decision or has to be
tuned, then use a property.

> The same sole "snps,dw-mshc" compatible is specified for NXP LPC18xx/43xx,
> ZTE ZX and HiSilicon ARM SoCs.

They should be fixed.

> Another similar example is ARM PrimeCell PLxxx IP blocks, as far as
> I know there is no SoC-specific compatibles/aliases for PrimeCell IP blocks.

There are some for ST variants I think. PrimeCell blocks are a bit
different in that they generally pretty simple blocks, have not
changed much, and they
have a standard ID register that has been sufficient for determining
differences. And we have a standard way to override the ID register
when it is wrong. Look at recent patches for Denali NAND controller if
you want an example of why IP version registers (or compatible
strings) can't be trusted.

Once you get into IP blocks with lots of configuration options,
complicated clocking, power domains, and with phys on the front end,
then you hit all the integration differences.

Rob

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

ARC dw-mshc binding compat string Marek Vasut <marex@denx.de> - 2016-03-26 16:50 +0100
  Re: ARC dw-mshc binding compat string Vladimir Zapolskiy <vladimir_zapolskiy@mentor.com> - 2016-03-26 18:30 +0100
    Re: ARC dw-mshc binding compat string Marek Vasut <marex@denx.de> - 2016-03-26 18:40 +0100
      Re: ARC dw-mshc binding compat string Alexey Brodkin <Alexey.Brodkin@synopsys.com> - 2016-03-26 18:50 +0100
      Re: ARC dw-mshc binding compat string Vladimir Zapolskiy <vladimir_zapolskiy@mentor.com> - 2016-03-26 19:00 +0100
        Re: ARC dw-mshc binding compat string Vladimir Zapolskiy <vladimir_zapolskiy@mentor.com> - 2016-03-26 19:20 +0100
          Re: ARC dw-mshc binding compat string Marek Vasut <marex@denx.de> - 2016-03-26 21:00 +0100
            Re: ARC dw-mshc binding compat string Vladimir Zapolskiy <vladimir_zapolskiy@mentor.com> - 2016-03-26 21:20 +0100
              Re: ARC dw-mshc binding compat string Marek Vasut <marex@denx.de> - 2016-03-26 21:30 +0100
                Re: ARC dw-mshc binding compat string Alexey Brodkin <Alexey.Brodkin@synopsys.com> - 2016-03-28 11:40 +0200
                Re: ARC dw-mshc binding compat string Jaehoon Chung <jh80.chung@samsung.com> - 2016-03-28 12:40 +0200
                Re: ARC dw-mshc binding compat string Alexey Brodkin <Alexey.Brodkin@synopsys.com> - 2016-03-28 13:00 +0200
                Re: ARC dw-mshc binding compat string Jaehoon Chung <jh80.chung@samsung.com> - 2016-03-28 13:50 +0200
                Re: ARC dw-mshc binding compat string Rob Herring <robh+dt@kernel.org> - 2016-03-28 14:50 +0200
                Re: ARC dw-mshc binding compat string Marek Vasut <marex@denx.de> - 2016-03-28 15:00 +0200
                Re: ARC dw-mshc binding compat string Marek Vasut <marex@denx.de> - 2016-03-28 15:00 +0200
                Re: ARC dw-mshc binding compat string Vladimir Zapolskiy <vladimir_zapolskiy@mentor.com> - 2016-03-28 18:20 +0200
                Re: ARC dw-mshc binding compat string Rob Herring <robh+dt@kernel.org> - 2016-03-28 21:10 +0200
        Re: ARC dw-mshc binding compat string Marek Vasut <marex@denx.de> - 2016-03-26 19:20 +0100

csiph-web