From: Markus Armbruster <armbru@redhat.com>
To: "Philippe Mathieu-Daudé" <philmd@redhat.com>
Cc: David Gibson <david@gibson.dropbear.id.au>,
qemu-ppc@nongnu.org, qemu-devel@nongnu.org
Subject: Re: [PATCH 2/4] smbus: Fix spd_data_generate() error API violation
Date: Fri, 24 Apr 2020 13:23:21 +0200 [thread overview]
Message-ID: <87wo65ktzq.fsf@dusky.pond.sub.org> (raw)
In-Reply-To: <ea6a25ab-17e9-1560-d1c3-9479bcecef54@redhat.com> ("Philippe Mathieu-Daudé"'s message of "Fri, 24 Apr 2020 12:18:44 +0200")
Philippe Mathieu-Daudé <philmd@redhat.com> writes:
> On 4/24/20 11:45 AM, Markus Armbruster wrote:
>> BALATON Zoltan <balaton@eik.bme.hu> writes:
>>> On Tue, 21 Apr 2020, Markus Armbruster wrote:
> [...]
>>>>
>>>> Here's what I actually disagree with:
>>>>
>>>> 1. QEMU warning the user about its choice of memory type, but only
>>>> sometimes. Why warn? There is nothing wrong, and there is nothing the
>>>> user can do to avoid the condition that triggers the warning.
>>>
>>> The memory size that triggers the warning is specified by the user so
>>> the user can do someting about it.
>>
>> There is no way to trigger the warning. If we dropped PATCH 1 instead
>> of fixing it as I did in v2, then the only way to trigger the warning is
>> -M sam460ex -m 64 or -m 32, and the only way to avoid it is to don't do
>> that.
>>
>> Why would a user care whether he gets DDR or DDR2 memory?
>
> To use a different firmware code path!
Let's see how that works out for users.
Assume machine foobar needs a non-default firmware for "small" memory
sizes, such as -m 64.
Alice doesn't know. She starts QEMU like this:
$ qemu-system-foo -M foobar -m 64
It hangs early in boot. Not good.
Except the warning from spd_data_generate() rides to her rescue!
qemu-system-foo: warning: Memory size is too small for SDRAM type, adjusting type
Since Alice is rather sharp, the warning makes her realize immediately
that she needs to use different firmware, like this:
$ qemu-system-foo -M foobar -m 64 -bios roms/foobar/firmware-small.bin
Okay, I'm done telling my fairy tale.
If you want helpful, make it work out of the box: default to the
firmware that actually works, don't make users guess which one they
need.
But one more time: this is all theoretical. We're talking about unused,
broken code. If you want to keep it, please add users, and fix it up.
next prev parent reply other threads:[~2020-04-24 11:24 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-20 13:28 [PATCH 0/4] Subject: [PATCH 0/4] smbus: SPD fixes Markus Armbruster
2020-04-20 13:28 ` [PATCH 1/4] sam460ex: Revert change to SPD memory type for <= 128 MiB Markus Armbruster
2020-04-20 14:12 ` BALATON Zoltan
2020-04-21 5:28 ` Markus Armbruster
2020-04-22 13:56 ` BALATON Zoltan
2020-04-29 5:18 ` Markus Armbruster
2020-04-20 13:28 ` [PATCH 2/4] smbus: Fix spd_data_generate() error API violation Markus Armbruster
2020-04-20 14:20 ` BALATON Zoltan
2020-04-21 5:28 ` Markus Armbruster
2020-04-22 13:43 ` BALATON Zoltan
2020-04-24 9:45 ` Markus Armbruster
2020-04-24 10:18 ` Philippe Mathieu-Daudé
2020-04-24 11:23 ` Markus Armbruster [this message]
2020-04-24 13:52 ` BALATON Zoltan
2020-04-29 5:42 ` Markus Armbruster
2020-04-20 13:28 ` [PATCH 3/4] bamboo, sam460ex: Tidy up error message for unsupported RAM size Markus Armbruster
2020-04-20 13:50 ` Philippe Mathieu-Daudé
2020-04-20 13:28 ` [PATCH 4/4] smbus: Fix spd_data_generate() for number of banks > 2 Markus Armbruster
2020-04-20 13:53 ` Philippe Mathieu-Daudé
2020-04-20 14:37 ` BALATON Zoltan
2020-04-21 4:57 ` Markus Armbruster
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=87wo65ktzq.fsf@dusky.pond.sub.org \
--to=armbru@redhat.com \
--cc=david@gibson.dropbear.id.au \
--cc=philmd@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.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.