aboutsummaryrefslogtreecommitdiff
path: root/sys/kern/kern_poll.c
diff options
context:
space:
mode:
authorMaxim Sobolev <sobomax@FreeBSD.org>2002-08-18 07:05:00 +0000
committerMaxim Sobolev <sobomax@FreeBSD.org>2002-08-18 07:05:00 +0000
commit62f76486821669cfb9ceafa372dcdc7eb15d4e3c (patch)
tree344b7a3da98a22c060f844fe311e36665045f41f /sys/kern/kern_poll.c
parent4f8fa749f0c3befcee389fbdea4cbcb7f149d9f6 (diff)
downloadsrc-62f76486821669cfb9ceafa372dcdc7eb15d4e3c.tar.gz
src-62f76486821669cfb9ceafa372dcdc7eb15d4e3c.zip
Increase size of ifnet.if_flags from 16 bits (short) to 32 bits (int). To avoid
breaking application ABI use unused ifreq.ifru_flags[1] for upper 16 bits in SIOCSIFFLAGS and SIOCGIFFLAGS ioctl's. Reviewed by: -hackers, -net
Notes
Notes: svn path=/head/; revision=102052
Diffstat (limited to 'sys/kern/kern_poll.c')
-rw-r--r--sys/kern/kern_poll.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/kern/kern_poll.c b/sys/kern/kern_poll.c
index b3a96bacb8b9..0f3254e97c9f 100644
--- a/sys/kern/kern_poll.c
+++ b/sys/kern/kern_poll.c
@@ -383,7 +383,7 @@ netisr_poll(void)
for (i = 0 ; i < poll_handlers ; i++) {
if (pr[i].handler &&
pr[i].ifp->if_flags & IFF_RUNNING) {
- pr[i].ifp->if_ipending &= ~IFF_POLLING;
+ pr[i].ifp->if_flags &= ~IFF_POLLING;
pr[i].handler(pr[i].ifp, POLL_DEREGISTER, 1);
}
pr[i].handler=NULL;
@@ -415,7 +415,7 @@ ether_poll_register(poll_handler_t *h, struct ifnet *ifp)
return 0;
if ( !(ifp->if_flags & IFF_UP) ) /* must be up */
return 0;
- if (ifp->if_ipending & IFF_POLLING) /* already polling */
+ if (ifp->if_flags & IFF_POLLING) /* already polling */
return 0;
s = splhigh();
@@ -440,7 +440,7 @@ ether_poll_register(poll_handler_t *h, struct ifnet *ifp)
pr[poll_handlers].handler = h;
pr[poll_handlers].ifp = ifp;
poll_handlers++;
- ifp->if_ipending |= IFF_POLLING;
+ ifp->if_flags |= IFF_POLLING;
splx(s);
if (idlepoll_sleeping)
wakeup(&idlepoll_sleeping);
@@ -459,14 +459,14 @@ ether_poll_deregister(struct ifnet *ifp)
int i;
mtx_lock(&Giant);
- if ( !ifp || !(ifp->if_ipending & IFF_POLLING) ) {
+ if ( !ifp || !(ifp->if_flags & IFF_POLLING) ) {
mtx_unlock(&Giant);
return 0;
}
for (i = 0 ; i < poll_handlers ; i++)
if (pr[i].ifp == ifp) /* found it */
break;
- ifp->if_ipending &= ~IFF_POLLING; /* found or not... */
+ ifp->if_flags &= ~IFF_POLLING; /* found or not... */
if (i == poll_handlers) {
mtx_unlock(&Giant);
printf("ether_poll_deregister: ifp not found!!!\n");