* [PATCH net-next v4] net: mana: Add MAC address to vPort logs and clarify error messages
@ 2026-02-25 19:22 Erni Sri Satya Vennela
2026-02-27 19:06 ` Erni Sri Satya Vennela
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Erni Sri Satya Vennela @ 2026-02-25 19:22 UTC (permalink / raw)
To: kys, haiyangz, wei.liu, decui, longli, andrew+netdev, davem,
edumazet, kuba, pabeni, dipayanroy, ernis, shirazsaleem, ssengar,
shradhagupta, gargaditya, linux-hyperv, netdev, linux-kernel
Add MAC address to vPort configuration success message and update error
message to be more specific about HWC message errors in
mana_send_request.
Signed-off-by: Erni Sri Satya Vennela <ernis@linux.microsoft.com>
---
Changes in v4:
* Remove logs that do not add value in hw_channel.c.
Changes in v3:
* Remove the changes from v2 and Update commit message.
* Use "Enabled vPort ..." instead of "Configured vPort" in
mana_cfg_vport.
* Update error logs in mana_hwc_send_request.
Changes in v2:
* Update commit message.
* Use "Enabled vPort ..." instead of "Configured vPort" in
mana_cfg_vport.
* Add info log in mana_uncfg_vport, mana_gd_verify_vf_version,
mana_gd_query_max_resources, mana_query_device_cfg and
mana_query_vport_cfg.
---
drivers/net/ethernet/microsoft/mana/hw_channel.c | 12 +++++++-----
drivers/net/ethernet/microsoft/mana/mana_en.c | 8 ++++----
2 files changed, 11 insertions(+), 9 deletions(-)
diff --git a/drivers/net/ethernet/microsoft/mana/hw_channel.c b/drivers/net/ethernet/microsoft/mana/hw_channel.c
index aa4e2731e2ba..e89b7ed8dd69 100644
--- a/drivers/net/ethernet/microsoft/mana/hw_channel.c
+++ b/drivers/net/ethernet/microsoft/mana/hw_channel.c
@@ -853,6 +853,7 @@ int mana_hwc_send_request(struct hw_channel_context *hwc, u32 req_len,
struct hwc_caller_ctx *ctx;
u32 dest_vrcq = 0;
u32 dest_vrq = 0;
+ u32 command;
u16 msg_id;
int err;
@@ -878,6 +879,7 @@ int mana_hwc_send_request(struct hw_channel_context *hwc, u32 req_len,
req_msg->req.hwc_msg_id = msg_id;
tx_wr->msg_size = req_len;
+ command = req_msg->req.msg_type;
if (gc->is_pf) {
dest_vrq = hwc->pf_dest_vrq_id;
@@ -893,8 +895,8 @@ int mana_hwc_send_request(struct hw_channel_context *hwc, u32 req_len,
if (!wait_for_completion_timeout(&ctx->comp_event,
(msecs_to_jiffies(hwc->hwc_timeout)))) {
if (hwc->hwc_timeout != 0)
- dev_err(hwc->dev, "HWC: Request timed out: %u ms\n",
- hwc->hwc_timeout);
+ dev_err(hwc->dev, "%s:%d: Command 0x%x timed out: %u ms\n",
+ __func__, __LINE__, command, hwc->hwc_timeout);
/* Reduce further waiting if HWC no response */
if (hwc->hwc_timeout > 1)
@@ -914,9 +916,9 @@ int mana_hwc_send_request(struct hw_channel_context *hwc, u32 req_len,
err = -EOPNOTSUPP;
goto out;
}
- if (req_msg->req.msg_type != MANA_QUERY_PHY_STAT)
- dev_err(hwc->dev, "HWC: Failed hw_channel req: 0x%x\n",
- ctx->status_code);
+ if (command != MANA_QUERY_PHY_STAT)
+ dev_err(hwc->dev, "%s:%d: Command 0x%x failed with status: 0x%x\n",
+ __func__, __LINE__, command, ctx->status_code);
err = -EPROTO;
goto out;
}
diff --git a/drivers/net/ethernet/microsoft/mana/mana_en.c b/drivers/net/ethernet/microsoft/mana/mana_en.c
index 9b5a72ada5c4..53f24244de75 100644
--- a/drivers/net/ethernet/microsoft/mana/mana_en.c
+++ b/drivers/net/ethernet/microsoft/mana/mana_en.c
@@ -1023,8 +1023,8 @@ static int mana_send_request(struct mana_context *ac, void *in_buf,
if (req->req.msg_type != MANA_QUERY_PHY_STAT &&
mana_need_log(gc, err))
- dev_err(dev, "Failed to send mana message: %d, 0x%x\n",
- err, resp->status);
+ dev_err(dev, "Command 0x%x failed with status: 0x%x, err: %d\n",
+ req->req.msg_type, resp->status, err);
return err ? err : -EPROTO;
}
@@ -1337,8 +1337,8 @@ int mana_cfg_vport(struct mana_port_context *apc, u32 protection_dom_id,
apc->tx_shortform_allowed = resp.short_form_allowed;
apc->tx_vp_offset = resp.tx_vport_offset;
- netdev_info(apc->ndev, "Configured vPort %llu PD %u DB %u\n",
- apc->port_handle, protection_dom_id, doorbell_pg_id);
+ netdev_info(apc->ndev, "Enabled vPort %llu PD %u DB %u MAC %pM\n",
+ apc->port_handle, protection_dom_id, doorbell_pg_id, apc->mac_addr);
out:
if (err)
mana_uncfg_vport(apc);
--
2.34.1
^ permalink raw reply related [flat|nested] 7+ messages in thread* Re: [PATCH net-next v4] net: mana: Add MAC address to vPort logs and clarify error messages
2026-02-25 19:22 [PATCH net-next v4] net: mana: Add MAC address to vPort logs and clarify error messages Erni Sri Satya Vennela
@ 2026-02-27 19:06 ` Erni Sri Satya Vennela
2026-02-28 0:52 ` Jakub Kicinski
2026-02-28 17:55 ` Jakub Kicinski
2026-03-01 16:41 ` Simon Horman
2 siblings, 1 reply; 7+ messages in thread
From: Erni Sri Satya Vennela @ 2026-02-27 19:06 UTC (permalink / raw)
To: kys, haiyangz, wei.liu, decui, longli, andrew+netdev, davem,
edumazet, kuba, pabeni, dipayanroy, shirazsaleem, ssengar,
shradhagupta, gargaditya, linux-hyperv, netdev, linux-kernel
On Wed, Feb 25, 2026 at 11:22:41AM -0800, Erni Sri Satya Vennela wrote:
> Add MAC address to vPort configuration success message and update error
> message to be more specific about HWC message errors in
> mana_send_request.
>
> Signed-off-by: Erni Sri Satya Vennela <ernis@linux.microsoft.com>
Gentle ping — I sent this patch on 25/02/2026 and would appreciate any
feedback when you have time.
Happy to rebase or add more details if needed, thanks for your review.
Regards,
Vennela
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH net-next v4] net: mana: Add MAC address to vPort logs and clarify error messages
2026-02-27 19:06 ` Erni Sri Satya Vennela
@ 2026-02-28 0:52 ` Jakub Kicinski
2026-02-28 7:26 ` Erni Sri Satya Vennela
0 siblings, 1 reply; 7+ messages in thread
From: Jakub Kicinski @ 2026-02-28 0:52 UTC (permalink / raw)
To: Erni Sri Satya Vennela
Cc: kys, haiyangz, wei.liu, decui, longli, andrew+netdev, davem,
edumazet, pabeni, dipayanroy, shirazsaleem, ssengar, shradhagupta,
gargaditya, linux-hyperv, netdev, linux-kernel
On Fri, 27 Feb 2026 11:06:31 -0800 Erni Sri Satya Vennela wrote:
> On Wed, Feb 25, 2026 at 11:22:41AM -0800, Erni Sri Satya Vennela wrote:
> > Add MAC address to vPort configuration success message and update error
> > message to be more specific about HWC message errors in
> > mana_send_request.
> >
> > Signed-off-by: Erni Sri Satya Vennela <ernis@linux.microsoft.com>
>
> Gentle ping — I sent this patch on 25/02/2026 and would appreciate any
> feedback when you have time.
> Happy to rebase or add more details if needed, thanks for your review.
What are you trying to achieve with this ping? Just look at patchwork,
there are 61 patches ahead of you in the queue.
These are Microsoft review contribution scores:
Author score negative (-42)
Company score negative (-1118)
so you expecting that someone in the community will jump onto reviewing
your patches is... odd. How about you review something?
Read the process documentation, and please have some basic
understanding of what is consider good manners when communicating
upstream.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH net-next v4] net: mana: Add MAC address to vPort logs and clarify error messages
2026-02-28 0:52 ` Jakub Kicinski
@ 2026-02-28 7:26 ` Erni Sri Satya Vennela
0 siblings, 0 replies; 7+ messages in thread
From: Erni Sri Satya Vennela @ 2026-02-28 7:26 UTC (permalink / raw)
To: Jakub Kicinski
Cc: kys, haiyangz, wei.liu, decui, longli, andrew+netdev, davem,
edumazet, pabeni, dipayanroy, shirazsaleem, ssengar, shradhagupta,
gargaditya, linux-hyperv, netdev, linux-kernel
On Fri, Feb 27, 2026 at 04:52:26PM -0800, Jakub Kicinski wrote:
> On Fri, 27 Feb 2026 11:06:31 -0800 Erni Sri Satya Vennela wrote:
> > On Wed, Feb 25, 2026 at 11:22:41AM -0800, Erni Sri Satya Vennela wrote:
> > > Add MAC address to vPort configuration success message and update error
> > > message to be more specific about HWC message errors in
> > > mana_send_request.
> > >
> > > Signed-off-by: Erni Sri Satya Vennela <ernis@linux.microsoft.com>
> >
> > Gentle ping — I sent this patch on 25/02/2026 and would appreciate any
> > feedback when you have time.
> > Happy to rebase or add more details if needed, thanks for your review.
>
> What are you trying to achieve with this ping? Just look at patchwork,
> there are 61 patches ahead of you in the queue.
>
> These are Microsoft review contribution scores:
> Author score negative (-42)
> Company score negative (-1118)
> so you expecting that someone in the community will jump onto reviewing
> your patches is... odd. How about you review something?
>
> Read the process documentation, and please have some basic
> understanding of what is consider good manners when communicating
> upstream.
I'm sorry for causing the trouble, and I appreciate you pointing this out.
I’ll be more patient with the review process and wait my turn in the
queue.
- Vennela
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH net-next v4] net: mana: Add MAC address to vPort logs and clarify error messages
2026-02-25 19:22 [PATCH net-next v4] net: mana: Add MAC address to vPort logs and clarify error messages Erni Sri Satya Vennela
2026-02-27 19:06 ` Erni Sri Satya Vennela
@ 2026-02-28 17:55 ` Jakub Kicinski
2026-03-01 16:41 ` Simon Horman
2 siblings, 0 replies; 7+ messages in thread
From: Jakub Kicinski @ 2026-02-28 17:55 UTC (permalink / raw)
To: Erni Sri Satya Vennela
Cc: kys, haiyangz, wei.liu, decui, longli, andrew+netdev, davem,
edumazet, pabeni, dipayanroy, shirazsaleem, ssengar, shradhagupta,
gargaditya, linux-hyperv, netdev, linux-kernel
On Wed, 25 Feb 2026 11:22:41 -0800 Erni Sri Satya Vennela wrote:
> - dev_err(hwc->dev, "HWC: Request timed out: %u ms\n",
> - hwc->hwc_timeout);
> + dev_err(hwc->dev, "%s:%d: Command 0x%x timed out: %u ms\n",
> + __func__, __LINE__, command, hwc->hwc_timeout);
Please don't include __LINE__, they are meaningless given the amount of
backporting that usually happens in the kernel. The string should be
unique enough to identify the error, which I think yours is given the
__func__ + text you have.
--
pw-bot: cr
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH net-next v4] net: mana: Add MAC address to vPort logs and clarify error messages
2026-02-25 19:22 [PATCH net-next v4] net: mana: Add MAC address to vPort logs and clarify error messages Erni Sri Satya Vennela
2026-02-27 19:06 ` Erni Sri Satya Vennela
2026-02-28 17:55 ` Jakub Kicinski
@ 2026-03-01 16:41 ` Simon Horman
2026-03-02 17:27 ` Erni Sri Satya Vennela
2 siblings, 1 reply; 7+ messages in thread
From: Simon Horman @ 2026-03-01 16:41 UTC (permalink / raw)
To: Erni Sri Satya Vennela
Cc: kys, haiyangz, wei.liu, decui, longli, andrew+netdev, davem,
edumazet, kuba, pabeni, dipayanroy, shirazsaleem, ssengar,
shradhagupta, gargaditya, linux-hyperv, netdev, linux-kernel
On Wed, Feb 25, 2026 at 11:22:41AM -0800, Erni Sri Satya Vennela wrote:
> Add MAC address to vPort configuration success message and update error
> message to be more specific about HWC message errors in
> mana_send_request.
>
> Signed-off-by: Erni Sri Satya Vennela <ernis@linux.microsoft.com>
...
> diff --git a/drivers/net/ethernet/microsoft/mana/hw_channel.c b/drivers/net/ethernet/microsoft/mana/hw_channel.c
...
> @@ -893,8 +895,8 @@ int mana_hwc_send_request(struct hw_channel_context *hwc, u32 req_len,
> if (!wait_for_completion_timeout(&ctx->comp_event,
> (msecs_to_jiffies(hwc->hwc_timeout)))) {
> if (hwc->hwc_timeout != 0)
> - dev_err(hwc->dev, "HWC: Request timed out: %u ms\n",
> - hwc->hwc_timeout);
> + dev_err(hwc->dev, "%s:%d: Command 0x%x timed out: %u ms\n",
> + __func__, __LINE__, command, hwc->hwc_timeout);
I have reservations about the usefulness of including __func__ and __LINE__
in debug messages. In a nutshell, it requires the logs to be correlated
(exactly?) with the source used to build the driver. And at that point
I think other mechanism - e.g. dynamic trace points - are going to be
useful if the debug message (without function and line information)
is insufficient to pinpoint the problem.
This is a general statement, rather than something specifically
about this code. But nonetheless I'd advise against adding this
information here.
>
> /* Reduce further waiting if HWC no response */
> if (hwc->hwc_timeout > 1)
> @@ -914,9 +916,9 @@ int mana_hwc_send_request(struct hw_channel_context *hwc, u32 req_len,
> err = -EOPNOTSUPP;
> goto out;
> }
> - if (req_msg->req.msg_type != MANA_QUERY_PHY_STAT)
> - dev_err(hwc->dev, "HWC: Failed hw_channel req: 0x%x\n",
> - ctx->status_code);
> + if (command != MANA_QUERY_PHY_STAT)
> + dev_err(hwc->dev, "%s:%d: Command 0x%x failed with status: 0x%x\n",
> + __func__, __LINE__, command, ctx->status_code);
> err = -EPROTO;
> goto out;
> }
...
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [PATCH net-next v4] net: mana: Add MAC address to vPort logs and clarify error messages
2026-03-01 16:41 ` Simon Horman
@ 2026-03-02 17:27 ` Erni Sri Satya Vennela
0 siblings, 0 replies; 7+ messages in thread
From: Erni Sri Satya Vennela @ 2026-03-02 17:27 UTC (permalink / raw)
To: Simon Horman
Cc: kys, haiyangz, wei.liu, decui, longli, andrew+netdev, davem,
edumazet, kuba, pabeni, dipayanroy, shirazsaleem, ssengar,
shradhagupta, gargaditya, linux-hyperv, netdev, linux-kernel
> I have reservations about the usefulness of including __func__ and __LINE__
> in debug messages. In a nutshell, it requires the logs to be correlated
> (exactly?) with the source used to build the driver. And at that point
> I think other mechanism - e.g. dynamic trace points - are going to be
> useful if the debug message (without function and line information)
> is insufficient to pinpoint the problem.
>
> This is a general statement, rather than something specifically
> about this code. But nonetheless I'd advise against adding this
> information here.
>
Thankyou Jakub and Simon for the suggestions.
I'll remove both in the next version.
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2026-03-02 17:27 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-02-25 19:22 [PATCH net-next v4] net: mana: Add MAC address to vPort logs and clarify error messages Erni Sri Satya Vennela
2026-02-27 19:06 ` Erni Sri Satya Vennela
2026-02-28 0:52 ` Jakub Kicinski
2026-02-28 7:26 ` Erni Sri Satya Vennela
2026-02-28 17:55 ` Jakub Kicinski
2026-03-01 16:41 ` Simon Horman
2026-03-02 17:27 ` Erni Sri Satya Vennela
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox