qemu-arm
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v3] arm/aspeed: Rework NIC attachment


From: Joel Stanley
Subject: Re: [PATCH v3] arm/aspeed: Rework NIC attachment
Date: Thu, 28 May 2020 07:25:47 +0000

On Wed, 27 May 2020 at 12:44, Cédric Le Goater <clg@kaod.org> wrote:
>
> 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
> for the AST2600. The model initializes the maximum number of supported
> MACs but the number of realized devices is capped by the number of
> 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 may 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
>
> Signed-off-by: Cédric Le Goater <clg@kaod.org>
> Reviewed-by: Markus Armbruster <armbru@redhat.com>

Reviewed-by: Joel Stanley <joel@jms.id.au>

This is a good usability improvement, thanks Cédric.

> @@ -680,6 +691,7 @@ static void 
> aspeed_machine_ast2600_evb_class_init(ObjectClass *oc, void *data)
>      amc->fmc_model = "w25q512jv";
>      amc->spi_model = "mx66u51235f";
>      amc->num_cs    = 1;
> +    amc->macs_mask  = ASPEED_MAC1_ON | ASPEED_MAC2_ON | ASPEED_MAC3_ON;

In the future we could enable all four. The A0 silicon had a broken
MAC4 but it is working on A1.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]