[PATCH u-boot-net 03/14] net: introduce helpers to get PHY ofnode from MAC

Marek Behún kabel at kernel.org
Mon Mar 28 23:51:23 CEST 2022


On Mon, 28 Mar 2022 00:35:00 -0600
Simon Glass <sjg at chromium.org> wrote:

> Hi Marek,
> 
> On Thu, 17 Mar 2022 at 06:50, Marek Behún <kabel at kernel.org> wrote:
> >
> > From: Marek Behún <marek.behun at nic.cz>
> >
> > Add helpers ofnode_get_phy_node() and dev_get_phy_node() and use it in
> > net/mdio-uclass.c function dm_eth_connect_phy_handle().
> >
> > This is useful because other part's of U-Boot may want to get PHY ofnode
> > without connecting a PHY.
> >
> > Signed-off-by: Marek Behún <marek.behun at nic.cz>
> > ---
> >  drivers/core/ofnode.c | 21 +++++++++++++++++++++
> >  drivers/core/read.c   |  5 +++++
> >  include/dm/ofnode.h   | 14 ++++++++++++++
> >  include/dm/read.h     | 19 +++++++++++++++++++
> >  net/mdio-uclass.c     | 24 ++++++------------------
> >  5 files changed, 65 insertions(+), 18 deletions(-)  
> 
> Please add a test for your new function. With that:
> 
> Reviewed-by: Simon Glass <sjg at chromium.org>

Dear Simon,

OK, I added test for ofnode_get_phy_node(). Should I also add one for
dev_get_phy_node() ? That one is implemented in drivers/core/read.c or
include/dm/read.h, and it just calls ofnode_get_phy_node()...

Also adding test for ofnode_get_phy_mode() (node -> mode) which is
implemented in patch 07/14. Can I add your reviewde-by for that patch
also? That patch is rather big, touches many files treewide...

Marek


More information about the U-Boot mailing list