linux-spi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: <Prajna.Rajendrakumar@microchip.com>
To: <broonie@kernel.org>, <krzk@kernel.org>
Cc: <linux-spi@vger.kernel.org>, <linux-riscv@lists.infradead.org>,
	<Conor.Dooley@microchip.com>, <devicetree@vger.kernel.org>,
	<robh@kernel.org>, <linux-kernel@vger.kernel.org>,
	<krzk+dt@kernel.org>, <Valentina.FernandezAlanis@microchip.com>,
	<Daire.McNamara@microchip.com>
Subject: Re: [PATCH 2/3] spi: dt-bindings: Add num-cs property for mpfs-spi
Date: Fri, 3 May 2024 12:54:19 +0000	[thread overview]
Message-ID: <1edb6c4c1a66c1a2009278b99f897e3a71b592c6.camel@microchip.com> (raw)
In-Reply-To: <10671947-f418-4520-a29f-4ce129770e65@kernel.org>

On Thu, 2024-05-02 at 16:53 +0200, Krzysztof Kozlowski wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you
> know the content is safe
> 
> On 02/05/2024 16:34, Prajna Rajendra Kumar wrote:
> > The PolarFire SoC SPI controller supports multiple chip selects,but
> > in
> > the MSS, only one CS line is physically wired. To reflect this
> > hardware
> > limitation in the device tree, the binding enforces that the 'num-
> > cs'
> > property defaults to 1 and cannot exceed 1 unless additional
> > chip select lines are explicitly defined using GPIO descriptors.
> > 
> 

Hi,

> You marked it as Fix for bug, but I don't understand where the bug
> is.

The bug was that the PolarFire SoC SPI "hard" controller supports eight
chip selects, but only one chip select is connected and can be used.
This was not reflected in the device tree because default num-cs was
never set. Hence, it's marked as a fix.

> Do you describe above the issue or the solution?

It describes both the issue and the solution, but I will revise the
commit message as Conor Dooley suggested.
> 
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            const: microchip,mpfs-spi
> > +      not:
> > +        required:
> > +          - cs-gpios
> 
> I don't understand what you are expressing here. Did you actually
> validate it that it achieves exactly what you want?

Since the controller supports only one chip select, the num-cs should
default to 1 and cannot exceed 1 unless GPIOs are used as chip selects.

> > +    then:
> > +      properties:
> > +        num-cs:
> > +          default: 1
> > +          maximum: 1
> > +
> >  unevaluatedProperties: false
> > 
> >  examples:
> 
> Best regards,
> Krzysztof
> 
Best regards,
Prajna

  reply	other threads:[~2024-05-03 12:54 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-02 14:34 [PATCH 0/3] Add support for GPIO based CS Prajna Rajendra Kumar
2024-05-02 14:34 ` [PATCH 1/3] spi: spi-microchip-core: " Prajna Rajendra Kumar
2024-05-02 15:54   ` Conor Dooley
2024-05-03  5:27   ` kernel test robot
2024-05-03  5:37   ` kernel test robot
2024-05-02 14:34 ` [PATCH 2/3] spi: dt-bindings: Add num-cs property for mpfs-spi Prajna Rajendra Kumar
2024-05-02 14:53   ` Krzysztof Kozlowski
2024-05-03 12:54     ` Prajna.Rajendrakumar [this message]
2024-05-03 14:46       ` Krzysztof Kozlowski
2024-05-03 16:11         ` Conor Dooley
2024-05-07  7:57         ` Prajna.Rajendrakumar
2024-05-03 10:40   ` Conor Dooley
2024-05-02 14:34 ` [PATCH 3/3] spi: spi-microchip-core: Fix the number of chip selects supported Prajna Rajendra Kumar
2024-05-02 15:47   ` Conor Dooley

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=1edb6c4c1a66c1a2009278b99f897e3a71b592c6.camel@microchip.com \
    --to=prajna.rajendrakumar@microchip.com \
    --cc=Conor.Dooley@microchip.com \
    --cc=Daire.McNamara@microchip.com \
    --cc=Valentina.FernandezAlanis@microchip.com \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=krzk@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=linux-spi@vger.kernel.org \
    --cc=robh@kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).