Commit 62720770 authored by Mikhail Kobuk's avatar Mikhail Kobuk Committed by Vinod Koul

phy: marvell: a3700-comphy: Fix hardcoded array size

Replace hardcoded 'gbe_phy_init' array size by explicit one.

Fixes: 93433708 ("phy: marvell: phy-mvebu-a3700-comphy: Add native kernel implementation")
Signed-off-by: default avatarMikhail Kobuk <m.kobuk@ispras.ru>
Link: https://lore.kernel.org/r/20240321164734.49273-2-m.kobuk@ispras.ruSigned-off-by: default avatarVinod Koul <vkoul@kernel.org>
parent e4308bc2
......@@ -603,7 +603,7 @@ static void comphy_gbe_phy_init(struct mvebu_a3700_comphy_lane *lane,
u16 val;
fix_idx = 0;
for (addr = 0; addr < 512; addr++) {
for (addr = 0; addr < ARRAY_SIZE(gbe_phy_init); addr++) {
/*
* All PHY register values are defined in full for 3.125Gbps
* SERDES speed. The values required for 1.25 Gbps are almost
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment