2
0
Fork 0
mirror of https://github.com/AsahiLinux/u-boot synced 2024-12-28 14:03:44 +00:00
u-boot/board/gdsys/a38x
Marek Behún e24b58f5ed net: phy: don't require PHY interface mode during PHY creation
Currently we require PHY interface mode to be known when
finding/creating the PHY - the functions
  * phy_connect_phy_id()
  * phy_device_create()
  * create_phy_by_mask()
  * search_for_existing_phy()
  * get_phy_device_by_mask()
  * phy_find_by_mask()
all require the interface parameter, but the only thing done with it is
that it is assigned to phydev->interface.

This makes it impossible to find a PHY device without overwriting the
set mode.

Since the interface mode is not used during .probe() and should be used
at first in .config(), drop the interface parameter from these
functions. Make the default value of phydev->interface (in
phy_device_create()) to be PHY_INTERFACE_MODE_NA. Move the interface
parameter to phy_connect_dev(), where it should be.

Change all occurrences treewide. In occurrences where we don't call
phy_connect_dev() for some reason (they only configure the PHY without
connecting it to an ethernet controller), set
  phydev->interface = value from phy_find_by_mask call.

Signed-off-by: Marek Behún <marek.behun@nic.cz>
Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
Reviewed-by: Vladimir Oltean <vladimir.oltean@nxp.com>
2022-04-10 08:44:13 +03:00
..
controlcenterdc.c net: phy: don't require PHY interface mode during PHY creation 2022-04-10 08:44:13 +03:00
dt_helpers.c WS cleanup: remove trailing empty lines 2021-09-30 08:08:56 -04:00
dt_helpers.h SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
hre.c doc: replace @return by Return: 2022-01-19 18:11:34 +01:00
hre.h tpm: Convert to use a device parameter 2018-11-29 09:30:06 -07:00
hydra.c common: Drop asm/global_data.h from common header 2021-02-02 15:33:42 -05:00
hydra.h arm: mvebu: Add gdsys ControlCenter-Compact board 2017-03-23 15:48:28 +01:00
ihs_phys.c net: phy: don't require PHY interface mode during PHY creation 2022-04-10 08:44:13 +03:00
ihs_phys.h arm: mvebu: Add gdsys ControlCenter-Compact board 2017-03-23 15:48:28 +01:00
keyprogram.c tpm: Switch TPMv1 over to use the new API 2021-03-02 15:53:37 -05:00
keyprogram.h tpm: Convert to use a device parameter 2018-11-29 09:30:06 -07:00
MAINTAINERS board: gdsys: Drop Dirk Eibach from MAINTAINERS 2022-01-14 07:47:57 +01:00
Makefile arm: mvebu: gdsys: Remove custom spl_board_init() 2021-07-31 09:59:58 +02:00