<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 11pt; color: rgb(0, 0, 0);" class="elementToProof">
OK.</div>
<div style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 11pt; color: rgb(0, 0, 0);" class="elementToProof">
I wished there was a DPDK function to verify if transceiver is plugged in or not, without log errors. Such as rte_eth_dev_is_module_exist()</div>
<div style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 11pt; color: rgb(0, 0, 0);" class="elementToProof">
So, 1'st I would have checked if it's plugged in. Then I would have used rte_eth_dev_get_module_info().</div>
<div style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 11pt; color: rgb(0, 0, 0);" class="elementToProof">
<br>
</div>
<div style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 11pt; color: rgb(0, 0, 0);" class="elementToProof">
The workaround is setting the module's log level so the error won't be seen before calling rte_eth_dev_get_module_info(), and set it back to default afterwards.</div>
<div style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 11pt; color: rgb(0, 0, 0);" class="elementToProof">
<br>
</div>
<div style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 11pt; color: rgb(0, 0, 0);" class="elementToProof">
Thanks,</div>
<div style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 11pt; color: rgb(0, 0, 0);" class="elementToProof">
Yogev</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Dariusz Sosnowski <dsosnowski@nvidia.com><br>
<b>Sent:</b> Thursday, June 26, 2025 14:36<br>
<b>To:</b> Yogev Chaimovich <yogev@cgstowernetworks.com><br>
<b>Cc:</b> Maayan Kashani <mkashani@nvidia.com>; Stephen Hemminger <stephen@networkplumber.org>; Slava Ovsiienko <viacheslavo@nvidia.com>; Bing Zhao <bingz@nvidia.com>; Ori Kam <orika@nvidia.com>; Suanming Mou <suanmingm@nvidia.com>; Matan Azrad <matan@nvidia.com>;
dev@dpdk.org <dev@dpdk.org><br>
<b>Subject:</b> Re: [PATCH] net/mlx5: fix transceiver warning when not exist</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">Hi Yogev,<br>
<br>
On Mon, Jun 09, 2025 at 01:11:27PM +0000, Yogev Chaimovich wrote:<br>
> Hi,<br>
> Actually looks like we're going with another workaround, so I might not be needing my original patch.<br>
<br>
Could you tell us what kind of workaround you applied?<br>
<br>
Also, I'm not sure if this warning should be suppressed on EIO.<br>
mlx5 PMD relies on the kernel driver to get the module info,<br>
and from what I've seen for ETHTOOL_GMODULEINFO kernel can return EIO<br>
also for cases other than transceiver not existing<br>
(for example error on NIC register access).<br>
So mlx5 PMD cannot discern between "no transceiver" and<br>
"other I/O error".<br>
For this reason I would keep the log and keep it at warn level.<br>
<br>
> Also, I do not understand how my patch (not printing a log) makes a test fail - I couldn't find that test in DPDK to verify. I'm not that familiar though..<br>
> <br>
> Yogev<br>
<br>
*snip*<br>
<br>
Best regards,<br>
Dariusz Sosnowski<br>
</div>
</span></font></div>
</body>
</html>