Date: Sat, 14 Sep 2013 13:12:13 +0000 (UTC) From: Alexander Motin <mav@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r255569 - stable/9/sys/kern Message-ID: <201309141312.r8EDCDQX027813@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mav Date: Sat Sep 14 13:12:13 2013 New Revision: 255569 URL: http://svnweb.freebsd.org/changeset/base/255569 Log: Temporary revert r255541 since there is no CPU_FFS in stable/9 yet. Sorry. Modified: stable/9/sys/kern/sched_ule.c Modified: stable/9/sys/kern/sched_ule.c ============================================================================== --- stable/9/sys/kern/sched_ule.c Sat Sep 14 10:14:09 2013 (r255568) +++ stable/9/sys/kern/sched_ule.c Sat Sep 14 13:12:13 2013 (r255569) @@ -632,14 +632,10 @@ cpu_search(const struct cpu_group *cg, s } /* Iterate through the child CPU groups and then remaining CPUs. */ - for (i = cg->cg_children, cpu = mp_maxid; ; ) { + for (i = cg->cg_children, cpu = mp_maxid; i >= 0; ) { if (i == 0) { -#ifdef HAVE_INLINE_FFSL - cpu = CPU_FFS(&cpumask) - 1; -#else while (cpu >= 0 && !CPU_ISSET(cpu, &cpumask)) cpu--; -#endif if (cpu < 0) break; child = NULL; @@ -664,7 +660,6 @@ cpu_search(const struct cpu_group *cg, s break; } } else { /* Handle child CPU. */ - CPU_CLR(cpu, &cpumask); tdq = TDQ_CPU(cpu); load = tdq->tdq_load * 256; rndptr = DPCPU_PTR(randomval); @@ -712,11 +707,8 @@ cpu_search(const struct cpu_group *cg, s i--; if (i == 0 && CPU_EMPTY(&cpumask)) break; - } -#ifndef HAVE_INLINE_FFSL - else + } else cpu--; -#endif } return (total); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201309141312.r8EDCDQX027813>