The PF and VF drivers warn and return -EPROBE_DEFER when the AF has
not programmed the RVUM revision or does not answer the mailbox READY
message. That is expected until rvu_af has finished initializing, so
the warning is repeated on every deferred retry.
Use dev_err_probe() instead of dev_warn() so the expected deferral is
not printed at warning level. -EPROBE_DEFER is logged at debug level
and the reason is recorded in devices_deferred.
Signed-off-by: Juuso Rinta <redacted>
---
drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c | 11 ++++-------
drivers/net/ethernet/marvell/octeontx2/nic/otx2_vf.c | 5 ++---
2 files changed, 6 insertions(+), 10 deletions(-)
diff --git a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
index c995f2900..529040f3e 100644
--- a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
+++ b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
@@ -1167,10 +1167,9 @@ int otx2_register_mbox_intr(struct otx2_nic *pf, bool probe_af)
}
err = otx2_sync_mbox_msg(&pf->mbox);
if (err) {
- dev_warn(pf->dev,
- "AF not responding to mailbox, deferring probe\n");
otx2_disable_mbox_intr(pf);
- return -EPROBE_DEFER;
+ return dev_err_probe(pf->dev, -EPROBE_DEFER,
+ "AF not responding to mailbox, deferring probe\n");
}
return 0;@@ -2993,11 +2992,9 @@ int otx2_check_pf_usable(struct otx2_nic *nic)
* otherwise this driver probe should be deferred
* until AF driver comes up.
*/
- if (!rev) {
- dev_warn(nic->dev,
+ if (!rev)
+ return dev_err_probe(nic->dev, -EPROBE_DEFER,
"AF is not initialized, deferring probe\n");
- return -EPROBE_DEFER;
- }
return 0;
}
diff --git a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_vf.c b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_vf.c
index fcdf891f9..a02267978 100644
--- a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_vf.c
+++ b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_vf.c
@@ -297,10 +297,9 @@ static int otx2vf_register_mbox_intr(struct otx2_nic *vf, bool probe_pf)
err = otx2_sync_mbox_msg(&vf->mbox);
if (err) {
- dev_warn(vf->dev,
- "AF not responding to mailbox, deferring probe\n");
otx2vf_disable_mbox_intr(vf);
- return -EPROBE_DEFER;
+ return dev_err_probe(vf->dev, -EPROBE_DEFER,
+ "AF not responding to mailbox, deferring probe\n");
}
return 0;
}
---
base-commit: 25c1f6111034aef7fc06cfbdcf1e4f0d6e5ee74b
change-id: 20260831-octeontx2-dev-err-probe-9ff7be8b5e6c
Best regards,
--
Juuso Rinta [off-list ref]