From: Herve Codina <herve.codina@bootlin.com>
To: Herve Codina <herve.codina@bootlin.com>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Vinod Koul <vkoul@kernel.org>,
Kishon Vijay Abraham I <kishon@kernel.org>
Cc: linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
linux-phy@lists.infradead.org,
Christophe Leroy <christophe.leroy@csgroup.eu>,
Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Subject: [RFC PATCH 0/4] Hi,
Date: Thu, 23 Mar 2023 11:26:51 +0100 [thread overview]
Message-ID: <20230323102655.264115-1-herve.codina@bootlin.com> (raw)
I have a system where I need to handle an HDLC interface.
The HDLC data are transferred using a TDM bus on which a PEF2256 is
present. The PEF2256 transfers data from/to the TDM bus to/from E1 line.
This PEF2256 is also connected to a PowerQUICC SoC for the control path
and the TDM is connected to the SoC (QMC component) for the data path.
From the HDLC driver, I need to handle data using the QMC and carrier
detection using the PEF2256 (E1 line carrier).
The HDLC driver consider the PEF2256 as a generic PHY.
So, the design is the following:
+----------+ +-------------+ +---------+
| HDLC drv | <-data-> | QMC channel | <-- TDM --> | PEF2256 |
+----------+ +-------------+ | | <--> E1
^ +---------+ +---------+ | |
+-> | Gen PHY | <-> | PEF2256 | <- local bus -> | |
+---------+ | PHY drv | +---------+
+---------+
In order to implement this, I had to:
1 - Extend the generic PHY API to support get_status() and notification
on status change.
2 - Introduce a new kind of generic PHY named "basic phy". This PHY
familly can provide a link status in the get_status() data.
3 - Support the PEF2256 PHY as a "basic phy"
The purpose of this RFC series is to discuss this design.
The QMC driver code is available on linux-next. In this series:
- patch 1: driver HDLC using the QMC channel
- patch 2: Extend the generic PHY API
- patch 3: Use the "basic phy" in the HDLC driver
- patch 4: Implement the PEF2256 PHY driver
I did 2 patches for the HDLC driver in order to point the new PHY family
usage in the HDLC driver. In the end, these two patches will be squashed
and the bindings will be added.
Hope to have some feedback on this proposal.
Best regards,
Hervé
Herve Codina (4):
net: wan: Add support for QMC HDLC
phy: Extend API to support 'status' get and notification
net: wan: fsl_qmc_hdlc: Add PHY support
phy: lantiq: Add PEF2256 PHY support
drivers/net/wan/Kconfig | 12 +
drivers/net/wan/Makefile | 1 +
drivers/net/wan/fsl_qmc_hdlc.c | 558 ++++++++++++++++++++++++
drivers/phy/lantiq/Kconfig | 15 +
drivers/phy/lantiq/Makefile | 1 +
drivers/phy/lantiq/phy-lantiq-pef2256.c | 131 ++++++
drivers/phy/phy-core.c | 88 ++++
include/linux/phy/phy-basic.h | 27 ++
include/linux/phy/phy.h | 89 +++-
9 files changed, 921 insertions(+), 1 deletion(-)
create mode 100644 drivers/net/wan/fsl_qmc_hdlc.c
create mode 100644 drivers/phy/lantiq/phy-lantiq-pef2256.c
create mode 100644 include/linux/phy/phy-basic.h
--
2.39.2
--
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy
next reply other threads:[~2023-03-23 10:27 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-23 10:26 Herve Codina [this message]
2023-03-23 10:26 ` [RFC PATCH 1/4] net: wan: Add support for QMC HDLC Herve Codina
2023-03-23 10:26 ` [RFC PATCH 2/4] phy: Extend API to support 'status' get and notification Herve Codina
2023-03-23 10:26 ` [RFC PATCH 3/4] net: wan: fsl_qmc_hdlc: Add PHY support Herve Codina
2023-03-23 10:26 ` [RFC PATCH 4/4] phy: lantiq: Add PEF2256 " Herve Codina
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=20230323102655.264115-1-herve.codina@bootlin.com \
--to=herve.codina@bootlin.com \
--cc=christophe.leroy@csgroup.eu \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kishon@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-phy@lists.infradead.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=thomas.petazzoni@bootlin.com \
--cc=vkoul@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;
as well as URLs for NNTP newsgroup(s).