Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 29 Nov 2017 15:11:28 -0800
From:      Gleb Smirnoff <glebius@FreeBSD.org>
To:        Nathan Whitehorn <nwhitehorn@FreeBSD.org>
Cc:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   Re: svn commit: r326218 - head/sys/kern
Message-ID:  <20171129231128.GO1063@FreeBSD.org>
In-Reply-To: <201711252341.vAPNf5Qx001464@repo.freebsd.org>
References:  <201711252341.vAPNf5Qx001464@repo.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
  Hi Nathan,

On Sat, Nov 25, 2017 at 11:41:05PM +0000, Nathan Whitehorn wrote:
N> Author: nwhitehorn
N> Date: Sat Nov 25 23:41:05 2017
N> New Revision: 326218
N> URL: https://svnweb.freebsd.org/changeset/base/326218
N> 
N> Log:
N>   Remove some, but not all, assumptions that the BSP is CPU 0 and that CPUs
N>   are numbered densely from there to n_cpus.

I got experimental branch, where counter(9) can be used at very early
stages of startup, e.g. at VM initialization. I suspect it would be broken
once I merge in your changes.

Basically, what I need is that CPU_FOREACH() works before AP startup, with
one iteration - the BSP. Now I achieve that with this hack:

https://github.com/glebius/FreeBSD/commit/834b857464972b45e659f99fa2dd91e987b17dc9

Can you please suggest a better way to do that?

-- 
Gleb Smirnoff



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