Index | Thread | Search

From:
Klemens Nanni <kn@openbsd.org>
Subject:
Re: tun(4): SIOCSIFDSTADDR is deprecated, so stop handling it
To:
David Gwynne <david@gwynne.id.au>, tech@openbsd.org
Date:
Tue, 15 Oct 2024 17:02:01 +0000

Download raw body.

Thread
15.10.2024 06:33, David Gwynne пишет:
> according to netintro, SIOCSIFDSTADDR is deprecated. only a handful of
> old drivers still have code to handle it, so i'd like to clean them up.
> tun(4) can go first.

So is SIOCSIFADDR, why leave that one?

> 
> ok?
> 
> Index: if_tun.c
> ===================================================================
> RCS file: /cvs/src/sys/net/if_tun.c,v
> diff -u -p -r1.241 if_tun.c
> --- if_tun.c	10 Oct 2024 06:50:58 -0000	1.241
> +++ if_tun.c	15 Oct 2024 03:29:35 -0000
> @@ -599,10 +543,6 @@ tun_ioctl(struct ifnet *ifp, u_long cmd,
>  			CLR(ifp->if_flags, IFF_RUNNING);
>  		break;
>  
> -	case SIOCSIFDSTADDR:
> -		tun_init(sc);
> -		TUNDEBUG(("%s: destination address set\n", ifp->if_xname));
> -		break;
>  	case SIOCSIFMTU:
>  		if (ifr->ifr_mtu < ETHERMIN || ifr->ifr_mtu > TUNMRU)
>  			error = EINVAL;
>