.\" From: @(#)ifconfig.8 8.3 (Berkeley) 1/5/94
.\" $FreeBSD: src/sbin/ifconfig/ifconfig.8,v 1.124 2006/10/10 09:44:08 ru Exp $
.\"
-.Dd July 17, 2010
+.Dd Nov 12, 2012
.Dt IFCONFIG 8
.Os
.Sh NAME
reception of extended frames or tag processing in hardware,
respectively.
.It Cm pollcpu Ar cpu
-Turn on
-.Xr polling 4
-feature and disable interrupts on the interface,
-if the driver supports this mode and
-.Ar cpu
-supports
-.Xr polling 4 .
-Driver will be polled by
-.Ar cpu .
-.It Cm polling
+Deprecated, use polling or npolling instead.
+.It Cm polling , npolling
Turn on
.Xr polling 4
feature and disable interrupts on the interface, if the driver supports
this mode.
-.It Fl polling
+.It Fl polling , npolling
Turn off
.Xr polling 4
feature and enable interrupt mode on the interface.
setifpollcpu(const char *val, int dummy __unused, int s,
const struct afswtch *afp)
{
- int pollcpu;
-
- pollcpu = atoi(val);
- if (pollcpu < 0) {
- warn("pollcpu < 0");
- return;
- }
-
- setifflags("-polling", -IFF_POLLING, s, afp);
-
- ifr.ifr_pollcpu = pollcpu;
- if (ioctl(s, SIOCSIFPOLLCPU, (caddr_t)&ifr) < 0) {
- warn("ioctl (set pollcpu)");
- return;
- }
+ warnx("pollcpu is deprecated, use polling or npolling instead");
+ setifflags("npolling", IFF_NPOLLING, s, afp);
}
/*
if (ioctl(s, SIOCGIFSTATUS, &ifs) == 0)
printf("%s", ifs.ascii);
- if (flags & IFF_POLLING) {
- if (ioctl(s, SIOCGIFPOLLCPU, &ifr) == 0 && ifr.ifr_pollcpu >= 0)
- printf("\tpollcpu: %d\n", ifr.ifr_pollcpu);
- }
-
close(s);
return;
}
DEF_CMD("-monitor", -IFF_MONITOR, setifflags),
DEF_CMD("staticarp", IFF_STATICARP, setifflags),
DEF_CMD("-staticarp", -IFF_STATICARP, setifflags),
- DEF_CMD("polling", IFF_POLLING, setifflags),
- DEF_CMD("-polling", -IFF_POLLING, setifflags),
+ DEF_CMD("polling", IFF_NPOLLING, setifflags),
+ DEF_CMD("-polling", -IFF_NPOLLING, setifflags),
DEF_CMD("npolling", IFF_NPOLLING, setifflags),
DEF_CMD("-npolling", -IFF_NPOLLING, setifflags),
DEF_CMD("rxcsum", IFCAP_RXCSUM, setifcap),