U-Boot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Caleb Connolly <caleb.connolly@linaro.org>
To: Tom Rini <trini@konsulko.com>
Cc: Christian Marangi <ansuelsmth@gmail.com>,
	Dragan Simic <dsimic@manjaro.org>,
	Ilias Apalodimas <ilias.apalodimas@linaro.org>,
	Jaehoon Chung <jh80.chung@samsung.com>,
	Jerome Forissier <jerome.forissier@linaro.org>,
	Jonas Karlman <jonas@kwiboo.se>,
	Marek Vasut <marek.vasut+renesas@mailbox.org>,
	Peng Fan <peng.fan@nxp.com>,
	Peter Robinson <pbrobinson@gmail.com>,
	Rasmus Villemoes <rasmus.villemoes@prevas.dk>,
	Simon Glass <sjg@chromium.org>,
	Sughosh Ganu <sughosh.ganu@linaro.org>,
	u-boot@lists.denx.de
Subject: Re: [PATCH] mmc: don't print 'MMC:' if there are no MMC devices
Date: Thu, 14 Nov 2024 19:05:48 +0100	[thread overview]
Message-ID: <46b5f2c5-efbd-41b1-bd93-2f1ecc81eea4@linaro.org> (raw)
In-Reply-To: <20241114180244.GK3600562@bill-the-cat>

Hi Tom,

On 14/11/2024 19:02, Tom Rini wrote:
> On Wed, Nov 13, 2024 at 03:47:16PM +0100, Caleb Connolly wrote:
>>
>>
>> On 13/11/2024 15:24, Tom Rini wrote:
>>> On Wed, Nov 13, 2024 at 06:30:08AM +0100, Caleb Connolly wrote:
>>>
>>>> It may be the case that MMC support is enabled even though the board
>>>> we're booting on doesn't have any MMC devices. Move the print over to
>>>> the print_mmc_devices() function where we can only print it if we
>>>> actually have MMC devices.
>>>>
>>>> Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
>>>
>>> I'm not sure I like this. What we do / don't find on startup is part of
>>> the not-exactly-API. It's true that if we don't print an MMC line at
>>> all, and we should have MMC, the user (and any scripts that parse
>>> console output) but now we're also increasing the code size a little bit
>>> too. I can be convinced this is a good idea, but I'm not there yet.
>>
>> Hmm, fair enough. I'll offer some more context, maybe there's a smarter
>> approach here I'm not seeing.
>>
>> The main place this shows up is on Qualcomm boards. Since all Qualcomm
>> armv8 targets are supported with qcom_defconfig (just by adjusting which
>> DTB is used), we can't know at build time whether the board has MMC.
>>
>> I guess my thinking behind this patch comes from a bigger picture desire
>> to get UFS and MMC more aligned. The number of devices with UFS is
>> definitely going up, and I would argue that U-Boot's inconsistent
>> treatment of these two storage classes (obviously a result of their
>> relative age and support in the codebase) is really unintuitive and
>> weird for users (nevermind that the "scsi" command is used for UFS
>> devices, cute though it is).
>>
>> I'm really wary to open this whole can of worms, since I guess it would
>> require some larger efforts and collaboration to fix. But maybe this
>> patch (or one like it) would be better suited in the context of some
>> larger effort to unify storage backends?
> 
> I get it now, thanks. And yeah, this is part of our inconsistency in
> printing information. I'd rather leave things alone here (assuming the
> MMC: printout is reasonable in the case of no devices, similar to how
> the Net: printout is reasonable in that case) and wait for a longer term
> / high level solution wherein for example as we go down the device tree
> we give some consistent level of information for everything (and more or
> less info depending on verbosity configured perhaps).
> 

Thanks for taking a look. Something like what you're suggesting sounds
good to me, and I agree it's fine to leave things as-is until we have
such a plan.

Kind regards,

-- 
// Caleb (they/them)


  reply	other threads:[~2024-11-14 18:05 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20241113053033epcas1p2f8d1ef98103f17f5442279ac21a898fc@epcas1p2.samsung.com>
2024-11-13  5:30 ` [PATCH] mmc: don't print 'MMC:' if there are no MMC devices Caleb Connolly
2024-11-13  7:43   ` Ilias Apalodimas
2024-11-13  9:48   ` Dragan Simic
2024-11-13 13:08     ` Caleb Connolly
2024-11-13 13:15       ` Dragan Simic
2024-11-13 14:24   ` Tom Rini
2024-11-13 14:47     ` Caleb Connolly
2024-11-14  7:34       ` Jaehoon Chung
2024-11-14 18:02       ` Tom Rini
2024-11-14 18:05         ` Caleb Connolly [this message]
2024-11-14  6:54   ` Jaehoon Chung

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=46b5f2c5-efbd-41b1-bd93-2f1ecc81eea4@linaro.org \
    --to=caleb.connolly@linaro.org \
    --cc=ansuelsmth@gmail.com \
    --cc=dsimic@manjaro.org \
    --cc=ilias.apalodimas@linaro.org \
    --cc=jerome.forissier@linaro.org \
    --cc=jh80.chung@samsung.com \
    --cc=jonas@kwiboo.se \
    --cc=marek.vasut+renesas@mailbox.org \
    --cc=pbrobinson@gmail.com \
    --cc=peng.fan@nxp.com \
    --cc=rasmus.villemoes@prevas.dk \
    --cc=sjg@chromium.org \
    --cc=sughosh.ganu@linaro.org \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    /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