
Hi Michal,
On Mon, Apr 26, 2021 at 8:31 PM Michal Simek michal.simek@xilinx.com wrote:
The commit 6c993815bbea ("net: phy: xilinx: Be compatible with live OF tree") change driver behavior to while loop which wasn't correct because the driver was looping over again and again. The reason was that ofnode_valid() is taking 0 as correct value.
I am still trying to understand the problem. The changes in 6c993815bbea sound correct from an fdtdec <=> OF API mapping perspective. If the new OF API does not work, the old fdtdec may fail too. Could you please explain a little bit?
Fix it by changing while loop to ofnode_for_each_subnode() which is only loop over available nodes.
Fixes: 6c993815bbea ("net: phy: xilinx: Be compatible with live OF tree") Signed-off-by: Michal Simek michal.simek@xilinx.com
drivers/net/phy/phy.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
Regards, Bin