mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: zhuyinbo <zhuyinbo@loongson.cn>
To: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>,
	Mark Brown <broonie@kernel.org>, Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	linux-spi@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org
Cc: Jianmin Lv <lvjianmin@loongson.cn>,
	wanghongliang@loongson.cn, Liu Peibao <liupeibao@loongson.cn>,
	loongson-kernel@lists.loongnix.cn, zhuyinbo@loongson.cn
Subject: Re: [PATCH v12 1/2] spi: add loongson spi bindings
Date: Mon, 12 Jun 2023 19:29:31 +0800	[thread overview]
Message-ID: <9fec9cfa-0686-91d8-cba4-91ea67243b47@loongson.cn> (raw)
In-Reply-To: <d24f1e60-0ef3-2cb9-9675-846d861ef0c8@linaro.org>



在 2023/6/12 下午4:16, Krzysztof Kozlowski 写道:
>>>>>>>> 在 2023/6/8 下午7:45, Krzysztof Kozlowski 写道:
>>>>>>>>> On 08/06/2023 13:42, zhuyinbo wrote:
>>>>>>>>>> --- a/Documentation/devicetree/bindings/spi/loongson,ls2k-spi.yaml
>>>>>>>>>> +++ b/Documentation/devicetree/bindings/spi/loongson,ls2k-spi.yaml
>>>>>>>>>> @@ -16,6 +16,7 @@ properties:
>>>>>>>>>>          compatible:
>>>>>>>>>>            enum:
>>>>>>>>>>              - loongson,ls2k1000-spi
>>>>>>>>>> +      - loongson,ls2k0500-spi
>>>>>>>>>
>>>>>>>>> Aren't they compatible?
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Are you saying that the spi driver is compatible with 2k0500 ?
>>>>>>>
>>>>>>> Didn't you say this through 11 previous revisions?
>>>>>>
>>>>>>
>>>>>> Yes, did I understand your meaning incorrectly ?
>>>>>
>>>>> If they are compatible, then they are not part of one enum. They could
>>>>> not be as this would easily fail in testing of your DTS.
>>>>>
>>>>
>>>>
>>>> The "loongson,ls2k0500-spi" wasn't a compatible in previous version and
>>>> I will add "loongson,ls2k0500-spi" as a compatible in spi driver and
>>>> added it as a part of the one enum in dt-binding.
>>>
>>> No, because you claimed - if I understood correctly - that they are
>>> compatible. Don't add fake entries to the driver.
>>>
>>
>>
>> I'm a bit confused, and I just need to add 'loongson,ls2k0500-spi' as
>> one enum in dt-bindings, but driver don't add this entry ?
> 
> Compatibility is expressed with a list:
> https://devicetree-specification.readthedocs.io/en/latest/chapter2-devicetree-basics.html#compatible
> so it cannot be just one enum, but "items". There are hundreds of
> examples including example-schema.


Is it a description like the following?

  properties:
    compatible:
-    enum:
-      - loongson,ls2k1000-spi
+    oneOf:
+      - enum:
+          - loongson,ls2k1000-spi
+      - items:
+          - enum:
+              - loongson,ls2k1000-spi
+          - const: loongson,ls2k1000-spi
+      - items:
+          - enum:
+              - loongson,ls2k0500-spi
+          - const: loongson,ls2k1000-spi

    reg:


Thanks,
Yinbo


  reply	other threads:[~2023-06-12 11:39 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-08  7:28 [PATCH v12 0/2] spi: loongson: add bus driver for the loongson spi Yinbo Zhu
2023-06-08  7:28 ` [PATCH v12 1/2] spi: add loongson spi bindings Yinbo Zhu
2023-06-08  7:45   ` Krzysztof Kozlowski
2023-06-08  8:39     ` zhuyinbo
2023-06-08  8:53       ` Krzysztof Kozlowski
2023-06-08 10:00         ` zhuyinbo
2023-06-08 10:02           ` Krzysztof Kozlowski
2023-06-08 11:42             ` zhuyinbo
2023-06-08 11:45               ` Krzysztof Kozlowski
2023-06-08 12:10                 ` zhuyinbo
2023-06-08 13:26                   ` Krzysztof Kozlowski
2023-06-09  3:13                     ` zhuyinbo
2023-06-09 16:45                       ` Krzysztof Kozlowski
2023-06-12  7:13                         ` zhuyinbo
2023-06-12  7:17                           ` Krzysztof Kozlowski
2023-06-12  7:40                             ` zhuyinbo
2023-06-12  8:16                               ` Krzysztof Kozlowski
2023-06-12 11:29                                 ` zhuyinbo [this message]
2023-06-12 18:03                                   ` Krzysztof Kozlowski
2023-06-13  2:04                                     ` zhuyinbo
2023-06-08  7:28 ` [PATCH v12 2/2] spi: loongson: add bus driver for the loongson spi controller Yinbo Zhu
2023-06-08 10:15   ` Andy Shevchenko
2023-06-08 10:18     ` Andy Shevchenko
2023-06-09  7:13       ` zhuyinbo
2023-06-08 10:29     ` Mark Brown
2023-06-08 11:45       ` zhuyinbo
2023-06-08 11:53         ` Mark Brown
2023-06-09  3:17           ` zhuyinbo
2023-06-09  7:10     ` zhuyinbo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9fec9cfa-0686-91d8-cba4-91ea67243b47@loongson.cn \
    --to=zhuyinbo@loongson.cn \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=krzysztof.kozlowski@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-spi@vger.kernel.org \
    --cc=liupeibao@loongson.cn \
    --cc=loongson-kernel@lists.loongnix.cn \
    --cc=lvjianmin@loongson.cn \
    --cc=robh+dt@kernel.org \
    --cc=wanghongliang@loongson.cn \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®