Re: PPP(was: oE) problems with latest -CURRENT

From: Peter Ulrich Kruppa <root_at_pukruppa.net>
Date: Mon, 2 Aug 2004 12:06:09 +0000 (GMT)
Thanks, for repairing things. Your patch works fine for me.

Will it be committed soon, or do I have to keep it?

Peter Ulrich Kruppa ("Original poster")


On Sun, 1 Aug 2004, Bjoern A. Zeeb wrote:
>
> Index: ng_pppoe.c
> ===================================================================
> RCS file: /local/mirror/FreeBSD/r/ncvs/src/sys/netgraph/ng_pppoe.c,v
> retrieving revision 1.66
> diff -u -p -r1.66 ng_pppoe.c
> --- ng_pppoe.c	27 Jul 2004 19:47:13 -0000	1.66
> +++ ng_pppoe.c	1 Aug 2004 14:17:49 -0000
> _at__at_ -246,9 +246,9 _at__at_ enum {
>  };
>
>  struct ng_pppoe_mode_t {
> -        u_int8_t        		id;
> +	u_int8_t			id;
>  	const struct ether_header	*eh_prototype;
> -        const char      		*name;
> +	const char			*name;
>  };
>
>  static const struct ether_header eh_standard =
> _at__at_ -283,10 +283,9 _at__at_ struct PPPOE {
>  typedef struct PPPOE *priv_p;
>
>  /* Deprecated sysctl, leaved here to keep compatibility for some time */
> -#define PPPOE_KEEPSTANDARD	-1
> -#define PPPOE_STANDARD		0
> -#define PPPOE_NONSTANDARD	1
> -static int pppoe_mode = PPPOE_KEEPSTANDARD;
> +#define PPPOE_SYSCTL_KEEPSTANDARD	-1
> +#define PPPOE_SYSCTL_STANDARD		0
> +#define PPPOE_SYSCTL_NONSTANDARD	1
>  static const struct ng_pppoe_mode_t *sysctl_mode = ng_pppoe_modes;
>
>  static int
> _at__at_ -295,23 +294,22 _at__at_ ngpppoe_set_ethertype(SYSCTL_HANDLER_ARG
>  	int error;
>  	int val;
>
> -	val = pppoe_mode;
> +	val = PPPOE_SYSCTL_KEEPSTANDARD;
>  	error = sysctl_handle_int(oidp, &val, sizeof(int), req);
>  	if (error != 0 || req->newptr == NULL)
>  		return (error);
>  	switch (val) {
> -	case PPPOE_NONSTANDARD:
> +	case PPPOE_SYSCTL_NONSTANDARD:
>  		sysctl_mode = ng_pppoe_modes + 1;
>  		break;
> -	case PPPOE_STANDARD:
> -	case PPPOE_KEEPSTANDARD:
> +	case PPPOE_SYSCTL_STANDARD:
> +	case PPPOE_SYSCTL_KEEPSTANDARD:
>  		sysctl_mode = ng_pppoe_modes;
>  		break;
>  	default:
>  		return (EINVAL);
>  	}
>
> -	pppoe_mode = val;
>  	printf("net.graph.nonstandard_pppoe is deprecated. See ng_pppoe(4), ppp(8).\n");
>  	return (0);
>  }
>
> --
> Bjoern A. Zeeb				bzeeb at Zabbadoz dot NeT
> _______________________________________________
> freebsd-current_at_freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-current
> To unsubscribe, send any mail to "freebsd-current-unsubscribe_at_freebsd.org"
>
Received on Mon Aug 02 2004 - 08:06:39 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:04 UTC