qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/1] hw/net: Support Marvell 88E1111 phy driver
@ 2024-11-15  1:47 Fea.Wang
  2024-12-11  6:03 ` Fea Wang
  0 siblings, 1 reply; 2+ messages in thread
From: Fea.Wang @ 2024-11-15  1:47 UTC (permalink / raw)
  To: qemu-devel, qemu-riscv
  Cc: Edgar E. Iglesias, Alistair Francis, Peter Maydell, Jason Wang,
	open list:Xilinx Zynq, Fea.Wang

When the ethernet PHY's compatible string is 'ethernet-phy-id0141.0cc2',
it will be matched with the Marvell driver in Linux instead of the
generic driver. They differ from reading the PHY register17.11 bit which
is for 'Speed and Duplex Resolved' and the value 0 will clear
phydev->link and stop the flow. To avoid getting stuck, change the
constant return value in QEMU for the bit to 1 to keep the driver going.

Signed-off-by: Fea.Wang <fea.wang@sifive.com>
---
 hw/net/xilinx_axienet.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/net/xilinx_axienet.c b/hw/net/xilinx_axienet.c
index faf27947b0..ee4b3afe9c 100644
--- a/hw/net/xilinx_axienet.c
+++ b/hw/net/xilinx_axienet.c
@@ -102,7 +102,7 @@ static unsigned int tdk_read(struct PHY *phy, unsigned int req)
             break;
         case 17:
             /* Marvell PHY on many xilinx boards.  */
-            r = 0x8000; /* 1000Mb  */
+            r = 0x8800; /* 1000Mb  */
             break;
         case 18:
             {
-- 
2.34.1



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH 1/1] hw/net: Support Marvell 88E1111 phy driver
  2024-11-15  1:47 [PATCH 1/1] hw/net: Support Marvell 88E1111 phy driver Fea.Wang
@ 2024-12-11  6:03 ` Fea Wang
  0 siblings, 0 replies; 2+ messages in thread
From: Fea Wang @ 2024-12-11  6:03 UTC (permalink / raw)
  To: qemu-devel, qemu-riscv
  Cc: Edgar E. Iglesias, Alistair Francis, Peter Maydell, Jason Wang,
	open list:Xilinx Zynq

[-- Attachment #1: Type: text/plain, Size: 1194 bytes --]

Ping

On Fri, Nov 15, 2024 at 9:44 AM Fea.Wang <fea.wang@sifive.com> wrote:

> When the ethernet PHY's compatible string is 'ethernet-phy-id0141.0cc2',
> it will be matched with the Marvell driver in Linux instead of the
> generic driver. They differ from reading the PHY register17.11 bit which
> is for 'Speed and Duplex Resolved' and the value 0 will clear
> phydev->link and stop the flow. To avoid getting stuck, change the
> constant return value in QEMU for the bit to 1 to keep the driver going.
>
> Signed-off-by: Fea.Wang <fea.wang@sifive.com>
> ---
>  hw/net/xilinx_axienet.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/hw/net/xilinx_axienet.c b/hw/net/xilinx_axienet.c
> index faf27947b0..ee4b3afe9c 100644
> --- a/hw/net/xilinx_axienet.c
> +++ b/hw/net/xilinx_axienet.c
> @@ -102,7 +102,7 @@ static unsigned int tdk_read(struct PHY *phy, unsigned
> int req)
>              break;
>          case 17:
>              /* Marvell PHY on many xilinx boards.  */
> -            r = 0x8000; /* 1000Mb  */
> +            r = 0x8800; /* 1000Mb  */
>              break;
>          case 18:
>              {
> --
> 2.34.1
>
>

[-- Attachment #2: Type: text/html, Size: 1781 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-12-11  6:05 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-15  1:47 [PATCH 1/1] hw/net: Support Marvell 88E1111 phy driver Fea.Wang
2024-12-11  6:03 ` Fea Wang

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).