From: Maxime Coquelin <maxime.coquelin@redhat.com>
To: Wenwu Ma <wenwux.ma@intel.com>, dev@dpdk.org
Cc: chenbo.xia@intel.com, weix.ling@intel.com, stable@dpdk.org
Subject: Re: [PATCH] net/virtio: fix the setting of the vector for link state interrupt
Date: Fri, 20 Oct 2023 11:01:11 +0200 [thread overview]
Message-ID: <0c47913a-492b-4d8b-8c0f-26b05af0abf7@redhat.com> (raw)
In-Reply-To: <20230807031516.1332914-1-wenwux.ma@intel.com>
Hi Wenwu,
Please reword the commit title to something:
net/virtio: fix link state interrupt vector setting
On 8/7/23 05:15, Wenwu Ma wrote:
> The settings of the vector for link state interrupts
> should be done before the initialization of the device
> is completed.
>
> Fixes: ee85024cf5f7 ("net/virtio: complete init stage at the right place")
> Cc: stable@dpdk.org
>
> Signed-off-by: Wenwu Ma <wenwux.ma@intel.com>
> ---
> drivers/net/virtio/virtio_ethdev.c | 16 ++++++++--------
> 1 file changed, 8 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c
> index 2c23f1c00e..1801b0ae47 100644
> --- a/drivers/net/virtio/virtio_ethdev.c
> +++ b/drivers/net/virtio/virtio_ethdev.c
> @@ -1912,6 +1912,14 @@ virtio_init_device(struct rte_eth_dev *eth_dev, uint64_t req_features)
> }
> }
>
> + if (eth_dev->data->dev_flags & RTE_ETH_DEV_INTR_LSC)
> + /* Enable vector (0) for Link State Interrupt */
> + if (VIRTIO_OPS(hw)->set_config_irq(hw, 0) ==
> + VIRTIO_MSI_NO_VECTOR) {
> + PMD_DRV_LOG(ERR, "failed to set config vector");
> + return -EBUSY;
> + }
> +
> virtio_reinit_complete(hw);
>
> return 0;
> @@ -2237,14 +2245,6 @@ virtio_dev_configure(struct rte_eth_dev *dev)
> hw->has_tx_offload = tx_offload_enabled(hw);
> hw->has_rx_offload = rx_offload_enabled(hw);
>
> - if (dev->data->dev_flags & RTE_ETH_DEV_INTR_LSC)
> - /* Enable vector (0) for Link State Interrupt */
> - if (VIRTIO_OPS(hw)->set_config_irq(hw, 0) ==
> - VIRTIO_MSI_NO_VECTOR) {
> - PMD_DRV_LOG(ERR, "failed to set config vector");
> - return -EBUSY;
> - }
> -
> if (virtio_with_packed_queue(hw)) {
> #if defined(RTE_ARCH_X86_64) && defined(CC_AVX512_SUPPORT)
> if ((hw->use_vec_rx || hw->use_vec_tx) &&
It looks good to me, so I can change the title myself while applying if
Ok for you.
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
By the way, can you tell me with which backends have you tested it with?
Only Virtio-PCI? Or also Virtio-user?
Thanks,
Maxime
next prev parent reply other threads:[~2023-10-20 9:01 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-07 3:15 Wenwu Ma
2023-08-17 2:36 ` Ling, WeiX
2023-10-20 9:01 ` Maxime Coquelin [this message]
2023-10-23 1:26 ` Ma, WenwuX
2023-10-23 1:46 ` [PATCH v2] net/virtio: fix link state interrupt vector setting Wenwu Ma
2023-10-25 12:23 ` Maxime Coquelin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=0c47913a-492b-4d8b-8c0f-26b05af0abf7@redhat.com \
--to=maxime.coquelin@redhat.com \
--cc=chenbo.xia@intel.com \
--cc=dev@dpdk.org \
--cc=stable@dpdk.org \
--cc=weix.ling@intel.com \
--cc=wenwux.ma@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).