Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 19 Dec 2004 05:36:29 GMT
From:      Ken Westerback <krw@openbsd.org>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   kern/75250: timedout_scbs is not initialized with LIST_INIT()
Message-ID:  <200412190536.iBJ5aT7j095880@www.freebsd.org>
Resent-Message-ID: <200412190540.iBJ5eRvf075775@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         75250
>Category:       kern
>Synopsis:       timedout_scbs is not initialized with LIST_INIT()
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Dec 19 05:40:27 GMT 2004
>Closed-Date:
>Last-Modified:
>Originator:     Ken Westerback
>Release:        n/a
>Organization:
OpenBSD
>Environment:
n/a (OpenBSD)
>Description:
The list timedout_scbs in ahd_softc is not initialized anywhere I can find. The diff below adds a LIST_INIT(&ahd->timedout_scbs) to ahd_alloc(), which is where the similar list pending_scbs is initialized.

Found while trying to upgrade the OpenBSD ahd driver with the latest FreeBSD goodies.

I note that a similar problem may exist on ahc, but I haven't started sync'ing ahc yet.


>How-To-Repeat:
      
>Fix:
Index: aic79xx.c
===================================================================
RCS file: /home/ncvs/src/sys/dev/aic7xxx/aic79xx.c,v
retrieving revision 1.33
diff -u -r1.33 aic79xx.c
--- aic79xx.c	18 Nov 2004 20:22:30 -0000	1.33
+++ aic79xx.c	19 Dec 2004 05:23:19 -0000
@@ -5246,6 +5246,7 @@
 		return (NULL);
 	}
 	LIST_INIT(&ahd->pending_scbs);
+	LIST_INIT(&ahd->timedout_scbs);
 	/* We don't know our unit number until the OSM sets it */
 	ahd->name = name;
 	ahd->unit = -1;
  
>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200412190536.iBJ5aT7j095880>