Re: [PATCH] cpumask 5/10 rewrite cpumask.h - single bitmap based implementation

Paul Jackson
2004-06-04T05:24:58Z

> I don't see what you gain from having the cpumask type but having
> to get at its internals with the bitop functions.

The essential gain, in my view, of cpumask, is that it encapsulates
the value NR_CPUS. cpumasks are bitmaps of length NR_CPUS.

Yes, there is an open issue of whether cpumasks are worth it.
I think enough code has taken to them that they are.

The getting at internals (via cpus_addr(), I'm guessing you mean)
was a workaround for some code that messed with cpumasks and simple
unsigned longs as if they were interoperable. "cpus_addr" should
be marked deprecated, and its use coded out. Its remaining uses
are in arch-specific areas where I lack the expertise and testing
environment to accomplish such.

I needed some legacy mechanism such as this, in order to avoid
having such existing uses bring the entire cpumask overhaul to
a screeching halt.

--
I won't rest till it's the best ...
Programmer, Linux Scalability
Paul Jackson <pj@sgi.com> 1.650.933.1373