Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 13 Dec 2013 22:22:55 +0000 (UTC)
From:      Ian Lepore <ian@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r259348 - stable/10/sys/arm/freescale/imx
Message-ID:  <201312132222.rBDMMt7I051364@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ian
Date: Fri Dec 13 22:22:54 2013
New Revision: 259348
URL: http://svnweb.freebsd.org/changeset/base/259348

Log:
  MFC r257418:
  
    Don't iterate through the bits of the pending interrupt register if the
    whole register is zero.  Most of the registers will be zero most of the time.

Modified:
  stable/10/sys/arm/freescale/imx/tzic.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/arm/freescale/imx/tzic.c
==============================================================================
--- stable/10/sys/arm/freescale/imx/tzic.c	Fri Dec 13 22:21:49 2013	(r259347)
+++ stable/10/sys/arm/freescale/imx/tzic.c	Fri Dec 13 22:22:54 2013	(r259348)
@@ -163,7 +163,7 @@ arm_get_next_irq(int last_irq)
 
 	for (i = 0; i < 4; i++) {
 		pending = tzic_read_4(TZIC_PND(i));
-		for (b = 0; b < 32; b++)
+		for (b = 0; pending != 0 && b < 32; b++)
 			if (pending & (1 << b)) {
 				return (i * 32 + b);
 			}



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