All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Troy Mitchell" <troy.mitchell@linux.dev>
To: "Iker Pedrosa" <ikerpedrosam@gmail.com>,
	"Margherita Milani" <margherita.milani@amarulasolutions.com>
Cc: "Ulf Hansson" <ulf.hansson@linaro.org>,
	"Rob Herring" <robh@kernel.org>,
	"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
	"Conor Dooley" <conor+dt@kernel.org>,
	"Adrian Hunter" <adrian.hunter@intel.com>,
	"Paul Walmsley" <pjw@kernel.org>,
	"Palmer Dabbelt" <palmer@dabbelt.com>,
	"Albert Ou" <aou@eecs.berkeley.edu>,
	"Alexandre Ghiti" <alex@ghiti.fr>, "Yixun Lan" <dlan@kernel.org>,
	"Troy Mitchell" <troy.mitchell@linux.dev>,
	"Michael Opdenacker" <michael.opdenacker@rootcommit.com>,
	"Javier Martinez Canillas" <javierm@redhat.com>,
	<linux-mmc@vger.kernel.org>, <devicetree@vger.kernel.org>,
	<linux-riscv@lists.infradead.org>, <spacemit@lists.linux.dev>,
	<linux-kernel@vger.kernel.org>,
	"Anand Moon" <linux.amoon@gmail.com>
Subject: Re: [PATCH v8 8/9] riscv: dts: spacemit: k1-bananapi-f3: add SD card support with UHS modes
Date: Thu, 07 May 2026 18:45:07 +0800	[thread overview]
Message-ID: <DICDTHYTPDSP.210EBVHTQ6966@linux.dev> (raw)
In-Reply-To: <CABdCQ=OsPva9=YPdBd=3HW1OO7=_zJtpXjvaiA0WLEDT5Scs_Q@mail.gmail.com>

On Thu May 7, 2026 at 5:53 PM CST, Iker Pedrosa wrote:
> Hi,
>
> El jue, 7 may 2026 a las 10:20, Margherita Milani
> (<margherita.milani@amarulasolutions.com>) escribió:
>>
>> Good morning Iker,
>>
>> > Add complete SD card controller support with UHS high-speed modes.
>> >
>> > - Enable sdhci0 controller with 4-bit bus width
>> > - Configure card detect GPIO with inversion
>> > - Connect vmmc-supply to buck4 for 3.3V card power
>> > - Connect vqmmc-supply to aldo1 for 1.8V/3.3V I/O switching
>> > - Add dual pinctrl states for voltage-dependent pin configuration
>> > - Support UHS-I SDR25, SDR50, and SDR104 modes
>>
>>
>> Tested-by: Margherita Milani <margherita.milani@amarulasolutions.com>
>>
>> However I noticed it only works when CONFIG_I2C_K1 is enabled.
>> Michael Opdenacker told me it's necessary to enable the regulators
>> used by the mmc controller.
>> Should we add the dependency between CONFIG_MMC_SDHCI_OF_K1 and
>> CONFIG_I2C_K1? (Unless some boards don't have these dependency?)
>> Thank you for your patchset which was really nice!
>
> Thank you for catching this! You're absolutely right about the dependency.
>
> From what I can see, all current SpacemiT K1 boards follow this design
> pattern where the SD card power is provided by an I2C-controlled PMIC.
> However, before adding a hard dependency, I'd like to get input from
> the community, does anyone know of K1-based boards that provide SD
> card power through fixed regulators or other means that don't require
> I2C?
if K1 needs to switch between standard and high-speed (UHS) modes,
I believe the I2C-controlled PMIC is mandatory to handle the voltage
switching (typically 3.3V to 1.8V).

I don't think any board would want to be stuck in standard mode permanently.
If high-speed mode is an option, why not use it? I think adding this
dependency is a good idea, but keep in mind it also needs to depend on P1.

                            - Troy

WARNING: multiple messages have this Message-ID (diff)
From: "Troy Mitchell" <troy.mitchell@linux.dev>
To: "Iker Pedrosa" <ikerpedrosam@gmail.com>,
	"Margherita Milani" <margherita.milani@amarulasolutions.com>
Cc: Rob Herring <robh@kernel.org>, Conor Dooley <conor+dt@kernel.org>,
	Albert Ou <aou@eecs.berkeley.edu>,
	Michael Opdenacker <michael.opdenacker@rootcommit.com>,
	Alexandre Ghiti <alex@ghiti.fr>,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	Troy Mitchell <troy.mitchell@linux.dev>,
	linux-mmc@vger.kernel.org, Ulf Hansson <ulf.hansson@linaro.org>,
	linux-riscv@lists.infradead.org,
	Adrian Hunter <adrian.hunter@intel.com>,
	Palmer Dabbelt <palmer@dabbelt.com>, Yixun Lan <dlan@kernel.org>,
	Javier Martinez Canillas <javierm@redhat.com>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	spacemit@lists.linux.dev, Paul Walmsley <pjw@kernel.org>
Subject: Re: [PATCH v8 8/9] riscv: dts: spacemit: k1-bananapi-f3: add SD card support with UHS modes
Date: Thu, 07 May 2026 18:45:07 +0800	[thread overview]
Message-ID: <DICDTHYTPDSP.210EBVHTQ6966@linux.dev> (raw)
In-Reply-To: <CABdCQ=OsPva9=YPdBd=3HW1OO7=_zJtpXjvaiA0WLEDT5Scs_Q@mail.gmail.com>

On Thu May 7, 2026 at 5:53 PM CST, Iker Pedrosa wrote:
> Hi,
>
> El jue, 7 may 2026 a las 10:20, Margherita Milani
> (<margherita.milani@amarulasolutions.com>) escribió:
>>
>> Good morning Iker,
>>
>> > Add complete SD card controller support with UHS high-speed modes.
>> >
>> > - Enable sdhci0 controller with 4-bit bus width
>> > - Configure card detect GPIO with inversion
>> > - Connect vmmc-supply to buck4 for 3.3V card power
>> > - Connect vqmmc-supply to aldo1 for 1.8V/3.3V I/O switching
>> > - Add dual pinctrl states for voltage-dependent pin configuration
>> > - Support UHS-I SDR25, SDR50, and SDR104 modes
>>
>>
>> Tested-by: Margherita Milani <margherita.milani@amarulasolutions.com>
>>
>> However I noticed it only works when CONFIG_I2C_K1 is enabled.
>> Michael Opdenacker told me it's necessary to enable the regulators
>> used by the mmc controller.
>> Should we add the dependency between CONFIG_MMC_SDHCI_OF_K1 and
>> CONFIG_I2C_K1? (Unless some boards don't have these dependency?)
>> Thank you for your patchset which was really nice!
>
> Thank you for catching this! You're absolutely right about the dependency.
>
> From what I can see, all current SpacemiT K1 boards follow this design
> pattern where the SD card power is provided by an I2C-controlled PMIC.
> However, before adding a hard dependency, I'd like to get input from
> the community, does anyone know of K1-based boards that provide SD
> card power through fixed regulators or other means that don't require
> I2C?
if K1 needs to switch between standard and high-speed (UHS) modes,
I believe the I2C-controlled PMIC is mandatory to handle the voltage
switching (typically 3.3V to 1.8V).

I don't think any board would want to be stuck in standard mode permanently.
If high-speed mode is an option, why not use it? I think adding this
dependency is a good idea, but keep in mind it also needs to depend on P1.

                            - Troy

_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv

  reply	other threads:[~2026-05-07 10:45 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-13  8:02 [PATCH v8 0/9] riscv: spacemit: enable SD card support with UHS modes for OrangePi RV2 Iker Pedrosa
2026-04-13  8:02 ` Iker Pedrosa
2026-04-13  8:02 ` [PATCH v8 1/9] dt-bindings: mmc: spacemit,sdhci: add pinctrl support for voltage switching Iker Pedrosa
2026-04-13  8:02   ` Iker Pedrosa
2026-04-13  8:02 ` [PATCH v8 2/9] mmc: sdhci-of-k1: enable essential clock infrastructure for SD operation Iker Pedrosa
2026-04-13  8:02   ` Iker Pedrosa
2026-04-13  8:02 ` [PATCH v8 3/9] mmc: sdhci-of-k1: add regulator and pinctrl voltage switching support Iker Pedrosa
2026-04-13  8:02   ` Iker Pedrosa
2026-04-13  8:02 ` [PATCH v8 4/9] mmc: sdhci-of-k1: add comprehensive SDR tuning support Iker Pedrosa
2026-04-13  8:02   ` Iker Pedrosa
2026-04-13  8:02 ` [PATCH v8 5/9] riscv: dts: spacemit: k1: add SD card controller and pinctrl support Iker Pedrosa
2026-04-13  8:02   ` Iker Pedrosa
2026-04-13  8:02 ` [PATCH v8 6/9] riscv: dts: spacemit: k1-orangepi-rv2: add PMIC and power infrastructure Iker Pedrosa
2026-04-13  8:02   ` Iker Pedrosa
2026-04-13  8:02 ` [PATCH v8 7/9] riscv: dts: spacemit: k1-orangepi-rv2: add SD card support with UHS modes Iker Pedrosa
2026-04-13  8:02   ` Iker Pedrosa
2026-04-13  8:02 ` [PATCH v8 8/9] riscv: dts: spacemit: k1-bananapi-f3: " Iker Pedrosa
2026-04-13  8:02   ` Iker Pedrosa
2026-05-07  8:20   ` Margherita Milani
2026-05-07  8:20     ` Margherita Milani
2026-05-07  9:53     ` Iker Pedrosa
2026-05-07  9:53       ` Iker Pedrosa
2026-05-07 10:45       ` Troy Mitchell [this message]
2026-05-07 10:45         ` Troy Mitchell
2026-05-08 22:53         ` Yixun Lan
2026-05-08 22:53           ` Yixun Lan
2026-05-08 23:10           ` Yixun Lan
2026-05-08 23:10             ` Yixun Lan
2026-05-11  8:01             ` Iker Pedrosa
2026-05-11  8:01               ` Iker Pedrosa
2026-05-07 18:28   ` Aurelien Jarno
2026-05-07 18:28     ` Aurelien Jarno
2026-05-08 22:27     ` Yixun Lan
2026-05-08 22:27       ` Yixun Lan
2026-04-13  8:02 ` [PATCH v8 9/9] riscv: dts: spacemit: k1-musepi-pro: " Iker Pedrosa
2026-04-13  8:02   ` Iker Pedrosa
2026-04-13  8:07 ` [PATCH v8 0/9] riscv: spacemit: enable SD card support with UHS modes for OrangePi RV2 Krzysztof Kozlowski
2026-04-13  8:07   ` Krzysztof Kozlowski
2026-04-14  7:12   ` Iker Pedrosa
2026-04-14  7:12     ` Iker Pedrosa
2026-04-14  8:13     ` Troy Mitchell
2026-04-14  8:13       ` Troy Mitchell
2026-04-16  8:18       ` Iker Pedrosa
2026-04-16  8:18         ` Iker Pedrosa
2026-04-23  9:44         ` Krzysztof Kozlowski
2026-04-23  9:44           ` Krzysztof Kozlowski
2026-04-23 12:42 ` Anand Moon
2026-04-23 12:42   ` Anand Moon
2026-05-07  9:57   ` Iker Pedrosa
2026-05-07  9:57     ` Iker Pedrosa

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=DICDTHYTPDSP.210EBVHTQ6966@linux.dev \
    --to=troy.mitchell@linux.dev \
    --cc=adrian.hunter@intel.com \
    --cc=alex@ghiti.fr \
    --cc=aou@eecs.berkeley.edu \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dlan@kernel.org \
    --cc=ikerpedrosam@gmail.com \
    --cc=javierm@redhat.com \
    --cc=krzk+dt@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=linux.amoon@gmail.com \
    --cc=margherita.milani@amarulasolutions.com \
    --cc=michael.opdenacker@rootcommit.com \
    --cc=palmer@dabbelt.com \
    --cc=pjw@kernel.org \
    --cc=robh@kernel.org \
    --cc=spacemit@lists.linux.dev \
    --cc=ulf.hansson@linaro.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.