Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/net It's not required (and can't do) to convert OSIOCSIF...



details:   https://anonhg.NetBSD.org/src/rev/c7e223457165
branches:  trunk
changeset: 450505:c7e223457165
user:      msaitoh <msaitoh%NetBSD.org@localhost>
date:      Tue Apr 16 06:48:33 2019 +0000

description:
It's not required (and can't do) to convert OSIOCSIFMEDIA in ifmedia_ioct()
because the conversiosn is done in doifioctl().

diffstat:

 sys/net/if_media.c |  15 ++-------------
 1 files changed, 2 insertions(+), 13 deletions(-)

diffs (48 lines):

diff -r 16072cb928e2 -r c7e223457165 sys/net/if_media.c
--- a/sys/net/if_media.c        Tue Apr 16 06:45:04 2019 +0000
+++ b/sys/net/if_media.c        Tue Apr 16 06:48:33 2019 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_media.c,v 1.40 2019/04/10 08:23:46 msaitoh Exp $    */
+/*     $NetBSD: if_media.c,v 1.41 2019/04/16 06:48:33 msaitoh Exp $    */
 
 /*-
  * Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -76,7 +76,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_media.c,v 1.40 2019/04/10 08:23:46 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_media.c,v 1.41 2019/04/16 06:48:33 msaitoh Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -89,8 +89,6 @@
 #include <net/if_media.h>
 #include <net/netisr.h>
 
-#include <compat/sys/sockio.h>
-
 static void    ifmedia_status(struct ifmedia *, struct ifnet *,
     struct ifmediareq *);
 static int     _ifmedia_ioctl(struct ifnet *, struct ifreq *,
@@ -252,20 +250,11 @@
        struct ifmedia_entry *match;
        struct ifmediareq *ifmr = (struct ifmediareq *)ifr;
        int error = 0;
-#ifdef OSIOCSIFMEDIA
-       struct oifreq *oifr = (struct oifreq *)ifr;
-#endif
 
        if (ifp == NULL || ifr == NULL || ifm == NULL)
                return (EINVAL);
 
        switch (cmd) {
-
-#ifdef OSIOCSIFMEDIA
-       case OSIOCSIFMEDIA:
-               ifr->ifr_media = oifr->ifr_media;
-#endif
-               /* FALLTHROUGH */
        /*
         * Set the current media.
         */



Home | Main Index | Thread Index | Old Index