* [PATCH] iptuntap: allow creation of multi-queue tun/tap device
@ 2013-05-23 22:36 Sriram Narasimhan
2013-06-09 11:11 ` Michael S. Tsirkin
0 siblings, 1 reply; 3+ messages in thread
From: Sriram Narasimhan @ 2013-05-23 22:36 UTC (permalink / raw)
To: netdev; +Cc: Sriram Narasimhan
This patch adds multi_queue option to ip tuntap.
This allows IFF_MULTI_QUEUE flag to be specified during
tun/tap device creation enabling multi-queue support in tun/tap
device.
Example: ip tuntap add dev tap0 mode tap multi_queue
Signed-off-by: Sriram Narasimhan <sriram.narasimhan@hp.com>
---
ip/iptuntap.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/ip/iptuntap.c b/ip/iptuntap.c
index 3d9ad7d..2391af2 100644
--- a/ip/iptuntap.c
+++ b/ip/iptuntap.c
@@ -38,7 +38,7 @@ static void usage(void)
{
fprintf(stderr, "Usage: ip tuntap { add | del } [ dev PHYS_DEV ] \n");
fprintf(stderr, " [ mode { tun | tap } ] [ user USER ] [ group GROUP ]\n");
- fprintf(stderr, " [ one_queue ] [ pi ] [ vnet_hdr ]\n");
+ fprintf(stderr, " [ one_queue ] [ pi ] [ vnet_hdr ] [ multi_queue ]\n");
fprintf(stderr, "\n");
fprintf(stderr, "Where: USER := { STRING | NUMBER }\n");
fprintf(stderr, " GROUP := { STRING | NUMBER }\n");
@@ -168,6 +168,8 @@ static int parse_args(int argc, char **argv, struct ifreq *ifr, uid_t *uid, gid_
ifr->ifr_flags |= IFF_ONE_QUEUE;
} else if (matches(*argv, "vnet_hdr") == 0) {
ifr->ifr_flags |= IFF_VNET_HDR;
+ } else if (matches(*argv, "multi_queue") == 0) {
+ ifr->ifr_flags |= IFF_MULTI_QUEUE;
} else if (matches(*argv, "dev") == 0) {
NEXT_ARG();
strncpy(ifr->ifr_name, *argv, IFNAMSIZ-1);
--
1.7.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] iptuntap: allow creation of multi-queue tun/tap device
2013-05-23 22:36 [PATCH] iptuntap: allow creation of multi-queue tun/tap device Sriram Narasimhan
@ 2013-06-09 11:11 ` Michael S. Tsirkin
2013-06-10 17:16 ` Stephen Hemminger
0 siblings, 1 reply; 3+ messages in thread
From: Michael S. Tsirkin @ 2013-06-09 11:11 UTC (permalink / raw)
To: Sriram Narasimhan; +Cc: netdev, stephen
On Thu, May 23, 2013 at 03:36:29PM -0700, Sriram Narasimhan wrote:
> This patch adds multi_queue option to ip tuntap.
> This allows IFF_MULTI_QUEUE flag to be specified during
> tun/tap device creation enabling multi-queue support in tun/tap
> device.
>
> Example: ip tuntap add dev tap0 mode tap multi_queue
>
> Signed-off-by: Sriram Narasimhan <sriram.narasimhan@hp.com>
Looks useful.
Stephen, what do you think?
Could you pick this up please?
> ---
> ip/iptuntap.c | 4 +++-
> 1 files changed, 3 insertions(+), 1 deletions(-)
>
> diff --git a/ip/iptuntap.c b/ip/iptuntap.c
> index 3d9ad7d..2391af2 100644
> --- a/ip/iptuntap.c
> +++ b/ip/iptuntap.c
> @@ -38,7 +38,7 @@ static void usage(void)
> {
> fprintf(stderr, "Usage: ip tuntap { add | del } [ dev PHYS_DEV ] \n");
> fprintf(stderr, " [ mode { tun | tap } ] [ user USER ] [ group GROUP ]\n");
> - fprintf(stderr, " [ one_queue ] [ pi ] [ vnet_hdr ]\n");
> + fprintf(stderr, " [ one_queue ] [ pi ] [ vnet_hdr ] [ multi_queue ]\n");
> fprintf(stderr, "\n");
> fprintf(stderr, "Where: USER := { STRING | NUMBER }\n");
> fprintf(stderr, " GROUP := { STRING | NUMBER }\n");
> @@ -168,6 +168,8 @@ static int parse_args(int argc, char **argv, struct ifreq *ifr, uid_t *uid, gid_
> ifr->ifr_flags |= IFF_ONE_QUEUE;
> } else if (matches(*argv, "vnet_hdr") == 0) {
> ifr->ifr_flags |= IFF_VNET_HDR;
> + } else if (matches(*argv, "multi_queue") == 0) {
> + ifr->ifr_flags |= IFF_MULTI_QUEUE;
> } else if (matches(*argv, "dev") == 0) {
> NEXT_ARG();
> strncpy(ifr->ifr_name, *argv, IFNAMSIZ-1);
> --
> 1.7.1
>
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] iptuntap: allow creation of multi-queue tun/tap device
2013-06-09 11:11 ` Michael S. Tsirkin
@ 2013-06-10 17:16 ` Stephen Hemminger
0 siblings, 0 replies; 3+ messages in thread
From: Stephen Hemminger @ 2013-06-10 17:16 UTC (permalink / raw)
To: Michael S. Tsirkin; +Cc: Sriram Narasimhan, netdev
On Sun, 9 Jun 2013 14:11:23 +0300
"Michael S. Tsirkin" <mst@redhat.com> wrote:
> On Thu, May 23, 2013 at 03:36:29PM -0700, Sriram Narasimhan wrote:
> > This patch adds multi_queue option to ip tuntap.
> > This allows IFF_MULTI_QUEUE flag to be specified during
> > tun/tap device creation enabling multi-queue support in tun/tap
> > device.
> >
> > Example: ip tuntap add dev tap0 mode tap multi_queue
> >
> > Signed-off-by: Sriram Narasimhan <sriram.narasimhan@hp.com>
>
> Looks useful.
>
> Stephen, what do you think?
> Could you pick this up please?
>
> > ---
> > ip/iptuntap.c | 4 +++-
> > 1 files changed, 3 insertions(+), 1 deletions(-)
> >
> > diff --git a/ip/iptuntap.c b/ip/iptuntap.c
> > index 3d9ad7d..2391af2 100644
> > --- a/ip/iptuntap.c
> > +++ b/ip/iptuntap.c
> > @@ -38,7 +38,7 @@ static void usage(void)
> > {
> > fprintf(stderr, "Usage: ip tuntap { add | del } [ dev PHYS_DEV ] \n");
> > fprintf(stderr, " [ mode { tun | tap } ] [ user USER ] [ group GROUP ]\n");
> > - fprintf(stderr, " [ one_queue ] [ pi ] [ vnet_hdr ]\n");
> > + fprintf(stderr, " [ one_queue ] [ pi ] [ vnet_hdr ] [ multi_queue ]\n");
> > fprintf(stderr, "\n");
> > fprintf(stderr, "Where: USER := { STRING | NUMBER }\n");
> > fprintf(stderr, " GROUP := { STRING | NUMBER }\n");
> > @@ -168,6 +168,8 @@ static int parse_args(int argc, char **argv, struct ifreq *ifr, uid_t *uid, gid_
> > ifr->ifr_flags |= IFF_ONE_QUEUE;
> > } else if (matches(*argv, "vnet_hdr") == 0) {
> > ifr->ifr_flags |= IFF_VNET_HDR;
> > + } else if (matches(*argv, "multi_queue") == 0) {
> > + ifr->ifr_flags |= IFF_MULTI_QUEUE;
> > } else if (matches(*argv, "dev") == 0) {
> > NEXT_ARG();
> > strncpy(ifr->ifr_name, *argv, IFNAMSIZ-1);
> > --
> > 1.7.1
> >
> > --
> > To unsubscribe from this list: send the line "unsubscribe netdev" in
> > the body of a message to majordomo@vger.kernel.org
> > More majordomo info at http://vger.kernel.org/majordomo-info.html
Already applied to iproute2 for 3.10
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-06-10 17:16 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-05-23 22:36 [PATCH] iptuntap: allow creation of multi-queue tun/tap device Sriram Narasimhan
2013-06-09 11:11 ` Michael S. Tsirkin
2013-06-10 17:16 ` Stephen Hemminger
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).