Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 22 Jul 2006 12:33:45 GMT
From:      Paolo Pisati <piso@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 102141 for review
Message-ID:  <200607221233.k6MCXjIL033391@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=102141

Change 102141 by piso@piso_longino on 2006/07/22 12:33:15

	Use IF_FAST macro instead of directly checking flags,
	and axe an INTR_FAST check in swi_add(): is it possible
	for a software interrupt handler to have INTR_FAST defined?
	did it make sense at all? 

Affected files ...

.. //depot/projects/soc2006/intr_filter/kern/kern_intr.c#10 edit

Differences ...

==== //depot/projects/soc2006/intr_filter/kern/kern_intr.c#10 (text+ko) ====

@@ -370,7 +370,7 @@
 	intr_event_update(ie);
 
 	/* Create a thread if we need one. */
-	while (ie->ie_thread == NULL && !(flags & INTR_FAST)) {
+	while (ie->ie_thread == NULL && !IS_FAST(filter, handler)) {
 		if (ie->ie_flags & IE_ADDING_THREAD)
 			msleep(ie, &ie->ie_lock, 0, "ithread", 0);
 		else {
@@ -551,7 +551,13 @@
 	struct intr_event *ie;
 	int error;
 
-	if (flags & (INTR_FAST | INTR_ENTROPY))
+#if 0
+	// XXX a software intr handler with INTR_FAST?!?!?!?
+        if (flags & (INTR_FAST | INTR_ENTROPY))
+                return (EINVAL);
+#endif
+
+	if (flags & INTR_ENTROPY)
 		return (EINVAL);
 
 	ie = (eventp != NULL) ? *eventp : NULL;



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