qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <philmd@redhat.com>
To: Markus Armbruster <armbru@redhat.com>, qemu-devel@nongnu.org
Cc: David Gibson <david@gibson.dropbear.id.au>, qemu-ppc@nongnu.org
Subject: Re: [PATCH v2 1/4] sam460ex: Suppress useless warning on -m 32 and -m 64
Date: Wed, 22 Apr 2020 16:44:09 +0200	[thread overview]
Message-ID: <007f94c0-3907-07f8-1c46-78a468a3af8a@redhat.com> (raw)
In-Reply-To: <20200422134815.1584-2-armbru@redhat.com>

On 4/22/20 3:48 PM, Markus Armbruster wrote:
> Requesting 32 or 64 MiB of RAM with the sam460ex machine type produces
> a useless warning:
> 
>      qemu-system-ppc: warning: Memory size is too small for SDRAM type, adjusting type
> 
> This is because sam460ex_init() asks spd_data_generate() for DDR2,
> which is impossible, so spd_data_generate() corrects it to DDR.
> 
> The warning goes back to commit 08fd99179a "sam460ex: Clean up SPD
> EEPROM creation".
> 
> Make sam460ex_init() pass the correct SDRAM type to get rid of the
> warning.
> 
> Signed-off-by: Markus Armbruster <armbru@redhat.com>
> ---
>   hw/ppc/sam460ex.c | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/hw/ppc/sam460ex.c b/hw/ppc/sam460ex.c
> index 898453cf30..1e3eaac0db 100644
> --- a/hw/ppc/sam460ex.c
> +++ b/hw/ppc/sam460ex.c
> @@ -335,7 +335,8 @@ static void sam460ex_init(MachineState *machine)
>       dev = sysbus_create_simple(TYPE_PPC4xx_I2C, 0x4ef600700, uic[0][2]);
>       i2c = PPC4xx_I2C(dev)->bus;
>       /* SPD EEPROM on RAM module */
> -    spd_data = spd_data_generate(DDR2, ram_sizes[0], &err);
> +    spd_data = spd_data_generate(ram_sizes[0] < 128 * MiB ? DDR : DDR2,
> +                                 ram_sizes[0], &err);

Previous to this patch question, don't we need one for each module? We 
have 4 banks... Ah, there is a comment earlier "/* put all RAM on first 
bank because board has one slot". OK...

Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>

>       if (err) {
>           warn_report_err(err);
>       }
> 



  reply	other threads:[~2020-04-22 14:45 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-22 13:48 [PATCH v2 0/4] smbus: SPD fixes Markus Armbruster
2020-04-22 13:48 ` [PATCH v2 1/4] sam460ex: Suppress useless warning on -m 32 and -m 64 Markus Armbruster
2020-04-22 14:44   ` Philippe Mathieu-Daudé [this message]
2020-04-22 13:48 ` [PATCH v2 2/4] smbus: Fix spd_data_generate() error API violation Markus Armbruster
2020-04-22 14:27   ` BALATON Zoltan
2020-04-22 14:50     ` Philippe Mathieu-Daudé
2020-04-22 19:32       ` BALATON Zoltan
2020-06-26 11:30         ` BALATON Zoltan
2020-06-27  7:17           ` Markus Armbruster
2020-06-27 11:30             ` BALATON Zoltan
2020-06-29 15:56               ` Markus Armbruster
2020-06-30  1:30                 ` BALATON Zoltan
2020-06-29 19:00             ` Philippe Mathieu-Daudé
2020-06-29 21:31               ` BALATON Zoltan
2020-06-30  6:09                 ` Philippe Mathieu-Daudé
2020-06-30  9:27                   ` BALATON Zoltan
2020-04-22 13:48 ` [PATCH v2 3/4] bamboo, sam460ex: Tidy up error message for unsupported RAM size Markus Armbruster
2020-04-22 14:20   ` BALATON Zoltan
2020-04-22 14:22   ` Philippe Mathieu-Daudé
2020-04-22 13:48 ` [PATCH v2 4/4] smbus: Fix spd_data_generate() for number of banks > 2 Markus Armbruster
2020-04-22 18:26 ` [PATCH v2 0/4] smbus: SPD fixes no-reply
2020-04-29  7:14 ` 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=007f94c0-3907-07f8-1c46-78a468a3af8a@redhat.com \
    --to=philmd@redhat.com \
    --cc=armbru@redhat.com \
    --cc=david@gibson.dropbear.id.au \
    --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 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).