On Sun, 16 Mar 2003 03:32:54 -0800, William Lee Irwin III wrote:
>> Another thought I had was wrapping things in structures for both small
>> and large, even UP systems so proper typechecking is enforced at all
>> times. That would probably need a great deal of arch sweeping to do,
>> especially as a number of arches are UP-only (non-SMP case's motive #2).
On Sun, Mar 16, 2003 at 10:53:19PM +1100, Keith Owens wrote:
> Keep the optimized model, where cpu_online_map is #defined to 1 for UP.
> Changing it to an ADT just to get type checking on architectures that
> only support UP looks like a bad tradeoff.
It shouldn't hurt UP:
typedef { unsigned long mask; } cpumask_t;
#define cpu_online_map ({ 1UL })
or some such nonsense with all the usual special cases. The arch code
impact OTOH can't really be gotten around with such tricks, if it's
significant. More food for thought...
-- wli
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
This archive was generated by hypermail 2b29 : Sun Mar 23 2003 - 22:00:18 EST