From dunstan@freebsd.czest.pl  Sat Jul  2 00:37:24 2005
Return-Path: <dunstan@freebsd.czest.pl>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 7F18716A41C
	for <FreeBSD-gnats-submit@freebsd.org>; Sat,  2 Jul 2005 00:37:24 +0000 (GMT)
	(envelope-from dunstan@freebsd.czest.pl)
Received: from freebsd.czest.pl (silver.iplus.pl [80.48.250.4])
	by mx1.FreeBSD.org (Postfix) with ESMTP id F27AE43D48
	for <FreeBSD-gnats-submit@freebsd.org>; Sat,  2 Jul 2005 00:37:23 +0000 (GMT)
	(envelope-from dunstan@freebsd.czest.pl)
Received: from freebsd.czest.pl (freebsd.czest.pl [80.48.250.4])
	by freebsd.czest.pl (8.12.10/8.12.9) with ESMTP id j620oK2l053161
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 2 Jul 2005 00:50:21 GMT
	(envelope-from dunstan@freebsd.czest.pl)
Received: (from dunstan@localhost)
	by freebsd.czest.pl (8.12.10/8.12.9/Submit) id j620oKBe053160;
	Sat, 2 Jul 2005 00:50:20 GMT
	(envelope-from dunstan)
Message-Id: <200507020050.j620oKBe053160@freebsd.czest.pl>
Date: Sat, 2 Jul 2005 00:50:20 GMT
From: "Wojciech A. Koszek" <dunstan@freebsd.czest.pl>
Reply-To: "Wojciech A. Koszek" <dunstan@freebsd.czest.pl>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: ng_fec(4) causes kernel panic after interface datach
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         82881
>Category:       kern
>Synopsis:       [netgraph] [panic] ng_fec(4) causes kernel panic after interface detach
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-net
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Jul 02 00:40:23 GMT 2005
>Closed-Date:    
>Last-Modified:  Thu Mar 18 04:25:24 UTC 2010
>Originator:     Wojciech A. Koszek
>Release:        FreeBSD 5.4-STABLE i386
>Organization:
>Environment:
System: FreeBSD dunstan.freebsd.czest.pl 5.4-STABLE FreeBSD 5.4-STABLE #0: Mon May 23 00:05:05 CEST 2005 root@dunstan.freebsd.czest.pl:/usr/obj/usr/src/sys/HOME8 i386


>Description:
ng_fec(4) brings Cisco Fast-Ethernet Trunking to Netgraph subsystem. It
creates virtual network interface, which is based on logical interfaces
providing access to physical media. Structures responsible for 'fec'
interface contain information about underlying interfaces. Thus,
modification on logical interfaces (e.g: detaching) modifies 'fec'
interface behaviour. Currently there is no handling of described situation -
after detaching underlying interface and touching existing fec interface,
kernel panics. This is due to delivery of requests (ioctl) to non-existent
interface.

>How-To-Repeat:
ngctl
(..)
+ mkpeer . fec a b
+ list
There are 2 total nodes:
  Name: fec0            Type: fec           ID: 00000002 Num hooks: 1
  Name: ngctl728        Type: socket        ID: 00000001  Num hooks: 1
+ msg [2]: add_iface "sk0"
+ quit

$ ifconfig fec0
fec0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> mtu 1500
	ether 00:11:d8:a8:10:ab
	media: Ethernet none
	status: active
# kldunload if_sk
# ifconfig fec0 10.0.0.1

>Fix:
Probably EVENTHANDLER(9) in current design.
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-net 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Thu Mar 18 04:25:10 UTC 2010 
Responsible-Changed-Why:  
Over to maintainer(s). 

http://www.freebsd.org/cgi/query-pr.cgi?pr=82881 
>Unformatted:
