Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 16 Oct 2009 12:01:00 +0000 (UTC)
From:      Konstantin Belousov <kib@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r198170 - in head/sys: amd64/amd64 i386/i386
Message-ID:  <200910161201.n9GC103B003290@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kib
Date: Fri Oct 16 12:00:59 2009
New Revision: 198170
URL: http://svn.freebsd.org/changeset/base/198170

Log:
  Move intr_describe() out of #ifdef SMP; the function is always required.
  
  Reviewed by:	jhb

Modified:
  head/sys/amd64/amd64/intr_machdep.c
  head/sys/i386/i386/intr_machdep.c

Modified: head/sys/amd64/amd64/intr_machdep.c
==============================================================================
--- head/sys/amd64/amd64/intr_machdep.c	Fri Oct 16 11:00:26 2009	(r198169)
+++ head/sys/amd64/amd64/intr_machdep.c	Fri Oct 16 12:00:59 2009	(r198170)
@@ -400,6 +400,23 @@ atpic_reset(void)
 }
 #endif
 
+/* Add a description to an active interrupt handler. */
+int
+intr_describe(u_int vector, void *ih, const char *descr)
+{
+	struct intsrc *isrc;
+	int error;
+
+	isrc = intr_lookup_source(vector);
+	if (isrc == NULL)
+		return (EINVAL);
+	error = intr_event_describe_handler(isrc->is_event, ih, descr);
+	if (error)
+		return (error);
+	intrcnt_updatename(isrc);
+	return (0);
+}
+
 #ifdef DDB
 /*
  * Dump data about interrupt handlers
@@ -466,23 +483,6 @@ intr_bind(u_int vector, u_char cpu)
 	return (intr_event_bind(isrc->is_event, cpu));
 }
 
-/* Add a description to an active interrupt handler. */
-int
-intr_describe(u_int vector, void *ih, const char *descr)
-{
-	struct intsrc *isrc;
-	int error;
-
-	isrc = intr_lookup_source(vector);
-	if (isrc == NULL)
-		return (EINVAL);
-	error = intr_event_describe_handler(isrc->is_event, ih, descr);
-	if (error)
-		return (error);
-	intrcnt_updatename(isrc);
-	return (0);
-}
-
 /*
  * Add a CPU to our mask of valid CPUs that can be destinations of
  * interrupts.

Modified: head/sys/i386/i386/intr_machdep.c
==============================================================================
--- head/sys/i386/i386/intr_machdep.c	Fri Oct 16 11:00:26 2009	(r198169)
+++ head/sys/i386/i386/intr_machdep.c	Fri Oct 16 12:00:59 2009	(r198170)
@@ -366,6 +366,23 @@ intr_init(void *dummy __unused)
 }
 SYSINIT(intr_init, SI_SUB_INTR, SI_ORDER_FIRST, intr_init, NULL);
 
+/* Add a description to an active interrupt handler. */
+int
+intr_describe(u_int vector, void *ih, const char *descr)
+{
+	struct intsrc *isrc;
+	int error;
+
+	isrc = intr_lookup_source(vector);
+	if (isrc == NULL)
+		return (EINVAL);
+	error = intr_event_describe_handler(isrc->is_event, ih, descr);
+	if (error)
+		return (error);
+	intrcnt_updatename(isrc);
+	return (0);
+}
+
 #ifdef DDB
 /*
  * Dump data about interrupt handlers
@@ -432,23 +449,6 @@ intr_bind(u_int vector, u_char cpu)
 	return (intr_event_bind(isrc->is_event, cpu));
 }
 
-/* Add a description to an active interrupt handler. */
-int
-intr_describe(u_int vector, void *ih, const char *descr)
-{
-	struct intsrc *isrc;
-	int error;
-
-	isrc = intr_lookup_source(vector);
-	if (isrc == NULL)
-		return (EINVAL);
-	error = intr_event_describe_handler(isrc->is_event, ih, descr);
-	if (error)
-		return (error);
-	intrcnt_updatename(isrc);
-	return (0);
-}
-
 /*
  * Add a CPU to our mask of valid CPUs that can be destinations of
  * interrupts.



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