Subject: kern/30233: raidstrategy() isn't interrupt-safe
To: None <,,>
From: Manuel Bouyer <>
List: netbsd-bugs
Date: 05/14/2005 22:03:00
>Number:         30233
>Category:       kern
>Synopsis:       raidstrategy() isn't interrupt-safe
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat May 14 22:03:00 +0000 2005
>Originator:     Manuel Bouyer
>Release:        NetBSD 3.99.3
System: NetBSD 3.99.3 NetBSD 3.99.3 (ROCHEBONNE) #0: Sat May 14 15:33:21 CEST 2005 i386
Architecture: i386
Machine: i386
	Quoting a post from Jason Thorpe on tech-kern:
	> There are lots of other things that might cause a disk's strategy
	> routine to be called from interrupt context (ccd / raidframe are good
	> examples).  Really, we need to audit ALL of the disk strategy
	> routines and ensure that they are IPL_BIO interrupt-context safe.

	raidstrategy() isn't safe to call from interrupt context: it ends up
	calling pool_get(PR_WAITOK):

	There may be other problems too other problems when called from
	interrupt context too (are the locks interrupt-safe ?).

	An easy way to trigger a pool_get() panic is to export a partition
	from a raidframe device to a guest Xen domain, as reported by
	Yoshito Komatsu on port-xen.
	None provided.