[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PULL 1/3] hw/net/imx_fec: return 0xffff when accessing non-existing
From: |
Philippe Mathieu-Daudé |
Subject: |
Re: [PULL 1/3] hw/net/imx_fec: return 0xffff when accessing non-existing PHY |
Date: |
Wed, 26 May 2021 11:08:32 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.10.1 |
On 5/26/21 10:24 AM, Jason Wang wrote:
> From: Guenter Roeck <linux@roeck-us.net>
>
> If a PHY does not exist, attempts to read from it should return 0xffff.
> Otherwise the Linux kernel will believe that a PHY is there and select
> the non-existing PHY. This in turn will result in network errors later
> on since the real PHY is not selected or configured.
>
> Since reading from or writing to a non-existing PHY is not an emulation
> error, replace guest error messages with traces.
>
> Fixes: 461c51ad4275 ("Add a phy-num property to the i.MX FEC emulator")
> Cc: Jean-Christophe Dubois <jcd@tribudubois.net>
> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
> Tested-by: Bin Meng <bmeng.cn@gmail.com>
> Reviewed-by: Philippe Mathieu-Daud茅 <f4bug@amsat.org>
Mojibake :/
> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
> Signed-off-by: Jason Wang <jasowang@redhat.com>
> ---
> hw/net/imx_fec.c | 8 +++-----
> hw/net/trace-events | 2 ++
> 2 files changed, 5 insertions(+), 5 deletions(-)