From: "Eugenio Pérez" <eperezma@redhat.com>
To: mst@redhat.com
Cc: "Laurent Vivier" <lvivier@redhat.com>,
"Stefano Garzarella" <sgarzare@redhat.com>,
"Dragos Tatulea DE" <dtatulea@nvidia.com>,
"Cindy Lu" <lulu@redhat.com>,
"Maxime Coquelin" <mcoqueli@redhat.com>,
"Eugenio Pérez" <eperezma@redhat.com>,
"Yongji Xie" <xieyongji@bytedance.com>,
jasowang@redhat.com, "Xuan Zhuo" <xuanzhuo@linux.alibaba.com>,
linux-kernel@vger.kernel.org,
"Jonah Palmer" <jonah.palmer@oracle.com>,
"Si-Wei Liu" <si-wei.liu@oracle.com>,
virtualization@lists.linux.dev,
"Beñat Gartzia Arruabarrena" <bgartzia@redhat.com>
Subject: [RFC 2/2] vduse: allow to specify device-specific features if it's multiclass
Date: Thu, 2 Oct 2025 12:35:37 +0200 [thread overview]
Message-ID: <20251002103537.308717-3-eperezma@redhat.com> (raw)
In-Reply-To: <20251002103537.308717-1-eperezma@redhat.com>
Even if the device supports more than one class, there are ways to solve
the ambiguity of which device are we creating. In the VDUSE case it is
the name, for example.
RFC: I fon't understand 100% the motivation of this limitation, as the
backend should be the one filtering out the invalid features if any.
Signed-off-by: Eugenio Pérez <eperezma@redhat.com>
---
drivers/vdpa/vdpa.c | 9 ---------
1 file changed, 9 deletions(-)
diff --git a/drivers/vdpa/vdpa.c b/drivers/vdpa/vdpa.c
index 34874beb0152..0fc32f3bd66f 100644
--- a/drivers/vdpa/vdpa.c
+++ b/drivers/vdpa/vdpa.c
@@ -688,15 +688,6 @@ static int vdpa_nl_cmd_dev_add_set_doit(struct sk_buff *skb, struct genl_info *i
err = -EINVAL;
goto err;
}
- if (!(config.mask & VDPA_DEV_NET_ATTRS_MASK) &&
- config.mask & BIT_ULL(VDPA_ATTR_DEV_FEATURES) &&
- classes & BIT_ULL(VIRTIO_ID_NET) && ncls > 1 &&
- config.device_features & VIRTIO_DEVICE_F_MASK) {
- NL_SET_ERR_MSG_MOD(info->extack,
- "Management device supports multi-class while device features specified are ambiguous");
- err = -EINVAL;
- goto err;
- }
err = mdev->ops->dev_add(mdev, name, &config);
err:
--
2.51.0
next prev parent reply other threads:[~2025-10-02 10:36 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-02 10:35 [RFC 0/2] support vduse feature provisioning in vdpa netlink command Eugenio Pérez
2025-10-02 10:35 ` [RFC 1/2] vduse: support feature provisioning Eugenio Pérez
2025-10-10 4:38 ` Si-Wei Liu
2025-10-10 9:41 ` Eugenio Perez Martin
2025-10-02 10:35 ` Eugenio Pérez [this message]
2025-10-10 1:39 ` [RFC 2/2] vduse: allow to specify device-specific features if it's multiclass Jason Wang
2025-10-10 3:58 ` Jason Wang
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=20251002103537.308717-3-eperezma@redhat.com \
--to=eperezma@redhat.com \
--cc=bgartzia@redhat.com \
--cc=dtatulea@nvidia.com \
--cc=jasowang@redhat.com \
--cc=jonah.palmer@oracle.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lulu@redhat.com \
--cc=lvivier@redhat.com \
--cc=mcoqueli@redhat.com \
--cc=mst@redhat.com \
--cc=sgarzare@redhat.com \
--cc=si-wei.liu@oracle.com \
--cc=virtualization@lists.linux.dev \
--cc=xieyongji@bytedance.com \
--cc=xuanzhuo@linux.alibaba.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).