diff options
author | Andrea Parri (Microsoft) <parri.andrea@gmail.com> | 2022-04-07 06:40:34 +0200 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2022-04-08 06:04:11 +0200 |
commit | 26894cd971168d14fd8f4c05435aef59188c9514 (patch) | |
tree | 4b7a1ca7474f92d5745f89376b5b1c98da10de5e /drivers/net/hyperv | |
parent | qed: remove an unneed NULL check on list iterator (diff) | |
download | linux-26894cd971168d14fd8f4c05435aef59188c9514.tar.xz linux-26894cd971168d14fd8f4c05435aef59188c9514.zip |
hv_netvsc: Print value of invalid ID in netvsc_send_{completion,tx_complete}()
That being useful for debugging purposes.
Notice that the packet descriptor is in "private" guest memory, so
that Hyper-V can not tamper with it.
While at it, remove two unnecessary u64-casts.
Signed-off-by: Andrea Parri (Microsoft) <parri.andrea@gmail.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/hyperv')
-rw-r--r-- | drivers/net/hyperv/netvsc.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c index 9442f751ad3a..4061af5baaea 100644 --- a/drivers/net/hyperv/netvsc.c +++ b/drivers/net/hyperv/netvsc.c @@ -792,9 +792,9 @@ static void netvsc_send_tx_complete(struct net_device *ndev, int queue_sends; u64 cmd_rqst; - cmd_rqst = channel->request_addr_callback(channel, (u64)desc->trans_id); + cmd_rqst = channel->request_addr_callback(channel, desc->trans_id); if (cmd_rqst == VMBUS_RQST_ERROR) { - netdev_err(ndev, "Incorrect transaction id\n"); + netdev_err(ndev, "Invalid transaction ID %llx\n", desc->trans_id); return; } @@ -854,9 +854,9 @@ static void netvsc_send_completion(struct net_device *ndev, /* First check if this is a VMBUS completion without data payload */ if (!msglen) { cmd_rqst = incoming_channel->request_addr_callback(incoming_channel, - (u64)desc->trans_id); + desc->trans_id); if (cmd_rqst == VMBUS_RQST_ERROR) { - netdev_err(ndev, "Invalid transaction id\n"); + netdev_err(ndev, "Invalid transaction ID %llx\n", desc->trans_id); return; } |