qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Markus Armbruster <armbru@redhat.com>
To: "Cédric Le Goater" <clg@kaod.org>
Cc: "Peter Maydell" <peter.maydell@linaro.org>,
	"Andrew Jeffery" <andrew@aj.id.au>,
	qemu-devel@nongnu.org, qemu-arm@nongnu.org,
	"Joel Stanley" <joel@jms.id.au>,
	"Philippe Mathieu-Daudé" <philmd@redhat.com>
Subject: Re: [PATCH v2] arm/aspeed: Rework NIC attachment
Date: Wed, 27 May 2020 13:47:46 +0200	[thread overview]
Message-ID: <871rn5r44d.fsf@dusky.pond.sub.org> (raw)
In-Reply-To: <20200526070802.160897-1-clg@kaod.org> (=?utf-8?Q?=22C=C3=A9d?= =?utf-8?Q?ric?= Le Goater"'s message of "Tue, 26 May 2020 09:08:02 +0200")

Cédric Le Goater <clg@kaod.org> writes:

> The number of MACs supported by an Aspeed SoC is defined by "macs_num"
> under the SoC model, that is two for the AST2400 and AST2500 and four
> the AST2600. The model initializes the maximum number of supported
> MACs but the number of realized devices is caped by the number of

s/caped/capped/

> network device back-ends defined on the command line. This can leave
> unrealized devices hanging around in the QOM composition tree.
>
> Modify the machine initialization to define which MACs are attached to
> a network device back-end using a bit-field property "macs-mask" and
> let the SoC realize all network devices.
>
> The default setting of "macs-mask" is "use MAC0" only, which works for
> all our AST2400 and AST2500 machines. The AST2600 machines have
> different configurations. The AST2600 EVB machine activates MAC1, MAC2
> and MAC3 and the Tacoma BMC machine activates MAC2.
>
> Inactive MACs will have no peer and QEMU will warn the user with :
>
>     qemu-system-arm: warning: nic ftgmac100.0 has no peer
>     qemu-system-arm: warning: nic ftgmac100.1 has no peer
>     qemu-system-arm: warning: nic ftgmac100.3 has no peer

This confused me, until I realized that QEMU sometimes supresses the
warning.

In vl.c:

    if (!default_net && (!qtest_enabled() || has_defaults)) {
        net_check_clients();
    }

Suppressed when none of -netdev, -nic, -net, -nodefaults is specified,
and also for -accel=qtest -nodefaults.

Say "QEMU may warn" instead?

I looked for other boards with onboard NICs.  As far as I can tell, they
all behave the same.

>
> Signed-off-by: Cédric Le Goater <clg@kaod.org>

Patch looks good, so
Reviewed-by: Markus Armbruster <armbru@redhat.com>



      reply	other threads:[~2020-05-27 11:48 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-26  7:08 [PATCH v2] arm/aspeed: Rework NIC attachment Cédric Le Goater
2020-05-27 11:47 ` Markus Armbruster [this message]

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=871rn5r44d.fsf@dusky.pond.sub.org \
    --to=armbru@redhat.com \
    --cc=andrew@aj.id.au \
    --cc=clg@kaod.org \
    --cc=joel@jms.id.au \
    --cc=peter.maydell@linaro.org \
    --cc=philmd@redhat.com \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@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).