From owner-freebsd-ports-bugs@FreeBSD.ORG Sun May 16 18:20:02 2010 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A758F1065677 for ; Sun, 16 May 2010 18:20:02 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (unknown [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 68EDA8FC14 for ; Sun, 16 May 2010 18:20:02 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id o4GIK1LT012621 for ; Sun, 16 May 2010 18:20:01 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id o4GIK16b012620; Sun, 16 May 2010 18:20:01 GMT (envelope-from gnats) Resent-Date: Sun, 16 May 2010 18:20:01 GMT Resent-Message-Id: <201005161820.o4GIK16b012620@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Stephen McPolin Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3C2171065677 for ; Sun, 16 May 2010 18:11:21 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id 2A61F8FC16 for ; Sun, 16 May 2010 18:11:21 +0000 (UTC) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.3/8.14.3) with ESMTP id o4GIBKqM021891 for ; Sun, 16 May 2010 18:11:20 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id o4GIBKKI021869; Sun, 16 May 2010 18:11:20 GMT (envelope-from nobody) Message-Id: <201005161811.o4GIBKKI021869@www.freebsd.org> Date: Sun, 16 May 2010 18:11:20 GMT From: Stephen McPolin To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: ports/146640: SIOC_WANPIPE_PIPEMON conflicts with GIFGOPTS causes ifconfig sigbus. X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 May 2010 18:20:02 -0000 >Number: 146640 >Category: ports >Synopsis: SIOC_WANPIPE_PIPEMON conflicts with GIFGOPTS causes ifconfig sigbus. >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: maintainer-update >Submitter-Id: current-users >Arrival-Date: Sun May 16 18:20:01 UTC 2010 >Closed-Date: >Last-Modified: >Originator: Stephen McPolin >Release: FreeBSD 8.0 STABLE >Organization: Bytown Technology Group >Environment: FreeBSD .jurasys.com 8.0-STABLE-201004 FreeBSD 8.0-STABLE-201004 #0: Mon Apr 5 15:59:06 UTC 2010 root@mason.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC amd64 >Description: The lines below show the conflicts in this ports ioctls. Ifconfig cores from a SIGBUS because the GIFGOPTS was being interpreted incorrectly by wanpipe, and smashed the stackframe of gif_status() in ifconfig/ifgif.c usr/ports/misc/wanpipe/work/wanpipe-3.3.1/include: wanpipe_snmp.h:# define SIOC_WANPIPE_SNMP _IOWR('i', 100, struct ifreq) wanpipe_snmp.h:# define SIOC_WANPIPE_SNMP_IFSPEED _IOWR('i', 101, struct ifreq) wanrouter.h:# define SIOC_WANPIPE_PIPEMON _IOWR('i', 150, struct ifreq) /* get monitor statistics */ wanrouter.h:# define SIOC_WANPIPE_DEVICE _IOWR('i', 151, struct ifreq) /* set generic device */ wanrouter.h:# define SIOC_WANPIPE_DUMP _IOWR('i', 153, struct ifreq) /* get memdump string (GENERIC) */ /usr/include: netinet6/in6_var.h:#define SIOCSIFPREFIX_IN6 _IOW('i', 100, struct in6_prefixreq) /* set */ netinet6/in6_var.h:#define SIOCGIFPREFIX_IN6 _IOWR('i', 101, struct in6_prefixreq) /* get */ net/if_gif.h:#define GIFGOPTS _IOWR('i', 150, struct ifreq) net/if_gif.h:#define GIFSOPTS _IOW('i', 151, struct ifreq) >How-To-Repeat: Build the wanpipe port [ requires a little manual intervention ] and install it on a machine with a Sangoma A10[124] board. Configure the ports, and load modules with "wanrouter start". After this, ifconfig faults when it queries any of the wanpipe interfaces. >Fix: Change the ioctl values in the wanpipe header files is step one. A real 'fix' would involve an "ioctl value registry". >Release-Note: >Audit-Trail: >Unformatted: