From: Brad Smith <brad@comstyle.com>
To: qemu-devel@nongnu.org
Cc: Jason Wang <jasowang@redhat.com>
Subject: [PATCH] tap-bsd: Remove special casing for older OpenBSD releases
Date: Fri, 26 Mar 2021 19:49:12 -0400 [thread overview]
Message-ID: <YF5y+MDiK2QInFA2@humpty.home.comstyle.com> (raw)
OpenBSD added support for tap(4) 10 releases ago.
Remove the special casing for older releases.
Signed-off-by: Brad Smith <brad@comstyle.com>
diff --git a/net/tap-bsd.c b/net/tap-bsd.c
index 77aaf674b1..59dfcdfae0 100644
--- a/net/tap-bsd.c
+++ b/net/tap-bsd.c
@@ -35,10 +35,6 @@
#include <net/if_tap.h>
#endif
-#if defined(__OpenBSD__)
-#include <sys/param.h>
-#endif
-
#ifndef __FreeBSD__
int tap_open(char *ifname, int ifname_size, int *vnet_hdr,
int vnet_hdr_required, int mq_required, Error **errp)
@@ -59,11 +55,7 @@ int tap_open(char *ifname, int ifname_size, int *vnet_hdr,
if (*ifname) {
snprintf(dname, sizeof dname, "/dev/%s", ifname);
} else {
-#if defined(__OpenBSD__) && OpenBSD < 201605
- snprintf(dname, sizeof dname, "/dev/tun%d", i);
-#else
snprintf(dname, sizeof dname, "/dev/tap%d", i);
-#endif
}
TFR(fd = open(dname, O_RDWR));
if (fd >= 0) {
next reply other threads:[~2021-03-26 23:50 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-26 23:49 Brad Smith [this message]
2021-03-29 2:22 ` [PATCH] tap-bsd: Remove special casing for older OpenBSD releases Jason Wang
2021-03-29 3:03 ` Brad Smith
2021-03-29 3:58 ` Jason Wang
2021-03-29 20:38 ` Brad Smith
2021-04-01 7:24 ` Jason Wang
2021-05-02 4:10 ` Brad Smith
2021-05-06 2:19 ` Jason Wang
2021-05-06 3:16 ` Brad Smith
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=YF5y+MDiK2QInFA2@humpty.home.comstyle.com \
--to=brad@comstyle.com \
--cc=jasowang@redhat.com \
--cc=qemu-devel@nongnu.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.