Date: 5 Apr 2000 19:04:58 -0000 From: fujiwara@rcac.tdi.co.jp To: FreeBSD-gnats-submit@freebsd.org Subject: kern/17814: sr driver ignores IFF_LINK2 | IFF_DEBUG when first time ifconfig Message-ID: <20000405190458.858.qmail@f.rcac.tdi.co.jp>
next in thread | raw e-mail | index | archive | help
>Number: 17814
>Category: kern
>Synopsis: sr driver ignores IFF_LINK2 | IFF_DEBUG when first time ifconfig
>Confidential: yes
>Severity: serious
>Priority: medium
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Wed Apr 5 12:10:00 PDT 2000
>Closed-Date:
>Last-Modified:
>Originator: Kazunori_Fujiwara
>Release: FreeBSD 4.0-STABLE i386
>Organization:
>Environment:
4.0-RELEASE, 4.0-STABLE, 5.0-CURRENT
PC with RISCom/N2(isa or pci) and Leased Line connection
pseudo-device sppp
device sr
>Description:
write to rc.conf:
network_interfaces="sr0 ..."
ifconfig_sr0="inet 192.168.1.1 192.168.1.2 netmask 0xfffffffc link2 debug up"
but then,
ifconfig sr0 shows without LINK2 and DEBUB
So, CISCO_HDLC connection is not done.
>How-To-Repeat:
>Fix:
firsttime sr_ioctl() calls sppp_attach,
sppp_attach destroys ifp->if_flags
So, sr_ioctl ignores LINK2 and DEBUG flags
my temporary patch is here. (if_spppsubr.c:sr_attach())
--- sys/net/if_spppsubr.c.orig Wed Apr 5 21:59:05 2000
+++ sys/net/if_spppsubr.c Thu Apr 6 03:39:43 2000
@@ -801,7 +801,8 @@
spppq = sp;
sp->pp_if.if_mtu = PP_MTU;
- sp->pp_if.if_flags = IFF_POINTOPOINT | IFF_MULTICAST;
+ sp->pp_if.if_flags &= (IFF_LINK0 | IFF_LINK1 | IFF_LINK2 | IFF_UP | IFF_DEBUG);
+ sp->pp_if.if_flags |= IFF_POINTOPOINT | IFF_MULTICAST;
sp->pp_if.if_type = IFT_PPP;
sp->pp_if.if_output = sppp_output;
#if 0
@@ -816,6 +817,7 @@
sp->pp_phase = PHASE_DEAD;
sp->pp_up = lcp.Up;
sp->pp_down = lcp.Down;
+ sp->pp_mode = 0;
sppp_lcp_init(sp);
sppp_ipcp_init(sp);
>Release-Note:
>Audit-Trail:
>Unformatted:
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20000405190458.858.qmail>
