mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Ziyang Huang <hzyitc@outlook.com>
To: Andrew Lunn <andrew@lunn.ch>
Cc: olteanv@gmail.com, davem@davemloft.net, edumazet@google.com,
	kuba@kernel.org, pabeni@redhat.com, robh@kernel.org,
	krzk+dt@kernel.org, conor+dt@kernel.org,
	rmk+kernel@armlinux.org.uk, javier.carrasco.cruz@gmail.com,
	john@phrozen.org, netdev@vger.kernel.org,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] dt-bindings: net: dsa: qca8k: add internal-PHY-to-PHY CPU link example
Date: Tue, 4 Mar 2025 13:00:58 +0800	[thread overview]
Message-ID: <TYZPR01MB5556A170A7D60C75FC134ECEC9C82@TYZPR01MB5556.apcprd01.prod.exchangelabs.com> (raw)
In-Reply-To: <55a2e7d3-f201-48d7-be4e-5d1307e52f56@lunn.ch>

在 2025/3/4 1:15, Andrew Lunn 写道:
> On Tue, Mar 04, 2025 at 12:37:36AM +0800, Ziyang Huang wrote:
>> 在 2025/3/4 0:15, Andrew Lunn 写道:
>>> ...
>>>
>>> The previous patch still causes it to look at port 0 and then port 6
>>> first. Only if they are not CPU ports will it look at other ports. So
>>> this example does not work, port 6 will be the CPU port, even with the
>>> properties you added.
>>
>> Sorry, I forget that the following patch is still penging:
>> https://lore.kernel.org/all/20230620063747.19175-1-ansuelsmth@gmail.com/
>>
>> With this path, we can have multi CPU link.
> 
> So you should get that merged first. Then this patch.

After checking the code again, the demo 2 has already had 2 CPU link
(Port0 and Port6). Could I just keep this or should I need to add a new
case ?

>>> When you fix this, i also think it would be good to extend:
>>>
>>>> +                    /* PHY-to-PHY CPU link */
>>>
>>> with the work internal.
>>>
>>> This also seems an odd architecture to me. If this is SoC internal,
>>> why not do a MAC to MAC link? What benefit do you get from having the
>>> PHYs?
>>
>> This patches are for IPQ50xx platform which has only one a SGMII/SGMII+ link
>> and a MDI link.
>>
>> It has 2 common designs:
>>   1. SGMII+ is used to connect a 2.5G PHY, which make qca8337 only be able to
>> be connected through the MDI link.
> 
> Please do not call it SGMII+. It is not SGMII if it is running at
> 2.5G. It is more likely to be broken 2500BaseX, broken in that it does
> not implement the inband signalling.
> 
>>   2. Both SGMII and MDI links are used to connect the qca8337, so we can get
>> 2G link which is beneficial in NAT mode (total 2G bidirectional).
> 
> So is this actually internally? Or do you have a IPQ50xx SoC connected
> to a qca8337 switch, with copper traces on a PCB? If so, it is not
> internal.

I think I known which point you are confused about. Sorry for my poor
English.

The "internal" is used to describe the localcation of PHY not the link.
In current code, qca8k has supported to use a external PHY to do a
PHY-to-PHY link (Port0 and Port6). This patch make the internal PHYs
support it too (Port1-5).

The followiing topology is existed in most IPQ50xx-based router:
      _______________________         _______________________
     |        IPQ5018        |       |        QCA8337        |
     | +------+   +--------+ |       | +--------+   +------+ |
     | | MAC0 |---| GE Phy |-+--MDI--+-|  Phy4  |---| MAC5 | |
     | +------+   +--------+ |       | +--------+   +------+ |
     | +------+   +--------+ |       | +--------+   +------+ |
     | | MAC1 |---| Uniphy |-+-SGMII-+-| SerDes |---| MAC0 | |
     | +------+   +--------+ |       | +--------+   +------+ |
     |_______________________|       |_______________________|

> 	Andrew


  reply	other threads:[~2025-03-04  5:01 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-03 15:22 [PATCH 0/2] net: dsa: qca8k: support internal-PHY-to-PHY CPU link Ziyang Huang
2025-03-03 15:24 ` [PATCH 1/2] " Ziyang Huang
2025-03-03 15:24 ` [PATCH 2/2] dt-bindings: net: dsa: qca8k: add internal-PHY-to-PHY CPU link example Ziyang Huang
2025-03-03 16:15   ` Andrew Lunn
2025-03-03 16:37     ` Ziyang Huang
2025-03-03 17:15       ` Andrew Lunn
2025-03-04  5:00         ` Ziyang Huang [this message]
     [not found]         ` <dbd0e376-d7c3-4ba9-886b-ba9529a2ec4e@outlook.com>
2025-03-04 14:11           ` Andrew Lunn
2025-03-05 14:41             ` Ziyang Huang

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=TYZPR01MB5556A170A7D60C75FC134ECEC9C82@TYZPR01MB5556.apcprd01.prod.exchangelabs.com \
    --to=hzyitc@outlook.com \
    --cc=andrew@lunn.ch \
    --cc=conor+dt@kernel.org \
    --cc=davem@davemloft.net \
    --cc=devicetree@vger.kernel.org \
    --cc=edumazet@google.com \
    --cc=javier.carrasco.cruz@gmail.com \
    --cc=john@phrozen.org \
    --cc=krzk+dt@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    --cc=pabeni@redhat.com \
    --cc=rmk+kernel@armlinux.org.uk \
    --cc=robh@kernel.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

all inboxes | Powered by JetHome®